Comments on Installing a Web, Email & MySQL Database Cluster on Debian 8.4 Jessie with ISPConfig 3.1
This tutorial describes the installation of a clustered web, email, database and DNS server to be used for redundancy, high availability and load balancing on Debian 8 with the ISPConfig 3 control panel. MySQL Master/Master replication will be used to replicate the MySQL client databases between the servers, Unison will be used to Sync the /var/www (websites) and the Mails will be synced with Dovecot.
33 Comment(s)
Comments
Nice job! thx
Thank you,Thats very helpful article. Good explanation and clear instruction.I assume it will be same if I want to implement that on Ubuntu 16.04 LTS server, right?That would be greate if you confirm it's working fine if I alter my current single server setup of ISPConfig to be changed to cluster based system.Thanks again...
Hi do you know a tutorial to add load balancer on the system which shares the load between the 2 servers?
Very good tutorial! Can u tell me, what to do, in cause of failover IPs?
hi ! great Tuto, on Step 6 with Download ISPConfig 3.1, an Type Error with the line :
tar xfvz xfz ISPConfig-3.1-beta.tar.gz, the second xfz is too.
hi !
i mean instead of "tar xfvz xfz ISPConfig-3.1-beta.tar.gz" on step 6 with upload of ISPConfig 3.1 only "tar xfvz ISPConfig-3.1-beta.tar.gz" ist ok.
Thank you. But what means (commenting out all existing conflicting options):
How i know which one's is conflicting options?
And what about PHP session files sync?
For the section 5.5, which server is this step being perfomed on?
5.5 MySQL Master-Master-Replication
Create the MySQL-User for the replication and grant the privileg in MySQL:
CREATE USER 'slaveuser1'@'server1.example.tld' IDENTIFIED BY 'slave_user_password';CREATE USER 'slaveuser1'@'192.168.0.105' IDENTIFIED BY 'slave_user_password';CREATE USER 'slaveuser1'@'2001:db8::1' IDENTIFIED BY 'slave_user_password';GRANT REPLICATION SLAVE ON *.* TO 'slaveuser1'@'server1.example.tld'; GRANT REPLICATION SLAVE ON *.* TO 'slaveuser1'@'192.168.0.105';GRANT REPLICATION SLAVE ON *.* TO 'slaveuser1'@'2001:db8::1';QUIT;
Can someone clarify on which server section 5.5 and 6 commands are to be run?
It is creating a Slave(second server) user to the 1st (master) server.
CREATE USER 'slaveuser1'@'server1.example.tld'
So its on the first, master server or server1.example.tld...
Hi,
last char is missing for server2 in below line
> relay-log-index = slave-relay-log.inde
Best regards,Mounaam
In chapter 5.4 it's important to note that by importing the sql from server1 to the slave you overwrite your MySQL credentials.
I had different SQL passwords for root on both servers and of course the login didn't work on the slave after overwriting it.
Is there a reason why we don't install webinterface on server 2?
So If I shutdown the ISPConfig server 1 how can I see the interface?
And where is mentioned that you would need some sort of SQL-DB installed first?
I am not quite sure about high availability. Lets imagine that my server1 goes down, server2 keeps going fully functional. If I have website that's in my servers www.site.tld has A record thats pointing to server1 IP-address. In this situation when I am trying to access my site, it's not available, because server1 is down. And if I am not using low TTL, I cannot even change dns IP manually, so it's getting spread around fast enough. Even if you give www.site.tld two a records (both server IP's) it's only working on every two requests (round-robin rule), you know it's not good solution either in this situation.As my opinion it would be great if server1 dns uses it's own IP in A-records etc... and server2 uses it's own. Of course this still needs low TTL, but even with that, it would be much more high available than this current solution.Or is there something I just don't understand corretly :/
Hello,
i don not really understand, why i have to do 5.1-5.4 a mysql Master-Slave Cluster and on position 5.5 a master-master cluster.
Is 5.5. alternative?
Thanks a lot
Tobias
if i want to sync through other port than 22, for example 2222, where can i modifying that scrip for unison?
Thank you for your tutorial. I personally didn´t know, that it was that easy to sync dovecot. I still have one question: where does the Loadbalancing happen (as mentioned in the introduction text)? Currently it seems to me, if the master goes down, the pages go down too, because most people just point their DNS to the Master. Or do I miss something?
Excellent article!
Any thoughts on configuring more nodes to the HA cluster outlined in your article?
Regards.
Hi,If the master fails, and the email are redirected to slave until master si back, the received mails on the slave will be replicated back to master when this will be available again?
How can be managed from DNS to always use the master and just if it fails to use the slave server (for web and emails)?
Thanl you.
Can we do multiserver setup with centos/RHEL?
Yes. But there is no tutorial available for that setup.
Found an Issue with the database replication not being passed from one ispconfig server to the other and it was failing with a log error. You do need to specify the relay-log and relay-index information in the my.cnf files. See this link for more information. The log showed in the syslog after i finished setup and ispconfig starting flagging datalog_status_u_server that changes hadnt been applied to all systems.
https://forums.mysql.com/read.php?26,207174,216663#msg-216663
Hi,
When a Debian 9 version of this How to?
Thanks in advance!
i am also wondering if this will work by using the debian 9 version.
Thanks for a great tutorial. One more thing is Let's encrypt. Servers must share /etc/letsencrypt and /usr/local/ispconfig/interface/acme to make it work properly. I use NFS and it works just fine.
Just waiting for the Debian 10 tutorial.
Hi Till,
Can I install it on Proxmox?
I have setup but can't find file config-db.php to copy. I'm on debian 10
I have 2 errors in the system.
1: It does not sync https domains. <VirtualHost *: 443> missing
2: In the master I have domains with php 7.2 and php 5.6, it does not synchronize the versions of php.
Could you help me?
/root/.unison/web.prf numericids=true # After sync, the master file owner was changed numericids=false # After sync, the master and slave file owner was sync as same
I have a problem, I request your help:
I register a new website, I select a version of PHP. The PHP version on server 1 is the same version that I selected but on server 2 (mirror) the default PHP version is always set.This happens to me with all websites, whether new or old.
How can I fix?