Does SET MIRROR OPTION synchronization_mode actually affect HA operations after the servers have started?

Does SET MIRROR OPTION synchronization_mode have any effect on an old-school HA setup that uses -xp instead of CREATE MIRROR SERVER?

Is DB_PROPERTY ( 'MirrorMode' ) supposed to show the effect of SET MIRROR OPTION synchronization_mode or not?

The following version behavior has been noticed in BOTH old-school and declarative HA setups; note that the option_value and MirrorMode values are different:

SET MIRROR OPTION synchronization_mode = 'asynchronous';
SELECT DB_PROPERTY ( 'MirrorMode' );



asked 18 Feb '14, 10:27

Breck%20Carter's gravatar image

Breck Carter
accept rate: 20%

edited 19 Feb '14, 15:17

Ian%20McHardy's gravatar image

Ian McHardy

Does upgrading to a newer EBF resolve the issue? On changing the synchronization_mode using SET MIRROR OPTION seems to update the MirrorMode property immediately. This appears to have been addressed by CR#666011 in builds 3327 and higher.

(18 Feb '14, 13:15) Mikel Rychliski

The current behaviour (in and I believe in the current is for:

  • when a database starts (including restarting after for example, loss of quorum) the MirrorMode comes from the first of: -xp mode=value OR the synchronization_mode mirror option OR the default of synchronous
  • if SET MIRROR OPTION synchronization_mode = 'asynchronous' is executed, that is effective immediately. However, if the -xp mode=value is specified on the command line, the next time the database starts or restarts, if the command line value (-xp mode=value) is specified, it will override the mirror option.

Note that you should either be using the SQL Anywhere 11 -xp options OR using the SQL Anywhere 12 SET MIRROR OPTIONS and CREATE/ALTER MIRROR SERVER ... syntaxes. Mixing the old and new syntaxes is not recommended and at your own risk. (Note that the SQL Anywhere 11 -xp options are deprecated in 12 and 16 and no longer documented. Support for these old -xp options will be removed in a future version since they can create confusion.)

From a quick look at CR#666011 , I believe that before that fix, SET MIRROR OPTION synchronization_mode = 'asynchronous'; incorrectly set the mode to synchronous.

Given the many mirroring issues that have been fixed since, I recommend upgrading to a recent build.

permanent link

answered 19 Feb '14, 14:18

Ian%20McHardy's gravatar image

Ian McHardy
accept rate: 40%

edited 19 Feb '14, 14:20

if SET MIRROR OPTION synchronization_mode = 'asynchronous' is executed, that is effective immediately.

Is that behaviour the same for the other two modes, too, i.e. is a change of the synchronization mode via SET MIRROR OPTION generally effective immediately?

(20 Feb '14, 03:26) Volker Barth
Replies hidden

Yes, from a quick look at the code I believe that is the behaviour.

(20 Feb '14, 09:01) Ian McHardy
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 18 Feb '14, 10:27

question was seen: 1,873 times

last updated: 20 Feb '14, 09:01