fantu
2008-12-22 1bb82f5e3e482834f308778d70faa791a9aef1e8
commit | author | age
ba0264 1 Installation
239490 2 ------------
ba0264 3
239490 4 It is recommended to use a clean (fresh) Ubuntu 8.04 LTS install where you selected no additional packages or servers during setup. Then follow the steps below to setup your server with ISPConfig 3:
ba0264 5
T 6 Now become root user by executing:
7
8 sudo su
9
10 and entering the password of the user that you created during setup.
11
12 Edit the file /etc/apt/sources.list and comment out the line beginning with "deb cdrom:....", then run:
13
14 apt-get update
15 apt-get -u upgrade
16
17
18 1) Install Postfix, Courier, Saslauthd, MySQL, phpMyAdmin with the following command line (on one line!):
19
871b33 20 apt-get install postfix postfix-mysql postfix-doc mysql-client mysql-server courier-authdaemon courier-authlib-mysql courier-pop courier-pop-ssl courier-imap courier-imap-ssl libsasl2-2 libsasl2-modules libsasl2-modules-sql sasl2-bin libpam-mysql openssl courier-maildrop getmail4
ba0264 21
T 22 Answer the questions from the package manager as follows.
23
871b33 24 Enter the mysql root password.
ba0264 25 Create directories for web-based administration ? <-- No
T 26 General type of configuration? <-- Internet site
27 Mail name? <-- server1.mydomain.tld
28  SSL certificate required <-- Ok
29
30 ...use your own domain name of course ;)
31
239490 32
ba0264 33 2) Install Amavisd-new, Spamassassin and Clamav (1 line!):
T 34
35 apt-get install amavisd-new spamassassin clamav clamav-daemon zoo unzip bzip2 arj nomarch lzop cabextract apt-listchanges libnet-ldap-perl libauthen-sasl-perl clamav-docs daemon libio-string-perl libio-socket-ssl-perl libnet-ident-perl zip libnet-dns-perl
36
37
38 3) Install apache, PHP5 and phpmyadmin (1 line!):
39
40 apt-get install apache2 apache2.2-common apache2-doc apache2-mpm-prefork apache2-utils libexpat1 ssl-cert libapache2-mod-php5 php5 php5-common php5-gd php5-mysql php5-imap phpmyadmin php5-cli
41
42 Then run the following to enable the Apache modules:
43
44 a2enmod suexec
45 a2enmod rewrite
46 a2enmod ssl
1f0c31 47 a2enmod include
ba0264 48
239490 49
R 50 3.1) Optional: Install SuPHP
871b33 51
T 52 apt-get install libapache2-mod-suphp
53
54 vi /etc/suphp/suphp.conf
55
56 set docroot to:
57
58 docroot=/var/clients
59
60 Change:
61
62 application/x-httpd-php=php:/usr/bin/php-cgi
63
64 to:
65
66 x-httpd-php=php:/usr/bin/php-cgi
67
68
ba0264 69 4) Install pure-ftpd and quota
T 70
71 First we have to make sure that the capability module is loaded in the kernel
72
73 modprobe capability
74 echo 'capability' >> /etc/modules
75
76 Then we install pureftpd and quota.
77
78 apt-get install pure-ftpd-common pure-ftpd-mysql quota quotatool
79
80 echo 'yes' > /etc/pure-ftpd/conf/DontResolve
81
239490 82
ba0264 83 5) Install mydns
T 84
85 apt-get install g++ libc6 gcc gawk make texinfo libmysqlclient15-dev
86
87 cd /tmp
239490 88 wget http://heanet.dl.sourceforge.net/sourceforge/mydns-ng/mydns-1.2.8.15.tar.gz
R 89 tar xvfz mydns-1.2.8.15.tar.gz
871b33 90 cd mydns-1.2.8
ba0264 91 ./configure
T 92 make
93 make install
94
d75f08 95 Now create the start / stop script for mydns:
T 96
97 vi /etc/init.d/mydns
98
99 and enter the following lines (between the ----- lines):
100
101 ------------------------------------------------------
239490 102 #! /bin/bash
d75f08 103 #
T 104 # mydns         Start the MyDNS server
105 #
106 # Author:       Philipp Kern <phil@philkern.de>.
107 #               Based upon skeleton 1.9.4 by Miquel van Smoorenburg
108 #               <miquels@cistron.nl> and Ian Murdock <imurdock@gnu.ai.mit.edu>.
109 #
110
111 set -e
112
113 PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
871b33 114 DAEMON=/usr/local/sbin/mydns
d75f08 115 NAME=mydns
T 116 DESC="DNS server"
117
118 SCRIPTNAME=/etc/init.d/$NAME
119
120 # Gracefully exit if the package has been removed.
121 test -x $DAEMON || exit 0
122
123 case "$1" in
124   start)
125         echo -n "Starting $DESC: $NAME"
126         start-stop-daemon --start --quiet \
127                 --exec $DAEMON -- -b
128         echo "."
129         ;;
130   stop)
131         echo -n "Stopping $DESC: $NAME"
132         start-stop-daemon --stop --oknodo --quiet \
133                 --exec $DAEMON
134         echo "."
135         ;;
136   reload|force-reload)
239490 137         echo -n "Reloading $DESC configuration ..."
d75f08 138         start-stop-daemon --stop --signal HUP --quiet \
T 139                 --exec $DAEMON
140         echo "done."
141         ;;
142   restart)
143         echo -n "Restarting $DESC: $NAME"
144         start-stop-daemon --stop --quiet --oknodo \
145                 --exec $DAEMON
146         sleep 1
147         start-stop-daemon --start --quiet \
148                 --exec $DAEMON -- -b
149         echo "."
150         ;;
151   *)
152         echo "Usage: $SCRIPTNAME {start|stop|restart|reload|force-reload}" >&2
153         exit 1
154         ;;
155 esac
156
157 exit 0
158 ---------------------------------------------------------------------------
159
160 now execute:
161
162 chmod +x /etc/init.d/mydns
163 update-rc.d mydns defaults
164
ba0264 165
9d4a9f 166 6) Install vlogger and webalizer and firewall
ba0264 167
9d4a9f 168 apt-get install vlogger webalizer bastille
ba0264 169
T 170
171 7) Install ISPConfig 3
172
239490 173 There are two possile scenarios a) or b), but not both:
ba0264 174
239490 175 a) Installation of beta 3
R 176     
177     cd /tmp
178     wget http://www.ispconfig.org/downloads/ISPConfig_3.0.0.7-beta.tar.gz
179     tar xvfz ISPConfig_3.0.0.7-alpha.tar.gz
180     cd ispconfig3_install/install/
ba0264 181
239490 182 b) Installation from SVN
ba0264 183
239490 184     apt-get install subversion
R 185     cd /tmp
186     svn export svn://svn.ispconfig.org/ispconfig3/trunk/
187     cd trunk/install
188     
189 after a) or b)
ba0264 190
239490 191 proceed with the ISPConfig installation.
ba0264 192
T 193 Now start the installation process by executing:
194
195 php -q install.php
196
197 The installer will configure all services like postfix, sasl, courier, etc. for you. A manual setup as required for ISPConfig 2 (perfect setup guides) is not nescessary. To login to the ISPConfig controlpanel, open the following URL in your browser (replace the IP to match your settings!):
198
239490 199 http://server1.mydomain.tld:8080/
ba0264 200
T 201 the default login is:
202
203 user: admin
204 password: admin
205
206 In case you get a permission denied error from apache, please restart the apache webserver process.
692f6f 207
Q 208
239490 209 8) Apache Fix
bac6ef 210
239490 211 Once you have restarted Apache you need to fix a quick setting in apache2. 
bac6ef 212
239490 213 a) rm /etc/apache2/sites-enabled/000-default
bac6ef 214
239490 215 b) echo "NameVirtualHost *:80">> /etc/apache2/httpd.conf
R 216
217 c) /etc/init.d/apache2 restart
bac6ef 218
Q 219
239490 220 9) Optional packages
bac6ef 221
239490 222 9.1) Installing Jailkit:
692f6f 223
cdf85e 224 apt-get install build-essential autoconf automake1.9 libtool flex bison
692f6f 225 cd /tmp
cdf85e 226 wget http://olivier.sessink.nl/jailkit/jailkit-2.5.tar.gz
T 227 tar xvfz jailkit-2.5.tar.gz
228 cd jailkit-2.5
692f6f 229 ./configure
Q 230 make
231 make install
cdf85e 232 rm -rf jailkit-2.5*
692f6f 233