Installing A Web, Email & MySQL Database Cluster On Debian 6.0 With ISPConfig 3 - Page 4

Want to support HowtoForge? Become a subscriber!
 
Submitted by till (Contact Author) (Forums) on Tue, 2012-02-14 16:42. ::

4 Installing ISPConfig 3 On The Second Server

In this step we will install ISPConfig on the slave server (server2.example.tld). This time we use the expert mode of the ISPConfig installer to add this node to the master ispconfig server and database. To get the download URL of the latest ISPConfig 3 stable release, please visit the ISPConfig website: http://www.ispconfig.org/ispconfig-3/download/

On server 2:

Download the latest ISPConfig 3 stable release...

cd /tmp
wget http://www.ispconfig.org/downloads/ISPConfig-3-stable.tar.gz
tar xfz ISPConfig-3-stable.tar.gz
cd ispconfig3_install/install/

... and start the install script:

php -q install.php

Select language (en,de) [en]: <-- en
Installation mode (standard,expert) [standard]:
<-- expert
Full qualified hostname (FQDN) of the server, eg server2.domain.tld [server2.example.tld]:
<-- server2.example.tld
MySQL server hostname [localhost]:
<-- localhost
MySQL root username [root]:
<-- root
MySQL root password []:
<-- Enter your mysql root password here
MySQL database to create [dbispconfig]:
<-- dbispconfig2 (the local ispconfig database name of the master and slave must be different, as both servers share the same data directory)
MySQL charset [utf8]:
<-- utf8

The next two questions are about the internal ISPConfig database user and password.
It is recommended to accept the defaults which are 'ispconfig' as username and a random password.
If you use a different password, use only numbers and chars for the password.

ISPConfig mysql database username [ispconfig]: <-- ispconfig2
ISPConfig mysql database password [54c243fd3f9ca68de7b08527c81dd5ef]:
<-- (press return to accept the default)

Shall this server join an existing ISPConfig multiserver setup (y,n) [n]:
<-- y
MySQL master server hostname []:
<-- server1.example.tld
MySQL master server root username [root]:
<-- root
MySQL master server root password []:
<-- Enter the root password of the master server here
MySQL master server database name [dbispconfig]:
<-- dbispconfig1
Configure Mail (y,n) [y]:
<-- y

Country Name (2 letter code) [AU]: <-- DE (Enter the ISO country code where you live here)
State or Province Name (full name) [Some-State]:
<-- Niedersachsen (Enter the state where you live here)
Locality Name (eg, city) []:
<-- Lueneburg (Enter the city here)
Organization Name (eg, company) [Internet Widgits Pty Ltd]:
Organizational Unit Name (eg, section) []:
Common Name (eg, YOUR name) []:
Email Address []:

Configure Jailkit (y,n) [y]: <-- y
Configure FTP Server (y,n) [y]:
<-- y
Configure DNS Server (y,n) [y]:
<-- y
Configure Apache Server (y,n) [y]:
<-- y
Configure Firewall Server (y,n) [y]:
<--y
Install ISPConfig Web-Interface (y,n) [y]:
<--y
Installing ISPConfig
ISPConfig Port [8080]:

Enable SSL for the ISPConfig web interface (y,n) [y]: <-- y

Generating RSA private key, 4096 bit long modulus
.................++
.............................................................................................................++
e is 65537 (0x10001)
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:
State or Province Name (full name) [Some-State]:
Locality Name (eg, city) []:
Organization Name (eg, company) [Internet Widgits Pty Ltd]:
Organizational Unit Name (eg, section) []:
Common Name (eg, YOUR name) []:
Email Address []:

Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:
An optional company name []:

Clean up the install directories:

rm -rf /tmp/ispconfig3_install/install
rm -f /tmp/ISPConfig-3-stable.tar.gz

In a last configuration step, we want to connect the ISPConfig interface of the slave directly to the master database. This step is only required if you want to access ISPConfig on port 8080 on the master and on the slave server. Log into the master server as root user on the shell...

On server 1:

... and execute this command:

scp -p /usr/local/ispconfig/interface/lib/config.inc.php root@192.168.0.106:/usr/local/ispconfig/interface/lib/config.inc.php

This command has to be excuted after each ISPConfig update again after you updated ISPConfig on the master and on the slave with the normal ISPConfig update command (ispconfig_update.sh).


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by Benjamin (not registered) on Fri, 2013-05-17 16:06.

I don't understand the last step.

For which reason we would use it ?

The SCP command copy the config of master to slave, in order to slave server use the database of master... but what is the advantage, because databases of both server will be synchronized.

And when the master server will failed, its database will not be able to used by slave server... that's not a problem ? 

I have used the port 8080 for both servers, I hope I can use my servers without that..

 Thank you for response..

 Benjamin

Submitted by MrWolf (registered user) on Sun, 2013-08-11 14:31.
in the file you can read: $conf['db_host'] = 'localhost'; so even if you copy the file, each ispconfig server will connect to it's own database. if you don't use the same database, you'll always have 2 different setup. at this point, I think the dbispconfig2 databases become useless and could be deleted