1. Assign the Nameserver IP Addresses in WHM

In WHM, navigate to the left hand menu option “Basic cPanel/WHM Setup” and do the following:

Set the Primary Nameserver to ns1.yourdomain.com.
Then click Assign IP Address.
Repeat this for the Secondary Nameserver section, using ns2.yourdomain.com.
On the bottom of the page, click Save.

2. Setup the Nameserver a Records in WHM

While still in the “Basic cPanel/WHM Setup” section, do the following:

Beside the Primary Nameserver entry, click the “Add an A record entry for this nameserver” button
Repeat this for the Secondary Nameserver section

If you have already created a hosting account on your cPanel server for the domain you are using for your nameservers, performing the A record creation steps above should just create an entry for each nameserver in the existing DNS zone for the domain. However, if you have not yet(or do not intend to) set up a hosting account for the nameserver domain, the steps above will create individual DNS zones for each nameserver you have setup.

NOTE: If you are not hosting the main domain used for the nameservers on the same server, you will need to ensure you have added A records for the nameservers into the DNS zone for the domain with the domain hosting provider.
3. Restart the DNS Service

You should now just be able to restart the DNS service by doing the following:

Navigate to the “Restart Services” section in the left hand men;
Select “DNS Server (BIND/NSD)”
Hit the yes button in the right hand frame.

4. Register Your Nameserver Hosts with Your Domain Registrar

Before the nameservers we’ve just set up in WHM will work, you need to make sure that the correct details have been configured with your domain registrar. Each registrar handles the setting up of private nameservers differently so you should contact them to determine the method they use. Some let you control the setup from your domain control panel, however some require their administrators to create the nameserver entries for.

The most important point to make when contacting your registrar is that you wish to create private nameserver hosts to use with your own hosting server(some refer to these as child nameservers or domain hosts). Occasionally you will strike level 1 support staff who do not fully understand what you wish to do and may provide you incorrect instruction unless you specify this.

Once you know how they do it, you just need to set up the nameservers in their system as below:

Enter the names you would like to use; e.g. ns1.yourdomain.com and ns2.yourdomain.com
Enter the corresponding ip addresses details from your server that you wish to use.

Done!…Hopefully you now have working nameservers attached to your own domain.

For a cpanel server, this error can exist.

# cd /tmp

particular session file is owned by the user/group of nobody/nobody.


-rw------- 1 nobody nobody 48 Apr 20 04:29 sess_v6bo3v7ta0pirob4lrf8dmrqd2

the rest of the sessions look like the following.


-rw------- 1 domainname domainname 48 Apr 21 06:08 sess_cdc929c2bf695826d3b1e34fe1e65866

1. change the owner of the files to the right user/group or delete the ones that are wrong so that they can be recreated.

The reason they are getting created this way would be because the PHP instance on that site is running as an apache module instead of CGI or fCGI. so the scripts are being run as the apache webserver user a.k.a. nobody/nobody.

cPanel default backup system may fail to create and save backup of your server and send you following message:
The backup was not able to be completed because timed out waiting for /bin/backup to finish

Possible cause of the problem

Any old backup process is still running in background on the server.

Login to your server as root via SSH and execute following command


# /usr/local/cpanel/bin/backup --force

Most probably it will show you following type message:

Backup process currently running. Pid: 5378
Backup log file: /usr/local/cpanel/logs/cpbackup/1377934812.log

Solution

We need to kill the current running backup process. Note the Pid from above and run following command. Change xxxx to Pid number that you have got from above.


# kill -9 xxxx

cPanel backup should now run normally. You can force to start a new fresh backup process using below command:


# /usr/local/cpanel/bin/backup --force

Sending email with WHM/cPanel and the error is:

Number of failed recipients exceeded. Come back in a few hours.

Check WHM Settings

Login to WHM and go to Home » Server Configuration » Tweak Settings. Click the Mail tab. Find “Number of failed or deferred messages a domain may send before protections can be triggered [?]”

Change to a higher number and save.

Home » Service Configuration » Exim Configuration Manager » ACL Options

Ratelimit incoming connections with only failed recipients [?]
Ratelimit incoming SMTP connections that have only sent to failed recipients five separate connection times in the last hour.

Try turning off or if you are sending to multiple emails , verify the emails as this will be usually when multiple emails fail.

Also, check tweak settings

Home » Server Configuration » Tweak Settings
Also – there is this:

/var/cpanel/email_send_limits/max_deferfail_example.com

Deleting this file fixed the problem immediately. I’m guessing that the system should have deleted (or updated?) this file at some point, but didn’t.

And,

You can modify the “Maximum Hourly Email by Domain Relayed” and “Maximum percentage of failed or deferred messages a domain may send per hour.” values for an account via:

“WHM Home » Account Functions » Modify an Account”

# service exim restart
Shutting down clamd:                                       [FAILED]
Shutting down exim:                                        [FAILED]
Shutting down spamd:                                       [FAILED]


# service exim status
exim dead but subsys locked

There may be 2 issues to check.

-The presence of /etc/eximdisable, just move this file to eximdisable-bak and restart exim

# mv /etc/eximdisable /etc/eximdisable-bak
# service exim restart
Shutting down clamd:                                       [FAILED]
Shutting down exim:                                        [FAILED]
Shutting down spamd:                                       [  OK  ]
Starting clamd:                                            [  OK  ]
Starting exim:                                             [  OK  ]
0 processes (antirelayd) sent signal 9
/usr/local/cpanel/scripts/update_sa_rules: running in background

-The server being out of disk space and/or inodes, use ‘df -h’ and ‘df -i’ to confirm.

When you login to WHM and all the IP’s are missing.

If you have avahi improperly configured and running on your machine, it will withdraw the IPs on running either a) a reboot, or b) a network restart, so you can check you logs at /var/log/messages for avahi.
You can either stop avahi or properly register your IPs in avahi for these to be recognized. That service is what is causing the issue to occur.

Run the following to restore the IP addresses:

# /etc/rc.d/init.d/ipaliases restart

You may have to restart named to get DNS going again as well. Restart named again cause it cannot bind on the new IPs from ipaliases.

# service named restart

The issue of why is explained here:

https://forums.cpanel.net/threads/cpanel-loses-all-but-primary-ip-address.160393/

If you want everyone on the server to send out on the same IP, just add the following to


# nano /etc/mailips:
*: xxx.xxx.xxx.xxx

Then add the IP and it’s matching PTR to /etc/mail_reverse_dns:

# nano /etc/mail_reverse_dns
# xxx.xxx.xxx.xxx hostname.tld

This will tell Exim to use that IP for any sender on the server.

Restart exim

# service exim restart