Posted by: kezhong | November 12, 2011

Install DirectAdmin on CentOS 5.7(x86_64)

Before Installing, we purchased the license, and got User ID and License ID.

Install base CentOS 5.7(x86_64) and update
# yum update -y

Install compile tools if you didn’t install “Development Tools” and “Develoment Libraries”
# yum install gcc-c++ gcc automake -y

Remove httpd, php and mysql if you have installed them
# yum remove httpd* php* mysql* -y

Disable firewall and selinux
# iptables -F
# iptables -X
# setenforce 0

Add “AllowUsers username” to /etc/ssh/sshd_config before you log out from root
username is your real user’ name

Download installation script from DirectAdmin official website and permit it run
# wget
# chmod u+x

Install DirectAdmin
# sh
*** 64-bit OS ***

* Have you run the pre-install commands? CTRL-C if not.
Please enter your Client ID : xxxxx
Please enter your License ID : xxxxx
Please enter your hostname \(\)
It must be a Fully Qualified Domain Name
Do *not* use a domain you plan on using for the hostname:
eg. don’t use Use instead.
Do not enter http:// or www

Enter your hostname (FQDN) :
Client ID:  xxxxx
License ID: xxxxx
Is this correct? (y,n) : y
The following ethernet devices/IPs were found. Please enter the name of the device you wish to use:


Enter the device name: eth0
Is the IP in your license? (y,n) : y

DirectAdmin will now be installed on: Enterprise 5.7
Is this correct? (must match license) (y,n) : y

You now have 2 options for your apache/php setup.

1: customapache: end-of-life software. Includes Apache 1.3, php 4 and frontpage.  **Not recommended**.  Will not work with newer OSs. Limited tech support.
2: custombuild 1.1:  newer software (recommended). Includes any Apache version, php 4, 5, or both in cli and/or suphp. Frontpage not available.
                 Post any issues with custombuild to the forum:

Enter your choice (1 or 2): 2
You have chosen custombuild 1.1.
–2011-11-11 14:47:00–
Connecting to||:80… connected.
HTTP request sent, awaiting response… 200 OK
Length: 289046 (282K) [text/plain]
Saving to: `/usr/local/directadmin/custombuild/build’

100%[=================================================================================================>] 289,046      855K/s   in 0.3s    

2011-11-11 14:47:01 (855 KB/s) – `/usr/local/directadmin/custombuild/build’ saved [289046/289046]

Would you like the default settings of apache 2.2 and php 5 cli? (y/n): y
Using the default settings for custombuild.
Would you like to search for the fastest download mirror? (y/n): y


make: *** [all-recursive] Error 1

Cannot find /usr/local/bin/php
Please recompile php with custombuild, eg:
cd /usr/local/directadmin/custombuild
./build all d

This appears to be a 64-bit system.
a common cause of http/php compile failures is mentioned here:

If you’re running CentOS (not freebsd or debian) and applies to you, then type:

ln -sf /usr/lib64/ /usr/lib/
ln -sf /usr/lib64/ /usr/lib/
ln -sf /usr/lib64/ /usr/lib/
cd /usr/local/directadmin/custombuild
./build all d


# ln -sf /usr/lib64/ /usr/lib/
# ln -sf /usr/lib64/ /usr/lib/
# ln -sf /usr/lib64/ /usr/lib/
# cd /usr/local/directadmin/custombuild
# ./build all d

Restart the httpd service
# /sbin/service httpd restart
Stopping httpd:                                            [FAILED]
Starting httpd: httpd: Syntax error on line 143 of /etc/httpd/conf/httpd.conf: Syntax error on line 21 of /etc/httpd/conf/extra/httpd-vhosts.conf: Could not open configuration file /etc/httpd/conf/ips.conf: No such file or directory

# cd /usr/local/directadmin
# ./directadmin i

# ./directadmin p
Permissions set

Restart the httpd service again, it will start

Accessing the Control Panel
DirectAdmin can be accessed at http://server.ip.address:2222 — use the Admin username/password specified in the setup.txt file in your scripts directory.



  1. […] Install DirectAdmin on CentOS 5.7(x86_64) | Kezhong’s … – Nov 12, 2011 · Before Installing, we purchased the license, and got User ID and License ID. Install base CentOS 5.7(x86_64) and update # yum update -y Install compile …… […]

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s


%d bloggers like this: