[PATCH] s4-drs: Patches related to Urgent Replication

Fernando J V da Silva fernandojvsilva at yahoo.com.br
Fri Feb 5 04:53:20 MST 2010


Hi!

The first patch fixes a few bugs related to urgent replication. As a
modify operation also happens when an object is deleted, It was
necessary to distinguish if such modify operation was called by a
common modify or by a delete operation, otherwise it would enable an
urgent replication when deleting an object, when it was necessary only
if such object was updated. To distinguish delete from modify, I read
the "isDeleted" attribute in msg ... Would it be a suitable solution?

The second patch is an adaptation from the function that Tridge wrote
in our last meeting. To return both the uSNHighest and the uSNUrgent,
I used a dictionary in python.

The third patch contains a test script for urgent replication, but
there are a few issues regarding it:
    - If I run it using something like "python
lib/ldb/tests/python/urgent_replication.py
~/prefix.s4/private/sam.ldb" it works correctly. But if I run it using
make test "make test TESTS=urgent_replication.python" then I get two
problems: 1) The "relax:0" control doesn't seem to work, and I get a
LDAP_UNWILLING_TO_PERFORM error when I try to create nTDSDSA or
rIDManager objects and 2) There's a delay between the object creation
and the @REPLCHANGED updating, so if I check uSNHighest and uSNUrgent
right after adding an object from python, they won't have the expected
values. Are those behaviors expected in such situations? If so, is
there any way to make "relax:0" work for creating objects? And is
there any way to "synchronize" the creation/modification of an object
and the update of @REPLCHANGED caused by such operations?
     - I couldn't delete an object from schema partition (where
attributeSchema and classSchema objects should be inside) so I suppose
the tests for attributeSchema and classSchema may be wrong, as I'm
trying to add those objects then update them but not delete them. Is
it possible to create those objects inside another container (or
something like this ...) so I could delete them? Or is there another
better approach for these tests?

PS: These patches are also available at my repository in repo.or.cz


Best Regards,

-- 
Fernando J V da Silva
M Sc Computer Science Student
Institute of Computing, State University of Campinas
+55 15 8801-2165
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-s4-drs-Fixes-bugs-regarding-Urgent-Replication-on-w.patch
Type: text/x-patch
Size: 3161 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20100205/140b1ebb/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-s4-drs-Function-for-accessing-dsdb_load_partition_u.patch
Type: text/x-patch
Size: 2436 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20100205/140b1ebb/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-s4-drs-Test-situations-for-Urgent-Replication.patch
Type: text/x-patch
Size: 19342 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20100205/140b1ebb/attachment-0002.bin>


More information about the samba-technical mailing list