- Report a bug
MMM depends on the ability of the machines in the network to have floating IP addresses and to send ARP notifications to the network peers.
Unfortunately, computing clouds (such as Amazon EC2) do not enable this feature, and you have no control over the IP addresses of your machines.
Therefore, the ns_agent contribution was made in order to allow the use of MMM in an environemnt where modifications on the network level are not available, but you do have control of a nameserver in the network.
This contribution is an initial attempt, and is very experimental. Should consider the reliability implication of using a nameserver and the name resolving process in a delicate high-availability environment.
So far, tested on a staging cluster on EC2, functioned well.
Awaiting community feedback.
* Convert ns_agent to Perl (currently written in PHP) * Clean up code from commented out sections * Test on several environments and several usecases
Currently in contrib/ns_agent
1. Run ns_agent.php (accompanied by mmm_ns_agent.conf) on the nameserver machine.
2. Add the following section to mmm_agent.conf on all database nodes:
nameserver <<nameserver_name>> ip <<nameserver ip address>> port <<ns_agent port>>
3. Replace /usr/local/mmm/lib/ifconfig.pm with the one provided with this contribution.
4. On the mmm monitor daemon config (mmm_mon.conf), replace any occurence of the floating IP address with the FQDN of the relevant host. For example:
Replace:
role writer mode exclusive servers ec2_db1 ip 192.168.100.101
With:
role writer mode exclusive servers ec2_db1 ip writer.mydomain.com
5. Configure the nameserver to answer queries for mydomain.com, have very low TTL, and make sure the zone file name matches the one in mmm_ns_agent.conf.
6. Set all the machines resolver to your nameserver.