Wednesday, September 19, 2018

Change files to 0644 and directories to 0755

Its very simple,

Basically numbers or letters it is the same:
read is 4
write is 2
execute is 1
0644 for example means read + write/ read/ read.

just type this command in web root directory:-

To change all the directories to 755 (drwxr-xr-x):
find . -type d -exec chmod 755 {} \;
To change all the files to 644 (-rw-r--r--):
find . -type f -exec chmod 644 {} \;

That's It,

Monday, September 3, 2018

redirect mail with header ispconfig

Redirect mail with header using ispconfig

Just go to the EMail Tab, then go to the Email Mailbox, click on the email which you want to forward, and last click on custom rule and past this code and submit it.

# required extensions to process email
require "editheader";
require "variables";

# keep local email unchange

# header rewriting
if header :matches "X-Original-To" "*" {
    # delete existing headers to  prevent creating duplicate
    deleteheader :index 1 :contains "From";
    deleteheader "DKIM-Signature";
    deleteheader "DomainKey-Signature";
    deleteheader "Delivered-To";
    # add the new header
    addheader "From" "${1}";
    # redirect or forward email
    redirect "";
    redirect "";
    redirect "";

Thursday, July 12, 2018

mount: unknown file system type 'VMFS_volume_member'

VMFS(Virtual Machine File System) is a clustered filesystem designed to store virtual machine disks for VMware ESX or ESXi Server hosts.

To access the data in VMFS drive.

  • 1st boot your server using live Ubuntu, then
  • Install vmfs-tools. (vmfs-tools is available in Ubuntu Software Center.) Or use command in terminal
sudo apt-get install vmfs-tools
or read manual install vmfs-tools from this link

Then mount vmfs drive

Use vmfs-tools to mount VMFS filesystem

1st find your vmfs drive using fdisk in terminal
use command in terminal
sudo fdisk -l
For example if you want to mount /dev/sdd1
1st create mount point 
mkdir /mnt/sdd
sudo vmfs-fuse /dev/sdd1 /mnt/sdd
Now you access your mount drive using
cd /mnt/sdd

For more Help Click Here

To Upgrade Datastores to VMFS-6 Click Here

That's it...

how to install vmfs-tools ubuntu

Install vmfs-tools. (vmfs-tools is available in Ubuntu Software Center.) Or use command in terminal
sudo apt-get install vmfs-tools
or download from this link:-
for 32 Bit or 64 Bit

Or using terminal use these commands

For 32Bit
For 64Bit
[root@akwal~]# dpkg -i mfs-tools_0.2.5-1_i386.deb
[root@akwal~]# dpkg -i vmfs-tools_0.2.5-1_amd64.deb
Then install it using
[root@akwal~]# apt-get install vmfs-tools
Then use this command to mount vmfs drive:-
[root@akwal~]# sudo vmfs-fuse /dev/sdd1 /mnt/sdd
for more help to mount vmfs Click here

Or install vmfs-tools on CentOS / Fedora Click here

That's it... 

Wednesday, May 9, 2018

Upload A File To cpanel From Another Server/URL?

How to Upload A File To cpanel From Another Server/URL?

Uploading data from one cpanel to another is very easy using this script.
Other wise its very pathetic and very time take task to download the data from one cpanel/server to your own computer, then upload it on the 2nd cpanel/server.

There are only few steps:-

  • compress your data folder (zip, tar, etc)
  • copy the link of that compress zip file. (eg
Then login your new cpanel/server:-
  • create a new file with any name, (eg upload.php)
  • paste this code and click upload button.
  • that's it.

<!DOCTYPE html>
    <title>Upload file from URL</title>
    $BASE_URL = strtok($_SERVER['REQUEST_URI'],'?');
    if (isset($_POST['url'])){
        $url = $_POST['url'];
        echo "Transferring file: {$url}<br>";
        exec("wget {$url}");
    <form name='upload' method='post' action="<?php echo $BASE_URL; ?>">
        <input type='text' id='url' name='url' size='128' /><br>
        <input type="submit" value="Upload">

Once you have done, make sure that you have removed the script/file (upload.php), cause hackers can  upload malicious files to your webserver!


Friday, May 4, 2018

Vtiger 7.1.0 Database charset or collation not compatible

Vtiger 7.1.0 Database charset or collation not compatible with UTF8 Error

If you are manually installing latest Vtiger 7.1.0 version, you might got this error: “vtiger Database charset or collation not compatible with UTF8”

This happens when the database charset is not compatible with Vtiger recommended utf8_general_ci. For this, login to phpmyadmin in your cPanel. In PhpMyAdmin, you can select the database you have created and then go to “Operations”.

In the operations tab section there is an option down below for “Collation”. In that there are collation options in the drop down list. You can select “utf8_general_ci” and click Go. That’s it, your database charset is now changed to utf8_general_ci. You can go ahead and continue with the manual installation of Vtiger 7.1.0.

Alternatively, you can also select the database in phpmyadmin and then run the follow command:


Tuesday, February 13, 2018

Resize VMDK

How to resize vmdk / VDI ?

vboxmanage modifyhd Windows7.vmdk --resize 30720
gives the error
Progress state: VBOX_E_NOT_SUPPORTED
VBoxManage: error: Resize hard disk operation for this format is not implemented yet!

As u know, resizing of vmdk is tough then VDI, 

So its simple to

  • Change the disk format VMDK to VDI first, 
  • Resizi it, and 
  • Change the format VDI to VMDK again
Now use these commands:-
VBoxManage clonehd "source.vmdk" "cloned.vdi" --format vdi
VBoxManage modifyhd "cloned.vdi" --resize 31720
VBoxManage clonehd "cloned.vdi" "resized.vmdk" --format vmdk
The above will resize the hard disk up to 30GB (30 * 1024MB).