Home » WHM/cPanel » WHM/cPanel backend files and directoires

WHM/cPanel backend files and directoires

WHM and cPanel backend files

bin- apache binaries are stored here – httpd, apachectl, apxs
/usr/local/apache/conf – configuration files – httpd.conf


/usr/local/apache/domlogs – domain log files are stored here


/usr/local/apache/include -header files

/usr/local/apache/libexec – shared object (.so) files are stored here – libphp4.so,mod_rewrite.so

/usr/local/apache/logs – apache logs – access_log, error_log, suexec_log

/usr/local/apache/man – apache manual pages



Cpanel script to restart apache – /scripts/restartsrv_httpd

Start httpd with ssl – /etc/init.d/httpd startssl


/etc/exim.conf – exim main configuration file

/etc/localdomains – list of domains allowed to relay mail

/var/log/exim_mainlog – incoming/outgoing mails are logged here

/var/log/exim_rejectlog – exim rejected mails are reported here
/var/log/exim_paniclog – exim errors are logged here

Mail queue: /var/spool/exim/input

Cpanel script to restart exim – /scripts/restartsrv_exim

Email forwarders and catchall address file – /etc/valiases/linuxpcfix.com

Email filters file – /etc/vfilters/linuxpcfix.com

POP user authentication file – /home/username/etc/domainname/passwd

catchall inbox – /home/username/mail/inbox

POP user inbox – /home/username/mail/domainname/popusername/inbox

POP user spambox – /home/username/mail/domainname/popusername/spam

Program : /usr/sbin/exim (suid – -rwsr-xr-x 1 root root )

Init Script: /etc/rc.d/init.d/exim

DNS – Named(Bind)
Program: /usr/sbin/named

Init Script: /etc/rc.d/init.d/named


db records:/var/named/


Program : /usr/bin/mysql

Init Script : /etc/rc.d/init.d/mysql

Conf : /etc/my.cnf, /root/.my.cnf

Data directory – /var/lib/mysql – Where all databases are stored.

Database naming convention – username_dbname (eg: john_sales)

Permissions on databases – drwx 2 mysql mysql

Socket file – /var/lib/mysql/mysql.sock, /tmp/ mysql.sock

Program :/usr/local/sbin/sshd

Init Script :/etc/rc.d/init.d/sshd


Log: /var/log/messages

Program :/usr/sbin/proftpd

Init Script :/etc/rc.d/init.d/proftpd

Conf: /etc/proftpd.conf

Log: /var/log/messages, /var/log/xferlog

FTP accounts file – /etc/proftpd/username – all ftp accounts for the domain are listed here

Program : /usr/sbin/pure-ftpd

Init Script :/etc/rc.d/init.d/pure-ftpd

Conf: /etc/pure-ftpd.conf

Anonymous ftp document root – /etc/pure-ftpd/ip-address


/usr/local/cpanel /3rdparty/ – tools like fantastico, mailman files are located here

/usr/local/cpanel /addons/ – AdvancedGuestBook, phpBB etc

/usr/local/cpanel /base/ – phpmyadmin, squirrelmail, skins, webmail etc

/usr/local/cpanel /bin/ – cpanel binaries

/usr/local/cpanel /cgi-sys/ – cgi files like cgiemail, formmail.cgi, formmail.pl etc

/usr/local/cpanel /logs/ – cpanel access log and error log

/usr/local/cpanel /whostmgr/ – whm related files
/var/cpanel/domain_keys/ – domains public/private keys

/var/cpanel/ – whm files

/var/cpanel/ bandwidth/ – rrd files of domains

/var/cpanel/username.accts – reseller accounts are listed in this files

/var/cpanel/packages – hosting packages are listed here

/var/cpanel/root.accts – root owned domains are listed here

/var/cpanel/suspended – suspended accounts are listed here

/var/cpanel/users/ – cpanel user file – theme, bwlimit, addon, parked, sub-domains all are listed in this files

/var/cpanel/zonetemplates/ – dns zone template files are taken from here

Important cpanel/whm files
/usr/local/apache/conf/httpd.conf – apache configuration file

/etc/exim.conf – mail server configuration file

/etc/named.conf – name server (named) configuration file

/etc/proftpd.conf – proftpd server configuration file

/etc/pure-ftpd.conf – pure-ftpd server configuration file

/etc/valiases/domainname – catchall and forwarders are set here

/etc/vfilters/domainname – email filters are set here

/etc/userdomains – all domains are listed here – addons, parked,subdomains along with their usernames

/etc/localdomains – exim related file – all domains should be listed here to be able to send mails

/var/cpanel/users/username – cpanel user file

/var/cpanel/cpanel.config – cpanel configuration file ( Tweak Settings )*

/etc/cpbackup-userskip.conf –

/etc/sysconfig/network – Networking Setup*

/etc/hosts –

/var/spool/exim –

/var/spool/cron –

/etc/resolv.conf – Networking Setup–> Resolver Configuration

/etc/nameserverips – Networking Setup–> Nameserver IPs ( FOr resellers togive their nameservers )

/var/cpanel/resellers – For addpkg, etc permissions for resellers.

/etc/chkserv.d – Main >> Service Configuration >> Service Manager *

/var/run/chkservd – Main >> Server Status >> Service Status *

/var/log/dcpumon – top log process

/root/cpanel3-skel – skel directory. Eg: public_ftp, public_html. (AccountFunctions–>Skeleton Directory )*

/etc/wwwacct.conf – account creation defaults file in WHM (Basic cPanel/WHMSetup)*

/etc/cpupdate.conf – Update Config *

/etc/cpbackup.conf – Configure Backup*

/etc/clamav.conf – clamav (antivirus configuration file )

/etc/my.cnf – mysql configuration file

/usr/local/Zend/etc/php.ini OR /usr/local/lib/php.ini – php configuration file

/etc/ips – ip addresses on the server (except the shared ip) (IP Functions–>Show IP Address Usage )*

/etc/ipaddrpool – ip addresses which are free

/etc/ips.dnsmaster – name server ips

/var/cpanel/Counters – To get the counter of each users.

/var/cpanel/bandwidth – To get bandwith usage of domains
/var/cpanel/mainip – WHM main IP address

cPanel/WHM scripts
/scripts/fixquotas fixes quota problems

/scripts/fullhordereset resets horde database to a fresh one – all previous user data are lost

/scripts/initquotas initializes quotas

/scripts/installzendopt installs zend optimizer

/scripts/killacct terminate an account – make sure you take a backup of the account first

/scripts/mailperm fixes permission problems with inboxes

/scripts/park to park a domain

/scripts/pkgacct used to backup an account

/scripts/restartsrv restart script for services

/scripts/restorepkg restores an account from a backup file ( pkgacct file)

/scripts/runlogsnow update logs of all users

/scripts/runweblogs update stats for a particular user

/scripts/securetmp secures /tmp partition with options nosuexec and nosuid

/scripts/suspendacct suspends an account

/scripts/unsuspendacct unsuspends a suspended account

/scripts/upcp updates cpanel to the latest version

/scripts/updatenow updates the cpanel scripts

/scripts/updateuserdomains updates userdomain entries

/scripts/addns :add a dns zone

/scripts/addfpmail :Add frontpage mail extensions to all domains without them

/scripts/addfpmail2 : Add frontpage mail extensions to all domains without them

/scripts/addnobodygrp :Adds the gorup nobody and activates security

/scripts/addpop :add a pop account

/scripts/addservlets :Add JSP support to an account (requires )

/scripts/addstatus : Internal use never called by user

/scripts/adduser : Ad a user to the system

/scripts/bandwidth : Bandwidth

/scripts/betaexim :Installs the latest version of exim

/scripts/biglogcheck :looks for logs nearing 2 gigabytes in size

/scripts/bsdcryptoinstall :Installs crypto on FreeBSD

/scripts/bsdldconfig : Configures the proper lib directories in FreeBSD

/scripts/bsdpkgpingtest :Tests the connection speed for downloading FreeBSD packages

/scripts/buildbsdexpect : Install expect on FreeBSD

/scripts/builddomainaddr : build domain address

/scripts/buildeximconf :Rebuilds exim.conf

/scripts/buildpostgrebsd-dev Installs postgresql on FreeBSD.

/scripts/chcpass change cpanel passwords

/scripts/easyapache recompile/upgrade apache and/or php

/scripts/exim4 reinstall exim and fix permissions

/scripts/fixcommonproblems fixes most common problems

/scripts/fixfrontpageperm fixes permission issues with Front Page

/scripts/fixmailman fixes common mailman issues

/scripts/fixnamed fixes common named issues

/scripts/fixndc fixes rndc errors with named


I am founder and webmaster of www.linuxpcfix.com and working as a Sr. Linux Administrator (Expertise on Linux/Unix & Cloud Server) and have been in the industry from last 7 years.

Leave a Reply

Your email address will not be published. Required fields are marked *


Time limit is exhausted. Please reload the CAPTCHA.

Categorized Tag Cloud