Changing A Records in Cpanel

How to Change A Records in cPanel ?

The article defines steps for Updating an A record in cPanel for a particular domain name.

The Domain Name System is complex in itself. Using the cPanel control panel, users can easily manage the DNS’s. The DNS is added to the WHM interface for that purpose. Updating the A records is one of the regular tasks carried out in the DNS settings. cPanel simplifies this process to a large extent.

We’ve made certain assumptions while writing the information below,
We assume that you have BIND running on your Linux web hosting Server,
You have the required knowledge of DNS and its entries and
More importantly, we assume that you are aware of the consequences of updating the zone file with incorrect details.

You may even prefer to lower the TTL- Time To Live value for the particular domains zone file, before proceeding with updating the DNS record.Affordable Web Hosting

Steps to Update A Records

Step 1 – Login to WHM
Step 2 – Find and Hit the Edit DNS Zone option. You’d find it under DNS Functions
Step 3Choose the Domain for which you wish to make the changes and hit the Edit tab
Step 4 – Look for the line about the ‘ftp’ subdomain, then Update the IP address box to show the new address.
Step 5Recheck the details that you’ve populated, then click the Save button to commit and apply the changes.

Before initiating the process of making the changes, if you’d lowered TTL for that domain, the changes made should start propagating shortly. This indicates to all clients and caching nameservers how often it should check back with the authoritative nameserver for updated information. When you are about to make any changes to the DNS zone file lowering the TTL value would instruct the caching servers to check back more frequently. Typically 300 seconds (5 minutes) is good primary IP address changes. This should help you keep the downtime to the minimum.

If you need any assistance regarding DNS or changing the A records for your domain, please feel free to contact our Support Department via. our 24×7 Live Chat available at our website or raise a ticket from client area (helpdesk).

Moving Tables from One MySQL Database to Another Using Command Line Interface

Moving all of the tables from one mysql database to another is very easy. It can be done using phpMyAdmin to dump the database to a .sql file. However, in this tutorial, we are going to dump the database to a .sql file using the command line interface. With the command line, you can complete your task more faster compare to the phpMyAdmin method.

In order to start, you need to be a user who has full privileges in both the databases or should be a root user. Usually, it is not necesssary to use username and password when dumping a mysql database in Linux cPanel Hosting. It won’t prompt you for the password and automatically takes the username and password. Follow the below steps:

How to Dump the MySQL Database to an SQL file

Enter the following command to dump a database:

mysqldump database_name > Database_name.sql

For example, suppose you wanted to dump a database called “eukblog”.

mysqldump eukblog > eukblog.sql

Now, since you have the database backup ready, simply import the contents to your destination database (i.e. another database).

mysql new_database_name < Database_name.sql

Here we are going to use the new destination database known as “neweukblog”.

For Example:

mysql neweukblog < eukblog.sql

Once the transfer is completed, you will see two databases that are similar, but with different names.

cPanel Hosting UK

Changing the Default Text Editor in Linux

A default text editor comes with respective Linux distributions. Such as nano, vim, ed etc. Users can change it according to their preferences by changing the $EDITOR environment variable.

Changing default editor from nano to vimCloud Hosting UK

You must open the .bashrc file and append the line as shown below.

#FILE: .bashrc

export EDITOR=”vim”

Different command line applications alike the crontab, svn and visudo make use of the $EDITOR variable to choose the default text editor.

How to change default text editor in Ubuntu

In an operating system such as Ubuntu, you need to use a script inorder to change the default text editor known as the update-alternatives. Below is the description of how you can go about doing it.

Open a terminal and enter the below command :

$ sudo update-alternatives –config editor

You may also do this by logging in as root to avoid using sudo to run the command. You then be prompted for password, entering the correct password you would be presented with a list of console text editors found on your system. You may choose between them and change it to using as a default text editor.

[sudo] password for yourserver : *****

There are 3 alternatives which provide `editor’.

Selection Alternative

1 /usr/bin/vim.tiny

2 /bin/ed

*+ 3 /bin/nano

Press enter to keep the default[*], or type selection number: 1

Furthermore, you may change the default text editor and apply it all across the system (for all users) or choose to change it for a particular user. Following is the procedure for the two :

A. System Wide

Run the following command and choose the one of your choice

$ sudo update-alternatives –config editor

B. User Level

If you are a user with limited privileges or a server admin who only wishes to change the text editor for particular users, you can add an alias for editor to for example vim.

For that purpose, you must Open and edit ~/.bashrc with adding alias editor=vim

You may test it now. Once you open a bash prompt, you’d see the editor has changed according to your preference.

If you need any assistance with this, please contact our support department via. online chat available at our website OR raise a ticket stating your requirements with the preferred text editor.

Cloud Servers

Installing ConfigServer ModSecurity Control (cmc) on Dedicated Server

Usually, some of the open source applications may not function properly as the mod security is enabled on the server. It can be enabled or disabled in both the ways either via .htaccess or from WHM control panel. However its necessary to have ConfigServer ModSecurity Control (cmc) Plugin already installed in your WHM on dedicated server.

In this tutorial we are going to show you Steps to Install ConfigServer ModSecurity Control (cmc) for your WHM:

Step 1: Log in to your dedicated server via SSH using root login.

Step 2: Make sure you download the latest version of ConfigServer ModSecurity Control (cmc) from the following source:

http://www.configserver.com/free/cmc.tgz

Step 3: Untar the GZip’ed Tar format file with the following command:

tar -xzf cmc.tgz

Step 4: Now, change the directory to the extracted folder:

cd cmc/

Setp 5: Simply execute the installer entering the following command:

sh install.sh

Step 6: Once it is installed, you can login to your WHM control panel and scroll to the bottom of the left hand menu and there you will find the “ConfigServer Mod Security”

How to Reset Plesk Admin Password Using Shell

Passwords are very case sensitive and most of the times it happens that users forgets important passwords. Here in this tutorial we are going to show how to reset plesk root password using shell and command prompt.

Reset Plesk Root Password with Shell : Plesk Linux

This can be done using the “ch_admin_passwd” binary.

[root@plesklinux root]# cd /usr/local/psa/admin/bin/

[root@plesklinux bin]# ./ch_admin_passwd —help

./ch_admin_passwd: Utility to set Plesk adminstrator’s password

Gets password from the environment variable PSA_PASSWORD

Password should be from 5 to 16 symbols and must not contain login name, whitespace, quotes or national characters

[root@plesklinux bin]# export PSA_PASSWORD=’newpass’

[root@plesklinux bin]# echo $PSA_PASSWORD
newpass

[root@plesklinux bin]# ./ch_admin_passwd

[root@plesklinux bin]# export PSA_PASSWORD=

[root@plesklinux bin]# cat /etc/psa/.psa.shadow
newpass

[root@plesklinux bin]#

Reset Plesk Admin Password Using Command Prompt: Plesk Windows

Plesk Windows Root Password can also be retrieved and reset with the help of the plesksrvclient binary located in the %plesk_bin% directory.

Open your Windows Command Prompt and type the following command and hit the Enter button:

cd %plesk_bin%

It will enter in to the directory where the Plesk’s Bin folder is located.

In order to get the existing root password, enter:

plesksrvclient.exe -get

It will show the existing password on a popup window. To copy it on clipboard click the Ok button.

To set a new password, enter above command without “-get”:

plesksrvclient.exe <NEWPASS>

It will enable you to insert a new desired password for your Plesk Admin login.

cPanel Web Hosting

«Create And Restore BackUp in Softaculous »

Cloud HostingHow to Create And Restore BackUp in Softaculous ?

Steps to create a backup in Softaculous

Softaculous comes pre-installed with our cPanel hosting control panel. It enables users with taking backups of the applications from the web-based interface. Following is the procedure to secure a backup in Softaculous

Step 1 – Login to your cPanel Control Panel and look for the Softaculous icon listed under Software/Services
Step 2 – Select All Installations
Step 3 – All the installed applications would be listed. You must then choose the application which you intend to backup.
Step 4 – Hit the Backup button;

Steps to restore a Softaculous backup

Following is the procedure to secure a backup in Softaculous

Step 1 – Login to your cPanel Control Panel and look for the Softaculous icon listed under Software/Services
Step 2 – Look for an option titled “Backups and Restore” and click it
Step 3 – You’d be presented with a list of all available backups. Choose the particular application which you intend to Restore.
Step 4 – Hit the “Restore” button.

If you need any assistance with backing up or restoration on your Softaculous installations, please contact our support department via. 24×7 Live Chat available at our website or raise a support request with Linux Technical Department via. helpdesk. Kindly state the domain name, your customer Id. and IP when raising a support ticket.

Steps to Kill a Process in Linux/Unix

A computer process refers to a computer program having a unique process identification or also called as PID. Basically, on the Linux operating system, a process may be running in the background, foreground or may be in a suspended state. It might possible that on Linux, the OS shell may not return the prompt to the end-user unless the current process that is running is finished. As a result, many processes that take a substantial amount of time to execute and keep you from utilizing the console until the process is finished running.

The most common issue that arises for Linux users is to kill or background a process so that other tasks are conducted on the system. In order to kill a process a signal has to be sent using the Linux kill command.

How to kill a linux process using “kill” command?

Step One: Enter the below linux command to get the PID for the running process on your system which you want to kill.

ps myProcess

Once you enter the above command it will return with something similar to the following:

PID TTY TIME CMD
1234 dz07 0:50 edit myBook
1235 dz07 0:47 -csh

Step Two: Enter the following linux kill command to terminate the first process mentioned in the example above:

kill -1 1234

Enter the following command to terminate the second active process:

kill -1 1235

Step Three: It is possible that the kill -1 does not work, in such a case, you will need to use the -9 argument to clear the process from your system. Use the following command:

kill -9 1234
kill -9 1235

Step Four: Instead you can also kill all the instances of a given process by using the killall command. Enter as shown below:

killall <pname>

<pname> refer to the process name.

This tutorial is applicable only on VPS or a Dedicated Server, as it requires root access to the server.

How to Use sudo to Assign Root Access to a User on a Linux Server

Using sudo to Assign Root Access to a User on a Linux Server

Attimes you are required to offer Root access for a particular account having limited privileges on a server. You must follow the below steps to assign Root Access to a particular user using sudo.

Step 1 : Login to the server as root.

Step 2 : Run the following command :

root@host [~]# visudo

Step 3 : The screen displayed would be of the sudoers file in the vi editor. You must include the belwow line into this file to assign complete root privileges to an account (in our case it is accountname).:

accountname ALL=(ALL) ALL

Step 4 : If you do not intend to offer the complete access but be able to run a particular list of commands, you may create a command alias in your sudoers file, for example:

User_Alias ADMINS = accountname
Cmnd_Alias HTTPD = /etc/init.d/httpd
ADMINS ALL = HTTPD

With this, you should be able to create a group of users whom you can then assign command aliases to. You only need to ensure that the users are separated using a comma (,).

The Cmnd_Alias would show you a list of different commands that the users of a particular Alias can run. You may then choose the user alias and assign the command alias.

The above would ask the user to enter his/er password each time sudo is run. Though if don’t want the system to ask for a password each time, you may replace ADMINS ALL = HTTPD in the last line with the following :

ADMINS ALL = NOPASSWD: HTTPD

Incase you need any assistance with this, please contact our support department via. 24×7 Live Chat available at www.eukhost.com

Affordable web hosting

How to Fix cPanel Error: Sorry, that domain is already setup (remove it from httpd.conf?)

It may be possible that you may come across an issue of adding a domain via WHM create account function and get the following error:

Sorry, that domain is already setup (remove it from httpd.conf)

Getting the above error simply means that the domain still exists in the virtualhost in apache configuration file known as httpd.conf . There are two main reasons why it has shown you this error.

Reason One:

It might be possible that the domain you are trying to create is being used as a primary domain for one of the accounts or may be it has been used as an addon domain or parked for other domains and accounts.

Reason Two:

Or it may be possible that you are facing some technical issues such as the addon, parked or the primary domain is not removed completely from the system after using the removing function.

If the error is due to the first reason, you can easily remove the domain name from the cPanel account and even if it is not removed and come up with the following error:

Error from park wrapper: Sorry, you do not control the domain

Follow the steps given below:

First you should find out who owns the domain, enter the following command:

/scripts/whoowns example.com

Even if it didn’t show any results, enter the following command string:

grep example.com /var/cpanel/users/*

You will get the result something like the following:

root@server [~]# grep example.com /var/cpanel/users/*
/var/cpanel/users/exam:XDNS1=example.com

As you can see, we could easily find the owner of the domain (example.com), the next step is to edit the following files with the corresponding user and remove the lines associated with the domain (example.com) you have problem with.

/var/named/example.com.db
Remove the virtualhost for example.com from /etc/httpd/conf/httpd.conf
/var/cpanel/users/username [remove entries related to domain]
/etc/userdomains
/etc/localdomains
vim /etc/named.conf [remove entries related to domain]
Remove DNS entry in WHM
Run /scripts/updateuserdomains as root on the server

That’s it!

cPanel Web Hosting

How to Backup and Restore Individual cPanel Account via SSH

Backing up your hosting account is very necessary for your business to survive on Internet. Whether it is a small or large business, you must backup all of your data regularly at least once a week. cPanel provides some great ready made scripts which will help you make your tasks more easy. Commands such as pkgacct is basically used for backing up cpanel web hosting accounts and restorepkg for restoring cpanel accounts via the SSH or command line interface.

How to create backup of Individual cPanel Account via SSH?

Step 1: Log-in to the SSH as Root user.

Step 2: Enter the following command string on the command line interface:

/scripts/pkgacct username

[Note: The account backup will be created in the current directory you are in.]

How to Restore the Individual cPanel Account via SSH?

Step 1: To restore the cPanel account backups, enter the following command

/scripts/restorepkg username

[Note: In order to restore the data, you need to be in the directory where the backup file is stored.]

This is the easiest way to backup and restore individual cPanel web hosting accounts via command line interface.

« Previous Page« Previous entries « Previous Page · Next Page » Next entries »Next Page »