Posts Under Category: cPanel

Step 1:

Login to your server via SSH as root user.

Step 2

Use below command to create / export a database.

mysqldump database_name > /backup/database_name.sql


database_name -> The name of database of which you want to create backup.
/backup/database_name.sql -> Location and file name of database backup file.

Step 1

Login to your server as root via SSH.

Step 2

Enter below command to see list of all domains on your cPanel server.

cat /etc/localdomains

Our Recommended VPS Hosting


Step 1

Login to your server as root via SSH.

Step 2

By default, MySQL root password is saved in the /root/.my.cnf file.
Open this file using command.

cat /root/.my.cnf

Step 3

Here you can see your server mysql root password.
mysql-root password

Our Recommended VPS Hosting

cpanel-paper-lantern theme

In this small tutorial, I will explain how to show hidden files like .htaccess file in cPanel file manager under paper lantern theme.

Step 1

Login in cPanel and click File Manager to open file manager.

Step 2

In File Manager, Click Settings button located in top right corner. This will open settings popup window.

Step 3

On popup windows, check Show Hidden Files (dotfiles) and save. Done!!

Our Recommended VPS Hosting

cpanel update error
If you are getting following warning mail message from your cPanel server

Cpanel update failure in upcp
Running `/usr/local/cpanel/scripts/updatenow –upcp –log=/var/cpanel/updatelogs/update.1434952321.log` failed, exited with code 29 (signal = 0)

Cpanel update failure during updatenow

An error was detected which prevented updatenow from completing normally.
Please review the enclosed log for further details

[20150622.015201] Detected version ‘’ from version file.
[20150622.015201] Running version ‘’ of updatenow.
[20150622.015600] Using mirror ‘’ for host ‘’.
[20150622.015706] Using mirror ‘’ for host ‘’.
[20150622.020037] Using mirror ‘’ for host ‘’.
[20150622.020042] ***** FATAL: Unable to retrieve tier version info: Interrupted system call
[20150622.020042] The Administrator will be notified to review this output when this script completes
[20150622.020042] E Detected events which require user notification during updatenow. Will send iContact the log

Follow below steps to solve it.
Step 1:
Login to your server via SSH as user root.

Step 2:
Run following commands

/scripts/autorepair fix_duplicate_cpanel_rpms
/scripts/upcp --force

Step 3:
The above commands will update cPanel to latest stable version. After update is completed, login in WHM as root to check if everything is fine.


Our Recommended VPS Hosting

Wordpress security
I am seeing a lot of WordPress wp-login.php brute force attack these days. In this tutorial I will explain how to stop wp-login.php attack on a cPanel server. read more

In this tutorial, I will explain how to install cPanel on a new Linux server with CentOS installed on server.

Step 1:

Before installing cPanel, make sure you have a cPanel license for your VPS. If you do not have cPanel license, you can get a free 15-days trail license. It will take hardly 1-minute to get a 15-days trail licence.
Get cPanel 15-Days Trail Licence
read more

If Apache / HTTPS is using lots of memory on your server, here is how you can optimize Apache on your server / VPS.
Login as root in WHM and navigate to:

WHM Home >> Service Configuration >> Apache Configuration >> Global Configuration

And change value of Max Connections Per Child. Default value of Max Connections Per Child is 10,000
You should reduce this value to 1000. This will greatly reduce memory usage by Apache on your server.

Our Recommended VPS Hosting

For security reason, it is highly recommended that you use SSH key to login to your server via SSH instead of using root password. In this tutorial I will explain how to use SSH key to login to your server via SSH as root user.

Step 1:

Disable SSH Password Authorization Tweak. For security reason, you should disable SSH Password Authorization Tweak from:

WHM Home >> Security Center >> SSH Password Authorization Tweak


Step 2:

Now we will generate SSH key on a cPanel server. In WHM, navigate to:

WHM Home >> Security Center >> Manage root’s SSH Keys

And click Generate a New Key.

Step 3:

Fill the form for the new SSH key and click Generate Key button. Key name can be anything like your server name or your name. Use a strong key password. Please note, you should not use your root password.

Step 4:

In this step we will authorize the key. Click Manage Authorization for the key that we have generated.
And Authorize this new key.

Step 5:

In this step we will download the SSH key. Click View/Download Key under Private Keys section.

Enter the password that you have used in step 3 while generating this key and click convert button.

Step 6:

Copy the key and paste it on a notepad file. Save this text file as ssh.ppk on your computer. Please note, you may use different name for this ssh key file, but you must use .ppk extension.

Step 7:

So, we have generated and downloaded the SSH key. To use this SSH key with putty, we need to download Pageant.
Download Pageant

Step 8:

After downloading pageant, run it and click Add Key button.

Browse and select the ssh.ppk file that we have saved in step 6. Pageant will ask for password. Enter the password that you have used in step 3. This will add the key in pageant.

Step 9:

Start putty and try to login to your server as root.

Done!! You will get logged in to your server as root user.

Our Recommended VPS Hosting

For security reason, it is recommended that you change your server default SSH port from 22 to any other port. We have a detailed step by step tutorial for changing SSH port.
How to change SSH port of a Linux server

But if you have forgot your server new SSH port number, or if the new SSH port is blocked at server, here is how you can reset SSH port back to default 22 port on a cPanel server.

Step 1:

Login in WHM of your server using root.


Step 2:

Add following url at the end of your WHM url and run it.


The final url may be like:


Your server SSH port is now reset to default 22. If its not working, you may need to restart SSH from

WHM >> Restart Services >> SSH Server

Our Recommended VPS Hosting