[Fedora-directory-devel] Please review: [Bug 462922] Import of data does not record timestamps...

Noriko Hosoi nhosoi at redhat.com
Tue Nov 4 16:14:38 UTC 2008


[Bug 462922] Import of data does not record timestamps...

https://bugzilla.redhat.com/show_bug.cgi?id=462922

[Problem description]
During the setup, I import a ldif file, which contains just the suffix object
(with the InstallLdifFile option during silent setup). 

The createTimestamp and modifyTimestamp operational attributes were not
generated during this import. This eventually leads into a WARNING message,
when I create vlv indexes for the timestamp attributes.

See the following thread from the mailing list.
https://www.redhat.com/archives/fedora-directory-users/2008-September/msg00084.html

Comment by Rich in the mailing list: createTimestamp should be present, unless
you have nsslapd-lastmod turned off.

[Fix proposal]
 --> (https://bugzilla.redhat.com/attachment.cgi?id=322441)
cvs diff ldap/servers/slapd/back-ldbm/import-threads.c

File: ldapserver/ldap/servers/slapd/back-ldbm/import-threads.c

Description: add a static function import_add_created_attrs to add
CreatorsName, ModifiersName, CreateTimestamp, ModifyTimestamp to each imported
entry.  I also added a check if nsslapd-lastmod is on or off.  It adds the created 
info only if the lastmod is on.

Sample entry:
 dn: dc=example,dc=com
 objectClass: top
 [...]
 nsUniqueId: ce7e5ea2-aa4011dd-b970c0aa-ead44d23
 creatorsName:
 modifiersName:
 createTimestamp: 20081104071841Z
 modifyTimestamp: 20081104071841Z

Please note: creatorsName and modifiersName are empty.  I followed the 
"add" case, which leaves the names empty when the creator's name is not 
available.  For the imported entries, we can choose not to put the name 
lines at all.  I'd like to have your comments on it, which would be more 
reasonable.

Thanks,
--noriko
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3237 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://listman.redhat.com/archives/fedora-directory-devel/attachments/20081104/7810d145/attachment.bin>


More information about the Fedora-directory-devel mailing list