| | 51 | 4) Preparation |
|---|
| | 52 | -------------- |
|---|
| | 53 | For the following steps, you will need to be logged in as root. |
|---|
| | 54 | |
|---|
| | 55 | 1. First, you will need to install the RPMForge repository for some of the |
|---|
| | 56 | packages required. It is recommended to follow the directions located at |
|---|
| | 57 | http://wiki.centos.org/Repositories/RPMForge, especially concerning the |
|---|
| | 58 | priorities plugin. |
|---|
| | 59 | |
|---|
| | 60 | 2. Next, make sure your system packages are updated. This is as simple as running: |
|---|
| | 61 | # yum update |
|---|
| | 62 | |
|---|
| | 63 | 3. You now need to disable SELinux, if it is enabled. You can do this by running |
|---|
| | 64 | the following command: |
|---|
| | 65 | # setenforce 0 |
|---|
| | 66 | Now, you will want to make sure it is off for future boots. Set "SELINUX" to |
|---|
| | 67 | "disabled" by editing /etc/selinux/config. |
|---|
| | 68 | |
|---|
| | 69 | 4. Untar or unzip the distribution files to a secure directory: |
|---|
| | 70 | # cd /root |
|---|
| | 71 | # tar xjvf ispcp-omega-1.0.0-RC6.tar.bz2 |
|---|
| | 72 | |
|---|
| | 73 | 5. Change to the newly created directory: |
|---|
| | 74 | # cd ./ispcp-omega-1.0.0 |
|---|
| | 75 | |
|---|
| | 76 | 3. Next, install the software packages we need. A list is conveniently provided |
|---|
| | 77 | and can be used to install by running the following: |
|---|
| | 78 | # yum install `cat ./docs/CentOS/centos-packages` |
|---|
| | 79 | After that, we need to install a few perl modules that aren't packaged. You |
|---|
| | 80 | can run the following command to install them: |
|---|
| | 81 | # cat ./docs/CentOS/centos-perl | xargs -I {} perl -MCPAN -e 'install {}' |
|---|
| | 82 | Now, remove Sendmail so Postfix will be the default MTA |
|---|
| | 83 | # yum remove sendmail |
|---|
| | 84 | |
|---|
| | 85 | 4. Install the Courier IMAP server. Packages for this are not in the default |
|---|
| | 86 | repositories, but are available from third-party packagers such at at |
|---|
| | 87 | http://www.thatfleminggent.com/. The following three packages are the latest |
|---|
| | 88 | versions as of the last update, but you should check the package list at the |
|---|
| | 89 | previous site to make sure you have the latest versions. |
|---|
| | 90 | |
|---|
| | 91 | http://www.thatfleminggent.com/packages/centos/5/i386/courier-authlib-0.60.6-1.el5.mf.i386.rpm |
|---|
| | 92 | http://www.thatfleminggent.com/packages/centos/5/i386/courier-authlib-userdb-0.60.6-1.el5.mf.i386.rpm |
|---|
| | 93 | http://www.thatfleminggent.com/packages/centos/5/i386/courier-imap-4.3.1-2.el5.mf.i386.rpm |
|---|
| | 94 | |
|---|
| | 95 | You will also need to do some minor configuration by adding a user and group |
|---|
| | 96 | for courier. The following commands will acomplish this: |
|---|
| | 97 | # groupadd courier -g 3000 |
|---|
| | 98 | # useradd -u 3000 -c 'Courier Mail Server' -d /dev/null -g courier -s /bin/false courier |
|---|
| | 99 | |
|---|
| | 100 | 4. Now we need to configure MySQL. To do this, it must be running. To make sure |
|---|
| | 101 | it is running, run the following command: |
|---|
| | 102 | # service mysqld start |
|---|
| | 103 | After it starts, you can run the mysql_secure_installation script. This will |
|---|
| | 104 | set up MySQL with an administrator password and make sure any non-secure |
|---|
| | 105 | default items like the test database are removed. This is very important if |
|---|
| | 106 | the server will be for shared hosting. |
|---|
| | 107 | # /usr/bin/mysql_secure_installation |
|---|
| | 108 | Make sure to remember the root password for MySQL. You will need it later. |
|---|
| | 109 | |
|---|
| | 110 | ================================================================================ |
|---|
| 54 | | Make sure you are logged in as root and MySQL is running. |
|---|
| 55 | | |
|---|
| 56 | | 1. Untar or unzip the distribution files to a secure directory: |
|---|
| 57 | | # cd /root |
|---|
| 58 | | # tar xjvf ispcp-omega-1.0.0-RC6.tar.bz2 |
|---|
| | 113 | For the following steps, you will need to be logged in as root and MySQL will |
|---|
| | 114 | need to be running. |
|---|
| | 115 | |
|---|
| | 116 | 1. (optional) Check the ispcp.conf and adapt it to your requirements. |
|---|
| | 117 | An overview over the variables you can find in the FAQ on |
|---|
| | 118 | http://isp-control.net |
|---|
| | 119 | |
|---|
| | 120 | 2. Build the System by using make: |
|---|
| | 121 | # make -f Makefile.centos install |
|---|
| | 122 | |
|---|
| | 123 | 3. Copy all the directories into your system (you may make backups) |
|---|
| | 124 | # cp -RLf /tmp/ispcp/* / |
|---|
| | 125 | # cp -Rv /tmp/ispcp/etc/init.d /etc/rc.d/ |
|---|
| | 126 | # ln -s /etc/rc.d/init.d /etc/init.d |
|---|
| | 127 | # mkdir /var/mail/virtual |
|---|
| | 128 | |
|---|
| | 129 | 4. Now, setup some items for BIND configuration: |
|---|
| | 130 | # mv /var/named/data /var/named/data2 |
|---|
| | 131 | # ln -s /var/named/chroot/var/named/data /var/named/data |
|---|
| | 132 | # touch /etc/named.conf |
|---|
| | 133 | # touch /etc/ispcp/bind/backup/named.conf.ispcp |
|---|
| | 134 | |
|---|
| | 135 | 5. Next, we create the SASL database directory and link the configuration for |
|---|
| | 136 | Postfix |
|---|
| | 137 | # touch /etc/sasldb2 |
|---|
| | 138 | # mkdir -p /var/spool/postfix/etc |
|---|
| | 139 | # cp /etc/sasldb2 /var/spool/postfix/etc/sasldb2 |
|---|
| | 140 | |
|---|
| | 141 | Now, edit /usr/lib/sasl2/smtpd.conf to use the SASL database. Replace the |
|---|
| | 142 | contents of that file with the following: |
|---|
| | 143 | pwcheck_method: auxprop |
|---|
| | 144 | auxprop_plugin: sasldb |
|---|
| | 145 | mech_list: PLAIN LOGIN CRAM-MD5 DIGEST-MD5 |
|---|
| | 146 | |
|---|
| | 147 | 6. A little bit of Apache configuration is needed: |
|---|
| | 148 | # mkdir /var/www/scoreboards |
|---|
| | 149 | |
|---|
| | 150 | # echo 'include vhosts/*.conf' >> /etc/httpd/conf/httpd.conf |
|---|
| | 151 | |
|---|
| | 152 | # chown apache:apache /var/www/ispcp/gui/tools/webmail/data |
|---|
| | 153 | |
|---|
| | 154 | 7. Now it's time to set up the frontend. We need to change into the right |
|---|
| | 155 | directory and run the setup tool: |
|---|
| | 156 | # cd /var/www/ispcp/engine/setup |
|---|
| | 157 | # perl ispcp-setup |
|---|
| | 158 | |
|---|
| | 159 | If you get no error, all went good; if you get one, look at |
|---|
| | 160 | http://isp-control.net to solve the problem. |
|---|
| | 161 | |
|---|
| | 162 | ================================================================================ |
|---|
| | 163 | 4) Post-Installation |
|---|
| | 164 | -------------------- |
|---|
| | 165 | 1. There is a bug in some versions of courier that prevent courier-authdaemon |
|---|
| | 166 | from stopping with the default service script. You will need to make an edit |
|---|
| | 167 | to fix this. Edit /etc/init.d/courier-authlib and |
|---|
| | 168 | change: ${libexecdir}/authlib/authdaemon stop |
|---|
| | 169 | into: killall authdaemond.plain |
|---|
| | 170 | |
|---|
| | 171 | 2. Modify some system values: |
|---|
| | 172 | # chmod 777 /var/www/ispcp/gui/phptmp |
|---|
| | 173 | |
|---|
| | 174 | * Install Daemon: |
|---|
| | 175 | # chkconfig --add ispcp_daemon |
|---|
| | 176 | # chkconfig --add ispcp_network |
|---|
| | 177 | # chkconfig --levels 345 ispcp_daemon on |
|---|
| | 178 | # chkconfig --levels 345 ispcp_network on |
|---|
| | 179 | # service ispcp_daemon start |
|---|
| | 180 | # service ispcp_network start |
|---|
| | 181 | |
|---|
| | 182 | 3. Clean the temporary folders: |
|---|
| | 183 | # rm -R /tmp/ispcp |
|---|
| | 184 | |
|---|
| | 185 | ================================================================================ |
|---|
| | 186 | 5) Update |
|---|
| | 187 | --------- |
|---|
| | 188 | For the following steps, you will need to be logged in as root and MySQL will |
|---|
| | 189 | need to be running. |
|---|
| | 190 | |
|---|
| | 191 | |
|---|
| | 192 | |
|---|
| | 193 | |
|---|
| | 194 | 1. Untar or unzip the distribution files to a secure directory: |
|---|
| | 195 | # cd /root |
|---|
| | 196 | # tar xjvf ispcp-omega-1.0.0-RC6.tar.bz2 |
|---|
| 61 | | # cd ./ispcp-omega-1.0.0 |
|---|
| 62 | | |
|---|
| 63 | | 3. Install the required modules: |
|---|
| 64 | | # wget http://apt.sw.be/redhat/el5/en/i386/RPMS.dag/rpmforge-release-0.3.6-1.el5.rf.i386.rpm |
|---|
| 65 | | # rpm -ivh rpmforge-release-0.3.6-1.el5.rf.i386.rpm |
|---|
| 66 | | # yum update |
|---|
| 67 | | # yum remove sendmail |
|---|
| 68 | | # yum install `cat ./docs/CentOS/centos-packages` |
|---|
| 69 | | # perl -MCPAN -e 'install `cat ./docs/CentOS/centos-perl`' |
|---|
| 70 | | # wget -r http://mirrors.penguinfriends.org/ISPCP/CentOS-5.0/Courier --no-directories --include-directories=/ISPCP/CentOS-5.0/Courier && rm index* |
|---|
| 71 | | # rpm -Uvh courier-authlib-0.57-1.i386.rpm courier-authlib-userdb-0.57-1.i386.rpm courier-authlib-devel-0.57-1.i386.rpm courier-0*.rpm courier-imapd-0*.rpm courier-pop3d-0*.rpm |
|---|
| 72 | | # chkconfig --add courier |
|---|
| 73 | | # service courier start |
|---|
| 74 | | # chkconfig --add courier-authlib |
|---|
| 75 | | # service courier-authlib start |
|---|
| 76 | | # chkconfig postfix on |
|---|
| 77 | | # service postfix start |
|---|
| | 199 | # cd ./ispcp-omega-1.0.0 |
|---|
| | 200 | |
|---|
| | 201 | 3. Next, install the software packages we need. A list is conveniently provided |
|---|
| | 202 | and can be used to install by running the following: |
|---|
| | 203 | # yum install `cat ./docs/CentOS/centos-packages` |
|---|
| | 204 | After that, we need to install a few perl modules that aren't packaged. You |
|---|
| | 205 | can run the following command to install them: |
|---|
| | 206 | # cat ./docs/CentOS/centos-perl | xargs -I {} perl -MCPAN -e 'install {}' |
|---|
| 84 | | # make install -f Makefile.centos |
|---|
| 85 | | |
|---|
| 86 | | 6. Copy all the directories into your system (you may make backups) |
|---|
| 87 | | # cp -Rv /tmp/ispcp/* / |
|---|
| 88 | | |
|---|
| 89 | | 7. Make the scoreboards dir and the aliases and some other fixes |
|---|
| 90 | | # mkdir /var/www/scoreboards |
|---|
| 91 | | # touch /etc/aliases && touch /etc/aliases.db |
|---|
| 92 | | # chmod 777 /var/www/ispcp/gui/phptmp/ |
|---|
| 93 | | # mkdir /etc/httpd/conf.d/mods-available/ |
|---|
| 94 | | # mkdir /etc/httpd/conf.d/sites-available/ |
|---|
| 95 | | # echo 'Include conf.d/sites-available/' >> /etc/httpd/conf/httpd.conf |
|---|
| 96 | | # mv ispcp_daemon /etc/init.d/ |
|---|
| 97 | | # mv ispcp_network /etc/init.d/ |
|---|
| 98 | | # chkconfig --levels 3 6 ispcp_daemon on && chkconfig --levels 3 6 ispcp_network on |
|---|
| 99 | | # chmod -R 775 /var/www/ispcp/gui/tools/webmail/data |
|---|
| 100 | | |
|---|
| 101 | | We have to disable selinux if running ... |
|---|
| 102 | | # setenforce 0 |
|---|
| 103 | | # nano /etc/selinux/config |
|---|
| 104 | | Make sure that: |
|---|
| 105 | | SELINUX=disabled |
|---|
| 106 | | Then we have to fix postfix: |
|---|
| 107 | | # nano /etc/postfix/master.cf |
|---|
| 108 | | Set in each line for smtp the "-" to "n" |
|---|
| 109 | | |
|---|
| 110 | | 8. Now it's time to set up the frontend. Change into the engine directory: |
|---|
| 111 | | # cd /var/www/ispcp/engine/setup |
|---|
| 112 | | |
|---|
| 113 | | 8a. Set the MySQL password, if not set: |
|---|
| 114 | | # mysqladmin -u root password YOUR_PASSWORD |
|---|
| 115 | | |
|---|
| 116 | | 9. Start the engine setup: |
|---|
| 117 | | # perl ispcp-setup |
|---|
| 118 | | |
|---|
| 119 | | 10. Install ispCP ω step-by-step |
|---|
| 120 | | |
|---|
| 121 | | If you get no error, all went good; if you get one, look at |
|---|
| 122 | | http://isp-control.net to solve the problem. |
|---|
| 123 | | |
|---|
| 124 | | 11. (optional) Get the latest PHP Version |
|---|
| 125 | | # rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-2.noarch.rpm |
|---|
| 126 | | # rpm -Uvh http://remi.collet.free.fr/rpms/el5.i386/remi-release-5-3.el5.remi.noarch.rpm |
|---|
| 127 | | # yum --enable remi update php-\* |
|---|
| 128 | | |
|---|
| 129 | | Sometimes libc-client.so.2006 is missing ... so we need to get it |
|---|
| 130 | | # rpm -Uvh ftp://fr.rpmfind.net/linux/fedora/extras/development/i386/libc-client2006-2006g-3.fc7.i386.rpm |
|---|
| 131 | | |
|---|
| 132 | | 12. (optional) Get the latest Apache |
|---|
| 133 | | # vim /etc/yum.repos.d/utterramblings.repo |
|---|
| 134 | | |
|---|
| 135 | | Add the following lines: |
|---|
| 136 | | [utterramblings] |
|---|
| 137 | | name=Jason's Utter Ramblings Repo |
|---|
| 138 | | baseurl=http://www.jasonlitka.com/media/EL$releasever/$basearch/ |
|---|
| 139 | | enabled=1 |
|---|
| 140 | | gpgcheck=1 |
|---|
| 141 | | gpgkey=http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka |
|---|
| 142 | | |
|---|
| 143 | | # yum --enable utterramblings update httpd-\* |
|---|
| 144 | | |
|---|
| 145 | | 12. Clean the temporary folders: |
|---|
| 146 | | # rm -R /tmp/ispcp |
|---|
| 147 | | |
|---|
| 148 | | |
|---|
| 149 | | ================================================================================ |
|---|
| 150 | | 5) Update |
|---|
| 151 | | --------- |
|---|
| 152 | | Make sure you are logged in as root and MySQL is running. |
|---|
| 153 | | |
|---|
| 154 | | 1. Untar or unzip the distribution files to a secure directory: |
|---|
| 155 | | # cd /root |
|---|
| 156 | | # tar xjvf ispcp-omega-1.0.0-RC6.tar.bz2 |
|---|
| 157 | | |
|---|
| 158 | | 2. Change to the newly created directory: |
|---|
| 159 | | # cd ./ispcp-omega-1.0.0 |
|---|
| 160 | | |
|---|
| 161 | | 3. Install the required modules: |
|---|
| 162 | | # wget http://apt.sw.be/redhat/el5/en/i386/RPMS.dag/rpmforge-release-0.3.6-1.el5.rf.i386.rpm |
|---|
| 163 | | # rpm -ivh rpmforge-release-0.3.6-1.el5.rf.i386.rpm |
|---|
| 164 | | # yum update |
|---|
| 165 | | # yum remove sendmail |
|---|
| 166 | | # yum install `cat ./docs/CentOS/centos-packages` |
|---|
| 167 | | # perl -MCPAN -e 'install `cat ./docs/CentOS/centos-perl`' |
|---|
| 168 | | # wget -r http://mirrors.penguinfriends.org/ISPCP/CentOS-5.0/Courier --no-directories --include-directories=/ISPCP/CentOS-5.0/Courier && rm index* |
|---|
| 169 | | # rpm -Uvh courier-authlib-0.57-1.i386.rpm courier-authlib-userdb-0.57-1.i386.rpm courier-authlib-devel-0.57-1.i386.rpm courier-0*.rpm courier-imapd-0*.rpm courier-pop3d-0*.rpm |
|---|
| 170 | | # chkconfig --add courier |
|---|
| 171 | | # service courier start |
|---|
| 172 | | # chkconfig --add courier-authlib |
|---|
| 173 | | # service courier-authlib start |
|---|
| 174 | | # chkconfig postfix on |
|---|
| 175 | | # service postfix start |
|---|
| 176 | | |
|---|
| 177 | | 4. (optional) Check the ispcp.conf and adapt it to your requirements. |
|---|
| 178 | | An overview over the variables you can find in the FAQ on |
|---|
| 179 | | http://isp-control.net |
|---|
| 180 | | |
|---|
| 181 | | 5. Build the System by using make: |
|---|
| 182 | | # make install |
|---|
| | 213 | # make -f Makefile.centos install |
|---|