[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Correct way to load LDIF in mirrormode

On Sat, Nov 21, 2009 at 7:10 PM, Howard Chu <hyc@symas.com> wrote:
> If this is true, then would i also be correct is saying that -S <sid>
> only sets a parameter to enable the -w option to set the SID correctly
> in CSN's etc? and that the value provided by -S has no effect if -w is
> not provided ?


hmmm.. csnsid in slapadd.c defaults to 0, unless the -S option is given, but let us assume it is given -S 1, so csnsid=1

if the -w option is specified, then update_ctxcsn is >0

it looks like slapadd will create the berval csn (in memory) which takes the value of csnsid, but it will only write related data if (update_ctxcsn)

but for multimaster the csnsid is used (thus must be provided) to find it's own CSN, but unless update_ctxcsn is >0, it wont change any state?

so maybe -S <sid> is required (with or without -w) to initialize multimaster to find the correct CSN (as other master's CSN's could be present? - i dont quite get why though if we are re-loading the database), but for mirrormode -S <sid> is not required (if there is no -w), but only because any other <sid>'s are likely to be shadow contexts in the initial case of a data load ?