|
| 1 | + |
| 2 | + |
| 3 | +Installation |
| 4 | +----------- |
| 5 | + |
| 6 | +It is recommended to use a clean (fresh) CentOS 5.4 install. Then follow the steps below to setup your server with ISPConfig 3: |
| 7 | + |
| 8 | +Installation of some basic requirements: |
| 9 | + |
| 10 | +rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY* |
| 11 | + |
| 12 | +enable the contrib and centosplus repositories. |
| 13 | + |
| 14 | +vi /etc/yum.repos.d/CentOS-Base.repo |
| 15 | + |
| 16 | +1. Edit the file /etc/yum.repos.d/CentOS-Base.repo and edit the lines below. |
| 17 | + |
| 18 | +[base] |
| 19 | +exclude=postfix |
| 20 | + |
| 21 | +[update] |
| 22 | +exclude=postfix |
| 23 | + |
| 24 | +[centosplus] |
| 25 | +enabled=1 |
| 26 | +includepkgs=postfix |
| 27 | + |
| 28 | +[contrib] |
| 29 | +enabled=1 |
| 30 | + |
| 31 | +rpm --import http://dag.wieers.com/rpm/packages/RPM-GPG-KEY.dag.txt |
| 32 | + |
| 33 | +cd /tmp |
| 34 | +wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.1-1.el5.rf.i386.rpm |
| 35 | +rpm -i rpmforge-release-0.5.1-1.el5.rf.i386.rpm |
| 36 | +yum update |
| 37 | + |
| 38 | +You should disable selinux now, as some programs will not start when selinux is enabled: |
| 39 | + |
| 40 | +system-config-securitylevel-tui |
| 41 | + |
| 42 | +then reboot the server. |
| 43 | + |
| 44 | +Then remove the postfix without mysql support |
| 45 | + |
| 46 | +yum remove postfix |
| 47 | + |
| 48 | +1) Install Postfix fron centosplus with mysql support, Dovecot, MySQL, phpMyAdmin with the following command line (on one line!): |
| 49 | + |
| 50 | +yum install ntp httpd mysql-server php php-mysql php-mbstring phpMyAdmin postfix getmail |
| 51 | + |
| 52 | +For 32Bit systems: |
| 53 | + |
| 54 | +rpm -i http://dl.atrpms.net/all/dovecot-1.2.10-2_107.el5.i386.rpm |
| 55 | +rpm -i http://dl.atrpms.net/all/dovecot-sieve-0.1.15-4.el5.i386.rpm |
| 56 | + |
| 57 | +For 64Bit Systems: |
| 58 | + |
| 59 | +rpm -i http://dl.atrpms.net/all/dovecot-1.2.10-2_107.el5.x86_64.rpm |
| 60 | +rpm -i http://dl.atrpms.net/all/dovecot-sieve-0.1.15-4.el5.x86_64.rpm |
| 61 | + |
| 62 | + |
| 63 | +chkconfig --levels 235 mysqld on |
| 64 | +/etc/init.d/mysqld start |
| 65 | + |
| 66 | +chkconfig --levels 235 httpd on |
| 67 | +/etc/init.d/httpd start |
| 68 | + |
| 69 | +chkconfig --levels 235 dovecot on |
| 70 | +/etc/init.d/dovecot start |
| 71 | + |
| 72 | +chkconfig --levels 235 sendmail off |
| 73 | +chkconfig --levels 235 postfix on |
| 74 | +/etc/init.d/sendmail stop |
| 75 | +/etc/init.d/postfix start |
| 76 | + |
| 77 | + |
| 78 | +Set the mysql database password: |
| 79 | + |
| 80 | +/usr/bin/mysql_secure_installation |
| 81 | + |
| 82 | + |
| 83 | +2) Install Amavisd-new, Spamassassin and Clamav (1 line!): |
| 84 | + |
| 85 | +yum install amavisd-new spamassassin clamav clamd unzip bzip2 unrar |
| 86 | + |
| 87 | +sa-update |
| 88 | +chkconfig --levels 235 amavisd on |
| 89 | +chkconfig --levels 235 clamd on |
| 90 | +/usr/bin/freshclam |
| 91 | +/etc/init.d/amavisd start |
| 92 | +/etc/init.d/clamd start |
| 93 | + |
| 94 | +If you use the amavisd from rpmforge (as we do in this guide) and not the one from centos, you will have to do these additional steps: |
| 95 | + |
| 96 | +add the following line in /etc/sysconfig/amavisd: |
| 97 | + |
| 98 | +CONFIG_FILE="/etc/amavisd/amavisd.conf |
| 99 | + |
| 100 | +run: |
| 101 | + |
| 102 | +mkdir /var/run/amavisd /var/spool/amavisd /var/spool/amavisd/tmp /var/spool/amavisd/db |
| 103 | +chown amavis /var/run/amavisd /var/spool/amavisd /var/spool/amavisd/tmp /var/spool/amavisd/db |
| 104 | +ln -s /var/run/clamav/clamd.sock /var/spool/amavisd/clamd.sock |
| 105 | +yum install perl-DBD-mysql |
| 106 | + |
| 107 | + |
| 108 | +3) Install apache, PHP5 and phpmyadmin (1 line!): |
| 109 | + |
| 110 | +yum install php php-devel php-gd php-imap php-ldap php-mysql php-odbc php-pear php-xml php-xmlrpc php-eaccelerator php-mbstring php-mcrypt php-mhash php-mssql php-snmp php-soap php-tidy curl curl-devel perl-libwww-perl ImageMagick libxml2 libxml2-devel phpmyadmin |
| 111 | + |
| 112 | + |
| 113 | +4) Install pure-ftpd and quota |
| 114 | + |
| 115 | +yum install pure-ftpd quota |
| 116 | + |
| 117 | +chkconfig --levels 235 pure-ftpd on |
| 118 | +/etc/init.d/pure-ftpd start |
| 119 | + |
| 120 | +5) Install bind dns server |
| 121 | + |
| 122 | +yum install bind-chroot |
| 123 | + |
| 124 | +chmod 755 /var/named/ |
| 125 | +chmod 775 /var/named/chroot/ |
| 126 | +chmod 775 /var/named/chroot/var/ |
| 127 | +chmod 775 /var/named/chroot/var/named/ |
| 128 | +chmod 775 /var/named/chroot/var/run/ |
| 129 | +chmod 777 /var/named/chroot/var/run/named/ |
| 130 | +cd /var/named/chroot/var/named/ |
| 131 | +ln -s ../../ chroot |
| 132 | +cp /usr/share/doc/bind-9.3.6/sample/var/named/named.local /var/named/chroot/var/named/named.local |
| 133 | +cp /usr/share/doc/bind-9.3.6/sample/var/named/named.root /var/named/chroot/var/named/named.root |
| 134 | +touch /var/named/chroot/etc/named.conf |
| 135 | + |
| 136 | +vi /var/named/chroot/etc/named.conf |
| 137 | + |
| 138 | +-------------------------------------------------------------------------------------------------- |
| 139 | +// |
| 140 | +// named.conf |
| 141 | +// |
| 142 | +// Provided by Red Hat bind package to configure the ISC BIND named(8) DNS |
| 143 | +// server as a caching only nameserver (as a localhost DNS resolver only). |
| 144 | +// |
| 145 | +// See /usr/share/doc/bind*/sample/ for example named configuration files. |
| 146 | +// |
| 147 | + |
| 148 | +options { |
| 149 | + listen-on port 53 { 127.0.0.1; }; |
| 150 | + listen-on-v6 port 53 { ::1; }; |
| 151 | + directory "/var/named/chroot/var/named"; |
| 152 | + dump-file "/var/named/chroot/var/named/data/cache_dump.db"; |
| 153 | + statistics-file "/var/named/chroot/var/named/data/named_stats.txt"; |
| 154 | + memstatistics-file "/var/named/chroot/var/named/data/named_mem_stats.txt"; |
| 155 | + allow-query { localhost; }; |
| 156 | + recursion yes; |
| 157 | +}; |
| 158 | + |
| 159 | +logging { |
| 160 | + channel default_debug { |
| 161 | + file "data/named.run"; |
| 162 | + severity dynamic; |
| 163 | + }; |
| 164 | +}; |
| 165 | + |
| 166 | +zone "." IN { |
| 167 | + type hint; |
| 168 | + file "named.root"; |
| 169 | +}; |
| 170 | + |
| 171 | +include "/var/named/chroot/etc/named.conf.local"; |
| 172 | +-------------------------------------------------------------------------------------------------- |
| 173 | + |
| 174 | + |
| 175 | +chkconfig --levels 235 named on |
| 176 | +/etc/init.d/named start |
| 177 | + |
| 178 | +6) Install vlogger dependencies and webalizer |
| 179 | + |
| 180 | +yum install webalizer perl-DateTime-Format-HTTP perl-DateTime-Format-Builder |
| 181 | + |
| 182 | +Installing Jailkit: |
| 183 | + |
| 184 | +yum install gcc |
| 185 | +cd /tmp |
| 186 | +wget http://olivier.sessink.nl/jailkit/jailkit-2.11.tar.gz |
| 187 | +tar xvfz jailkit-2.11.tar.gz |
| 188 | +cd jailkit-2.11 |
| 189 | +./configure |
| 190 | +make |
| 191 | +make install |
| 192 | +rm -rf jailkit-2.11* |
| 193 | + |
| 194 | + |
| 195 | +7) Install ISPConfig 3 |
| 196 | + |
| 197 | + |
| 198 | +cd /tmp |
| 199 | +wget http://www.ispconfig.org/downloads/ISPConfig-3.0.2.tar.gz |
| 200 | +tar xvfz ISPConfig-3.0.2.tar.gz |
| 201 | +cd ispconfig3_install/install/ |
| 202 | + |
| 203 | +Now start the installation process by executing: |
| 204 | + |
| 205 | +php -q install.php |
| 206 | + |
| 207 | +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!): |
| 208 | + |
| 209 | +http://192.168.0.100:8080/ |
| 210 | + |
| 211 | +the default login is: |
| 212 | + |
| 213 | +user: admin |
| 214 | +password: admin |
| 215 | + |
| 216 | +In case you get a permission denied error from apache, please restart the apache webserver process. |
| 217 | + |
| 218 | +Optional: |
| 219 | + |
| 220 | +Install a webbased Email Client |
| 221 | + |
| 222 | +yum install squirrelmail |
| 223 | + |
| 224 | + |
| 225 | + |
0 commit comments