Installing DirectAdmin on FreeBSD 9.2

Invader Zim

Verified User
Joined
Sep 4, 2004
Messages
188
I always start off with installing software that is needed later on, like
compat6x, wget, libtool, pcre, zip, bash, ImageMagick-nox11, openssh-portable and libxslt.

I also installed perl 5.16 and various cpan modules. Then download the directadmin install script, choose the options and off we go.

It might be worthy to note that this particular FreeBSD 9.2 system has been configured to use the new pkg (or pkg-ng) as I get some error messages during initial startup of the installer script:
Code:
DirectAdmin will now be installed on: FreeBSD 9.2
beginning pre-checks, please wait...
pkg_info: the package info for package 'ImageMagick-nox11-6.8.9.3_2,1' is corrupt
pkg_info: the package info for package 'aspell-0.60.6.1_4' is corrupt
pkg_info: the package info for package 'autoconf-2.69' is corrupt
pkg_info: the package info for package 'bash-4.3.18_2' is corrupt
pkg_info: the package info for package 'bison-2.7.1,1' is corrupt
pkg_info: the package info for package 'cmake-2.8.12.1_4' is corrupt
pkg_info: the package info for package 'cmake-modules-2.8.12.1_1' is corrupt
pkg_info: the package info for package 'compat6x-amd64-6.4.604000.200810_3' is corrupt
pkg_info: the package info for package 'cups-client-1.7.2' is corrupt
pkg_info: the package info for package 'cups-image-1.7.2' is corrupt
pkg_info: the package info for package 'expat-2.1.0_1' is corrupt
pkg_info: the package info for package 'fftw3-3.3.3_1' is corrupt
pkg_info: the package info for package 'fontconfig-2.11.0_3,1' is corrupt
pkg_info: the package info for package 'freetype2-2.5.3_2' is corrupt
pkg_info: the package info for package 'gettext-0.18.3.1_1' is corrupt
pkg_info: the package info for package 'ghostscript9-nox11-9.06_7' is corrupt
pkg_info: the package info for package 'giflib-nox11-4.2.3_2' is corrupt
pkg_info: the package info for package 'glib-2.36.3_3' is corrupt
pkg_info: the package info for package 'gmake-3.82_1' is corrupt
pkg_info: the package info for package 'gsfonts-8.11_6' is corrupt
pkg_info: the package info for package 'help2man-1.43.3_1' is corrupt
pkg_info: the package info for package 'icu-53.1' is corrupt
pkg_info: the package info for package 'jbig2dec-0.11_1' is corrupt
pkg_info: the package info for package 'jbigkit-2.1_1' is corrupt
pkg_info: the package info for package 'joe-3.7_2,1' is corrupt
pkg_info: the package info for package 'jpeg-8_5' is corrupt
pkg_info: the package info for package 'lcms2-2.6_3' is corrupt
pkg_info: the package info for package 'ldns-1.6.17_1' is corrupt
pkg_info: the package info for package 'libffi-3.0.13_1' is corrupt
pkg_info: the package info for package 'libfpx-1.3.1.4' is corrupt
pkg_info: the package info for package 'libgcrypt-1.5.3_2' is corrupt
pkg_info: the package info for package 'libgpg-error-1.13_1' is corrupt
pkg_info: the package info for package 'libiconv-1.14_3' is corrupt
pkg_info: the package info for package 'libidn-1.28_1' is corrupt
pkg_info: the package info for package 'liblqr-1-0.4.1_7' is corrupt
pkg_info: the package info for package 'libltdl-2.4.2_3' is corrupt
pkg_info: the package info for package 'libpaper-1.1.24_2' is corrupt
pkg_info: the package info for package 'libslang2-2.2.4_6' is corrupt
pkg_info: the package info for package 'libssh2-1.4.3_2,2' is corrupt
pkg_info: the package info for package 'libtool-2.4.2_3' is corrupt
pkg_info: the package info for package 'libwmf-nox11-0.2.8.4_11' is corrupt
pkg_info: the package info for package 'libxml2-2.9.1_1' is corrupt
pkg_info: the package info for package 'libxslt-1.1.28_3' is corrupt
pkg_info: the package info for package 'm4-1.4.17_1,1' is corrupt
pkg_info: the package info for package 'mc-4.8.12_2' is corrupt
pkg_info: the package info for package 'openjpeg-2.1.0' is corrupt
pkg_info: the package info for package 'openssh-portable-6.6.p1_2,1' is corrupt
pkg_info: the package info for package 'openssl-1.0.1_13' is corrupt
pkg_info: the package info for package 'p5-Locale-gettext-1.05_3' is corrupt
pkg_info: the package info for package 'pcre-8.34_1' is corrupt
pkg_info: the package info for package 'perl5-5.16.3_11' is corrupt
pkg_info: the package info for package 'pkgconf-0.9.6' is corrupt
pkg_info: the package info for package 'png-1.5.18' is corrupt
pkg_info: the package info for package 'python27-2.7.6_4' is corrupt
pkg_info: the package info for package 'screen-4.2.1_3' is corrupt
pkg_info: the package info for package 'svgalib-1.4.3_7' is corrupt
pkg_info: the package info for package 'tiff-4.0.3_4' is corrupt
pkg_info: the package info for package 'webp-0.4.0' is corrupt
pkg_info: the package info for package 'wget-1.15' is corrupt
pkg_info: the package info for package 'zip-3.0' is corrupt
adding perl5.8 ...
Error: Unable to get http://files.directadmin.com/services/packages-9.0-release/Latest/perl5.8.tbz: Not Found
pkg_add: unable to fetch 'http://files.directadmin.com/services/packages-9.0-release/Latest/perl5.8.tbz' by URL

Also for some reason it wants to download packages for FreeBSD 9.0 like perl 5.8. Seeing as that was released on "15-Dec-2008", that doesn't look like a good option to me. But perl is already installed:

Code:
root@blank:~ # perl -v

This is perl 5, version 16, subversion 3 (v5.16.3) built for amd64-freebsd-thread-multi

When it comes to php, I get the following:

Code:
Configuring SAPI modules
checking for AOLserver support... no
checking for Apache 1.x module support via DSO through APXS... no
checking for Apache 1.x module support... no
checking whether to enable Apache charset compatibility option... no
checking for Apache 2.0 filter-module support via DSO through APXS... no
checking for Apache 2.0 handler-module support via DSO through APXS...

Sorry, I cannot run apxs.  Possible reasons follow:

1. Perl is not installed
2. apxs was not found. Try to pass the path using --with-apxs2=/path/to/apxs
3. Apache was not built using --enable-so (the apxs usage page is displayed)

The output of apxs follows:
./configure: apxs: not found
configure: error: Aborting

*** There was an error while trying to configure php. Check the configure/ap2/configure.php5 file

*******************************************
*******************************************

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:
http://help.directadmin.com/item.php?id=213

*******************************************
*******************************************

Since this is a fresh install the configure/ap2/configure.php5 file is standard:

Code:
#!/bin/sh
./configure \
        --with-apxs2 \
        --with-curl=/usr/local/lib \
        --with-gd \
        --with-ttf \
        --with-gettext \
        --with-jpeg-dir=/usr/local/lib \
        --with-freetype-dir=/usr/local/lib \
        --with-kerberos \
        --with-openssl \
        --with-mcrypt \
        --with-mhash \
        --with-mysql=/usr/local/mysql \
        --with-mysqli=/usr/local/mysql/bin/mysql_config \
        --with-pdo-mysql=/usr/local/mysql \
        --with-pcre-regex=/usr/local \
        --with-pear \
        --with-png-dir=/usr/local/lib \
        --with-xsl \
        --with-zlib \
        --with-zlib-dir=/usr/local/lib \
        --with-iconv=/usr/local \
        --enable-bcmath \
        --enable-calendar \
        --enable-exif \
        --enable-ftp \
        --enable-gd-native-ttf \
        --enable-magic-quotes \
        --enable-safe-mode \
        --enable-soap \
        --enable-sockets \
        --enable-mbstring \
        --enable-zip \
        --enable-wddx

and because php failed to build I get the message "Cannot find /usr/local/bin/php".

I could really use some help here.
 
Do you get any errors when you execute "./build apache"?
 
Code:
Make complete
Installing Apache...
Making install in srclib
Making install in apr
/usr/local/directadmin/custombuild/httpd-2.2.27/srclib/apr/build/mkdir.sh /etc/httpd/lib /usr/bin /var/www/build  /etc/httpd/lib/pkgconfig /usr/include/apache
mkdir /var/www
mkdir: /var/www: File exists
mkdir /var/www/build
mkdir: /var/www: No such file or directory
*** [install] Error code 1

Stop in /usr/local/directadmin/custombuild/httpd-2.2.27/srclib/apr.
*** [install-recursive] Error code 1

Stop in /usr/local/directadmin/custombuild/httpd-2.2.27/srclib.
*** [install-recursive] Error code 1

Stop in /usr/local/directadmin/custombuild/httpd-2.2.27.
Restoring certificate and key, and turning on httpd for DirectAdmins's check.
Checking to ensure /etc/httpd/conf/ssl.crt/server.ca is set.
grep: /usr/local/directadmin/conf/directadmin.conf: No such file or directory
Checking to ensure /etc/httpd/conf/ssl.crt/server.ca is set.
grep: /usr/local/directadmin/conf/directadmin.conf: No such file or directory
[: : bad number
grep: /usr/local/directadmin/conf/directadmin.conf: No such file or directory
[: : bad number
Unable to read config file. Check the file permissionsUnable to read config file. Check to make sure that /usr/local/directadmin/conf/directadmin.conf.lock doesn't exist
Using 185.10.96.100 for your server IP
ls: /usr/local/directadmin/data/users/*/httpd.conf: No such file or directory
mkdir: /var/www: No such file or directory
./build: cannot create /var/www/html/index.html: No such file or directory
Restarting apache.
Stopping httpd:         [ FAILED ]
Starting httpd: daemon: /usr/sbin/httpd: No such file or directory
        [ OK ]
 
Whilst I have your attention, how about adding a choice to install apache 2.4 and php 5.4 (and perhaps 5.5) on cb 1.2? apache 2.2 and php 5.3 are so last year. ;)
 
This got my attention:
Code:
mkdir /var/www
mkdir: /var/www: File exists
mkdir /var/www/build
mkdir: /var/www: No such file or directory
What is /var/www? It should be a directory.. perhaps it's a file, hence the directory couldn't be created.
Code:
ls -la /var
ls -lad /var/www

For apache 2.4, and php 5.5, at install time you can either select CustomBuild 2.0, or if you use custombuild 1.2, you can select "n" when it asks if you want to use the defaults, then specify the higher apache/php values.

John
 
/var/www is a symlink to /data/var/www, /data is on a slice with much more disk space than /.

I gave it another go, without the symlink. Didn't work out I'm afraid.

Code:
blank# ./setup.sh client# license# fqdn em0 ipaddress
*** 64-bit OS ***
*** that being said, this should be a FreeBSD 7, 8 or 9 system. ***


*** DirectAdmin already exists ***
    Press Ctrl-C within the next 10 seconds to cancel the install
    Else, wait, and the install will continue, but will destroy existing data


Using em0
Using ipaddress

DirectAdmin will now be installed on: FreeBSD 9.0
beginning pre-checks, please wait...
pkg_info: the package info for package 'bind99-9.9.5P1_3' is corrupt
pkg_info: the package info for package 'binutils-2.24' is corrupt
pkg_info: the package info for package 'bison-2.7.1,1' is corrupt
pkg_info: the package info for package 'cmake-2.8.12.1_4' is corrupt
pkg_info: the package info for package 'cyrus-sasl-2.1.26_8' is corrupt
pkg_info: the package info for package 'flex-2.5.39_1' is corrupt
pkg_info: the package info for package 'gcc-ecj-4.5' is corrupt
pkg_info: the package info for package 'gcc49-4.9.1.s20140702' is corrupt
pkg_info: the package info for package 'gettext-0.18.3.1_1' is corrupt
pkg_info: the package info for package 'gmake-3.82_1' is corrupt
pkg_info: the package info for package 'gmp-5.1.3_2' is corrupt
pkg_info: the package info for package 'indexinfo-0.2' is corrupt
pkg_info: the package info for package 'mpc-1.0.2' is corrupt
pkg_info: the package info for package 'mpfr-3.1.2_2' is corrupt
pkg_info: the package info for package 'openssl-1.0.1_13' is corrupt
pkg_info: the package info for package 'screen-4.2.1_3' is corrupt
adding gd ...
Fetching http://files.directadmin.com/services/packages-9.0-release/Latest/gd.tbz... Done.
pkg_add: package 'gd-2.0.35_7,1' or its older version already installed
chmod: /usr/local/bin/webalizer: No such file or directory
--2014-07-08 20:12:26--  http://www.directadmin.com/named.conf.freebsd
Resolving www.directadmin.com (www.directadmin.com)... 216.144.255.179
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 566 [text/plain]
Saving to: '/etc/namedb/named.conf'

100%[===================================================================>] 566         --.-K/s   in 0s

2014-07-08 20:12:27 (28.3 MB/s) - '/etc/namedb/named.conf' saved [566/566]

net.inet6.ip6.v6only: 0 -> 0
 8 Jul 20:12:28 ntpdate[54948]: step time server 132.246.11.227 offset 0.000086 sec
--2014-07-08 20:12:28--  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Resolving www.directadmin.com (www.directadmin.com)... 216.144.255.179
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:29--  (try: 2)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:31--  (try: 3)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:34--  (try: 4)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:38--  (try: 5)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:43--  (try: 6)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:49--  (try: 7)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:12:56--  (try: 8)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:13:04--  (try: 9)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:13:13--  (try:10)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:13:23--  (try:11)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:13:33--  (try:12)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:13:43--  (try:13)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:13:53--  (try:14)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:14:03--  (try:15)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:14:13--  (try:16)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:14:23--  (try:17)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:14:34--  (try:18)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:14:44--  (try:19)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Retrying.

--2014-07-08 20:14:54--  (try:20)  https://www.directadmin.com/cgi-bin/daupdate?uid=1824&lid=104070
Connecting to www.directadmin.com (www.directadmin.com)|216.144.255.179|:443... failed: Can't assign requested address.
Giving up.

Cannot find the DirectAdmin binary.  Extraction failed

If you see an error that says to add --no-check-certificate, recompile wget:
http://help.directadmin.com/item.php?id=119
 
Last edited:
Turns out the "Can't assign requested address" comes when you fill in the wrong source address.
 
Installation goes a bit better now, until curl gets built

Code:
libtool: compile:  gcc -DHAVE_CONFIG_H -I../include -I../include -I../lib -I../lib -I/usr/kerberos/include -g0 -O2 -Wno-system-headers -MT base64.lo -MD -MP -MF .deps/base64.Tpo -c base64.c  -fPIC -DPIC -o .libs/base64.o
In file included from base64.c:43:
urldata.h:139:21: error: libssh2.h: No such file or directory
urldata.h:140:26: error: libssh2_sftp.h: No such file or directory
In file included from base64.c:43:
urldata.h:543: error: expected specifier-qualifier-list before 'LIBSSH2_SFTP_ATTRIBUTES'
*** Error code 1

Stop in /usr/local/directadmin/customapache/curl-7.19.3/lib.
*** Error code 1

Stop in /usr/local/directadmin/customapache/curl-7.19.3/lib.
*** Error code 1

Stop in /usr/local/directadmin/customapache/curl-7.19.3.
*******************************************
*******************************************
 
Last edited:
Please try:
Code:
cd /usr/local/directadmin/custombuild
./build update
perl -pi -e 's|${MAINVER} -ge 10|${MAINVER} -ge 9|' build
./build all d
 
Back
Top