tbrehm
2009-01-11 b67e4fbd493eb5c0bee7480a0dc19ab8112857ab
commit | author | age
663619 1 Installation
T 2 -----------
3
4 It is recommended to use a clean (fresh) CentOS 5.2 install. Then follow the steps below to setup your server with ISPConfig 3:
5
6 Installation of some basic requirements:
7
8 rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY*
9 yum update
10 yum groupinstall 'Development Tools'
11 yum groupinstall 'Development Libraries'
12
13 You should disable selinux now, as some programs will not start when selinux is enabled:
14
15 system-config-securitylevel-tui
16
17 then reboot the server.
18
19
20 1) Install Postfix, Courier, Saslauthd, MySQL, phpMyAdmin with the following command line (on one line!):
21
22 yum install ntp httpd mysql-server php php-mysql php-mbstring rpm-build gcc mysql-devel openssl-devel cyrus-sasl-devel pkgconfig zlib-devel phpMyAdmin pcre-devel openldap-devel postgresql-devel expect libtool-ltdl-devel openldap-servers libtool gdbm-devel pam-devel gamin-devel postfix
23
24 rpm --import http://dag.wieers.com/rpm/packages/RPM-GPG-KEY.dag.txt
25
26 cd /tmp
27 wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm
28 rpm -i rpmforge-release-0.3.6-1.el5.rf.i386.rpm
29 yum update
30
31 yum install getmail
32
33 useradd -m -s /bin/bash compileuser
34 passwd compileuser
35
36 visudo
37
38 ## Allow root to run any commands anywhere
39 root    ALL=(ALL)       ALL
40 compileuser   ALL=(ALL)       ALL
41
42
43 su compileuser
44
45 mkdir $HOME/rpm
46 mkdir $HOME/rpm/SOURCES
47 mkdir $HOME/rpm/SPECS
48 mkdir $HOME/rpm/BUILD
49 mkdir $HOME/rpm/SRPMS
50 mkdir $HOME/rpm/RPMS
51 mkdir $HOME/rpm/RPMS/i386
52
53 echo "%_topdir $HOME/rpm" >> $HOME/.rpmmacros
54
55
56 wget http://prdownloads.sourceforge.net/courier/courier-authlib-0.61.0.tar.bz2
57 wget http://prdownloads.sourceforge.net/courier/courier-imap-4.4.1.tar.bz2
58 wget http://prdownloads.sourceforge.net/courier/maildrop-2.0.4.tar.bz2
59
60 sudo rpmbuild -ta courier-authlib-0.61.0.tar.bz2
61
62 sudo rpm -ivh /home/compileuser/rpm/RPMS/i386/courier-authlib-0.61.0-1.i386.rpm
63 sudo rpm -ivh /home/compileuser/rpm/RPMS/i386/courier-authlib-mysql-0.61.0-1.i386.rpm
64 sudo rpm -ivh /home/compileuser/rpm/RPMS/i386/courier-authlib-devel-0.61.0-1.i386.rpm
65
66 rpmbuild -ta courier-imap-4.4.1.tar.bz2
67
68 sudo rpm -ivh /home/compileuser/rpm/RPMS/i386/courier-imap-4.4.1-1.i386.rpm
69
70 sudo rpmbuild -ta maildrop-2.0.4.tar.bz2
71
72 sudo rpm -ivh /home/compileuser/rpm/RPMS/i386/maildrop-2.0.4-1.i386.rpm
73
74 exit
75
76 chkconfig --levels 235 mysqld on
77 /etc/init.d/mysqld start
78
79 chkconfig --levels 235 httpd on
80 /etc/init.d/httpd start
81
82 chkconfig --levels 235 courier-authlib on
83 /etc/init.d/courier-authlib start
84
85 chkconfig --levels 235 sendmail off
86 chkconfig --levels 235 postfix on
87 chkconfig --levels 235 saslauthd on
88 /etc/init.d/sendmail stop
89 /etc/init.d/postfix start
90 /etc/init.d/saslauthd start
91
92 chkconfig --levels 235 courier-imap on
93 /etc/init.d/courier-authlib restart
94 /etc/init.d/courier-imap restart
95
96
97 Set the mysql database password:
98
99 mysqladmin -u root password yourrootsqlpassword
100 mysqladmin -h ispconfig.local -u root password yourrootsqlpassword
101
102
103 2) Install Amavisd-new, Spamassassin and Clamav (1 line!):
104
105 yum install amavisd-new spamassassin clamav clamd clamav-data clamav-server clamav-update unzip bzip2 unrar
106
107 chkconfig --levels 235 amavisd on
108 chkconfig --levels 235 clamd on
109 /usr/bin/freshclam
110 /etc/init.d/amavisd start
111 /etc/init.d/clamd start
112
7c514f 113 If you use the amavisd from rpmforge and not the one from centos, you will have to do these additional steps:
T 114
115 add the following line in /etc/sysconfig/amavisd:
116
117 CONFIG_FILE="/etc/amavisd/amavisd.conf
118
119 run:
120
121 mkdir /var/run/amavisd /var/spool/amavisd /var/spool/amavisd/tmp /var/spool/amavisd/db
122 chown amavis /var/run/amavisd /var/spool/amavisd /var/spool/amavisd/tmp /var/spool/amavisd/db
123 yum install perl-DBD-mysql
124
125
663619 126 3) Install apache, PHP5 and phpmyadmin (1 line!):
T 127
128 yum install php php-devel php-gd php-imap php-ldap php-mysql php-odbc php-pear php-xml php-xmlrpc php-eaccelerator php-magickwand php-magpierss php-mapserver php-mbstring php-mcrypt php-mhash php-mssql php-shout php-snmp php-soap php-tidy curl curl-devel perl-libwww-perl ImageMagick libxml2 libxml2-devel phpmyadmin
129
130
131 4) Install pure-ftpd and quota
132
133 cd /tmp
134 wget http://centos.karan.org/el5/extras/testing/i386/RPMS/pure-ftpd-1.0.21-15.el5.kb.i386.rpm
135 rpm -i pure-ftpd-1.0.21-15.el5.kb.i386.rpm
136
137 yum install quota
138
139 chkconfig --levels 235 pure-ftpd on
140 /etc/init.d/pure-ftpd start
141
142 5) Install mydns
143
144 wget http://mydns.bboy.net/download/mydns-mysql-1.1.0-1.i386.rpm
145 rpm -ivh mydns-mysql-1.1.0-1.i386.rpm
146
147 chkconfig --levels 235 mydns on
148
149 6) Install vlogger and webalizer
150
151 yum install webalizer perl-DateTime-Format-HTTP perl-DateTime-Format-Builder
152
153 cd /tmp
154 wget http://n0rp.chemlab.org/vlogger/vlogger-1.3.tar.gz
155 tar xvfz vlogger-1.3.tar.gz
156 mv vlogger-1.3/vlogger /usr/sbin/
157 rm -rf vlogger*
158
159 7) Install ISPConfig 3
160
161 Disable the firewall:
162
163 system-config-securitylevel-tui
164
165 There are two possile scenarios, but not both:
166 7.1) Install the latest released version 
167 7.2) Install directly from SVN
168
169 7.1) Installation of beta 3 from tar.gz
170
171   cd /tmp
bf50bc 172   wget http://www.ispconfig.org/downloads/ISPConfig-3.0.0.8-rc1.tar.gz
T 173   tar xvfz ISPConfig-3.0.0.8-rc1.tar.gz
663619 174   cd ispconfig3_install/install/
T 175
176 7.2) Installation from SVN
177
178   yum install subversion
179   cd /tmp
180   svn export svn://svn.ispconfig.org/ispconfig3/trunk/
181   cd trunk/install
182
183
184 7.1+7.2) Now proceed with the ISPConfig installation.
185
186 Now start the installation process by executing:
187
188 php -q install.php
189
190 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!):
191
192 http://192.168.0.100:8080/
193
194 the default login is:
195
196 user: admin
197 password: admin
198
199 In case you get a permission denied error from apache, please restart the apache webserver process.
200
201 Optional:
202
490039 203 Install a webbased Email Client
663619 204
T 205 yum install squirrelmail
206
207
208 ----------------------------------------------------------------------------------------------------------
209
210 Hints:
211
212 debian 4.0 under openvz:
213
214 VPSID=101
215 for CAP in CHOWN DAC_READ_SEARCH SETGID SETUID NET_BIND_SERVICE NET_ADMIN SYS_CHROOT SYS_NICE CHOWN DAC_READ_SEARCH SETGID SETUID NET_BIND_SERVICE NET_ADMIN SYS_CHROOT SYS_NICE
216 do
217   vzctl set $VPSID --capability ${CAP}:on --save
218 done
219
220 ----------------------------------------------------------------------------------------------------------
221
222 Installing Jailkit:
223
224 cd /tmp
cdf85e 225 wget http://olivier.sessink.nl/jailkit/jailkit-2.5.tar.gz
T 226 tar xvfz jailkit-2.5.tar.gz
227 cd jailkit-2.5
663619 228 ./configure
T 229 make
230 make install
cdf85e 231 rm -rf jailkit-2.5*