When database multiplexing mode is used, use the mc_ctl command to start and stop the instance and Mirroring Controller at the same time.
Do not start or stop the instance by itself.
Starting Mirroring Controller
While Mirroring Controller is in a stopped state, execute the mc_ctl command in start mode to start Mirroring Controller.
Execute the mc_ctl command in start mode.
Example)
$ mc_ctl start -M /mcdir/inst1
When only the instance is started and stopped, the following will happen:
When only the instance is started
Features such as automatic switch and automatic disconnection will not work until Mirroring Controller is started.
When only the instance is stopped
Mirroring Controller determines that an error has occurred in the instance, and performs an unnecessary automatic switch.
Automatic switch may also stop working correctly in some cases.
Execute the mc_ctl command in start mode with the -F option specified.
Example)
$ mc_ctl start -M /mcdir/inst1 -F
When only the instance is started and stopped, the following will happen:
When only the instance is started
Errors indicated in "1.1 What is Database Multiplexing Mode" will not be detected until Mirroring Controller is started.
When only the instance is stopped
Mirroring Controller determines that an error has occurred in the instance, and outputs an error to the system log.
Point
To start the Mirroring Controller process only, execute the mc_ctl command in start mode with the --mc-only option specified.
After Mirroring Controller is started, automatic switch/disconnection can be enabled or disabled using the enable-failover or disable-failover mode of the mc_ctl command.
When the arbitration server is used for automatic degradation, the Mirroring Controller process startup fails on the database server if the Mirroring Controller arbitration process has not been started on the arbitration server in advance. However, even if the Mirroring Controller arbitration process cannot be started in advance, the Mirroring Controller process can be started by specifying the --async-connect-arbiter option in the mc_ctl command.
Note
When the arbitration server is used for automatic degradation, the database server must connect to the arbitration server, and as a result, Mirroring Controller startup may take longer.
Mirroring Controller startup usually fails if the standby server is mistakenly started as the primary server or if the old primary server is not recovered after the switch and is then mistakenly started as the primary server. However, if the admin network is disconnected, then startup does not fail, and both servers may become primary servers. Therefore, ensure that the admin network is connected before starting Mirroring Controller.
Stopping Mirroring Controller
While Mirroring Controller is running, execute the mc_ctl command in stop mode to stop Mirroring Controller process.
Example)
$ mc_ctl stop -M /mcdir/inst1
Point
To stop the Mirroring Controller process only, execute the mc_ctl command in stop mode with the --mc-only option specified.
Note
To prevent an unintended automatic switch, before shutting down the operating system on the primary server, you must stop the Mirroring Controller, or shut down the operating system on the standby server.
See
Refer to the Reference for information on how to specify the mc_ctl command.