An active/active configuration consists of two or more servers actively running a different database instance with each serving as a backup for each other. The database instances must be on different shared physical disks. For LifeKeeper configurations supporting multiple MySQL database instances (of the same or different versions), SIOS recommends that the mysqld Group feature be used for versions of MySQL that support this feature. For these configurations, the my.cnf configuration file will reside in /etc. For MySQL versions that do not support the mysqld Group feature, the my.cnf configuration file must reside in the MySQL data directory shared file system for each database instance (e.g. in Figure 2 below, /shr1/mysql and /shr2/mysql).

Figure 2. Active/Active Configuration, Example 2

Configuration Notes:

  • Each server uses a different MySQL data directory (which includes the database instances (database A and database B) on different shared disks
  • The path to the MySQL data directory is different for each instance defined on the server.
  • The my.cnf configuration file is located in /etc and contains mysqld group sections for each database instance. Each section defines a unique MySQL data directory, port and socket for that database instance. The my.cnf configuration file must be kept in sync on all nodes in the cluster. For systems running versions of MySQL that do not support mysqld Groups, the my.cnf configuration file for each of the database instances is located on the shared drive in the data directory for the database instance. Each configuration file defines a unique MySQL data directory, port and socket definition for that database instance.
  • The MySQL executables are located on a local drive on each server in /usr/bin.
  • Initially, Server 1 runs databaseA and Server 2 runs databaseB. In a switchover situation, one server can run both databases.

Creating the first resource hierarchy on Server 1:

Server: Server 1
Directory of my.cnf File Location: /etc
Directory of my MySQL Executables Location: /usr/bin
Database Tag: mysql-shared.example.instance1

Extending the first resource hierarchy to Server 2:

Template Server: Server 1
Tag to Extend: mysql-shared.example.instance1
Target Server: Server2
Target Priority: 10
Directory of my.cnf File Location: /etc
Directory of my MySQL Executables Location: /usr/bin
Database Tag: mysql-shared.example.instance1

Creating the second resource hierarchy on Server 2:

Server: Server 2
Directory of my.cnf File Location: /etc
Directory of my MySQL Executables Location: /usr/bin
Database Tag: mysql-shared.example.instance2

Extending the second resource hierarchy to Server 1:

Template Server: Server 2
Tag to Extend: mysql-shared.example.instance2
Target Server: Server1
Target Priority: 10
Directory of my.cnf File Location: /etc
Directory of my MySQL Executables Location: /usr/bin
Database Tag: mysql-shared.example.instance2

Configuration Notes:

  • Each server uses a different MySQL data directory (which includes the database instances (database A and database B) on different shared disks
  • The path to the MySQL data directory is different for each database instance defined on the server.
  • The my.cnf configuration file is located in /etc and contains mysqld group sections for each database instance. Each section defines a unique MySQL data directory, port and socket for that database instance. The my.cnf configuration file must be kept in sync on all nodes in the cluster. For systems running versions of MySQL that do not support mysqld Groups, the my.cnf configuration file for each of the database instances is located on the shared drive in the data directory for the database. Each configuration file defines a unique MySQL data directory, port and socket definition for that database instance.
  • There is a copy of the MySQL executables on each of the shared disks that contains the data directories.
  • Initially, Server 1 runs databaseA and Server 2 runs databaseB. In a switchover situation, one server can run both database instances.

Creating the first resource hierarchy on Server 1:

Server: Server1
Directory of my.cnf File Location: /etc
Directory of MySQL Executables Location: /shr1/mysqlbin
Database Tag: mysql-shared.example.instance1

Extending the first resource hierarchy to Server 2:

Template Server: Server1
Tag to Extend: mysql-shared.example.instance1
Target Server: Server2
Target Priority: 10
Directory of my.cnf File Location: /etc
Directory of MySQL Executables Location: /shr1/mysqlbin
Database Tag: mysql-shared.example.instance1

Creating the second resource hierarchy on Server 2:

Server: Server2
Directory of my.cnf File Location: /etc
Directory of MySQL Executables Location: /shr2/mysqlbin
Database Tag: mysql-shared.example.instance2

Extending the second resource hierarchy to Server 1:

Template Server: Server2
Tag to Extend: mysql-shared.example.instance2
Target Server: Server1
Target Priority: 10
Directory of my.cnf File Location: /etc
Directory of MySQL Executables Location: /shr2/mysqlbin
Database Tag: mysql-shared.example.instance2

Feedback

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.

Post your comment on this topic.

Post Comment