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

Re: can't modify or add uidNumber attribute



yes, i've seen it.

but now i can't use also ldapsearch, please take a look of syslog:

Mar 26 16:11:33 amahoro slapd[1603]: @(#) $OpenLDAP: slapd 2.4.23 (Jun 16 2011 02:53:39) $#012#011buildd@murphy:/build/buildd-openldap_2.4.23-7.2-i386-Y1mwvF/openldap-2.4.23/debian/build/servers/slapd Mar 26 16:11:33 amahoro slapd[1604]: hdb_db_open: database "dc=amahoro,dc=bi" cannot be opened, err 13. Restore from backup! Mar 26 16:11:33 amahoro slapd[1604]: bdb(dc=amahoro,dc=bi): txn_checkpoint interface requires an environment configured for the transaction subsystem Mar 26 16:11:33 amahoro slapd[1604]: bdb_db_close: database "dc=amahoro,dc=bi": txn_checkpoint failed: Invalid argument (22). Mar 26 16:11:33 amahoro slapd[1604]: backend_startup_one (type=hdb, suffix="dc=amahoro,dc=bi"): bi_db_open failed! (13) Mar 26 16:11:33 amahoro slapd[1604]: bdb_db_close: database "dc=amahoro,dc=bi": alock_close failed
Mar 26 16:11:33 amahoro slapd[1604]: slapd stopped.

i don't understand this error type


On 03/26/2012 05:06 PM, Ondrej Kuznik wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 03/26/2012 04:21 PM, stefano wrote:
hi, i was modifying uidNumber attribute of a user but then has been
standing for a few minutes and I stopped it:
root@amahoro:~# ldapmodify -x -W -D 'cn=Manager,dc=amahoro,dc=bi'
Enter LDAP Password:
dn: uid=stefano,cn=Admins,dc=amahoro,dc=bi
changetype: modify
replace: uidNumber
uidNumber: 1001

modifying entry "uid=stefano,cn=Admins,dc=amahoro,dc=bi"
It has successfully performed the modification and was waiting for more
input, a Ctrl-D would have sufficed.

.
.
.
ctrl+c

then with an ldapsearch for this user there was not the uidNumber attribute:

dn: uid=stefano,cn=Admins,dc=amahoro,dc=bi
uid: stefano
[...]
userPassword:: e1NTSEF9b2pNOG1UT3NrT2ZVaDVyd1pUWUpSeWg3YXNxc1lXSHo=
uidNumber: 1001

The uidnumber is right above, as the last line of the entry.

trying to add it

root@amahoro:~# ldapmodify -x -W -D 'cn=Manager,dc=amahoro,dc=bi'
Enter LDAP Password:
dn: uid=stefano,cn=Admins,dc=amahoro,dc=bi
changetype: add
add: uidNumber
uidNumber: 1001

adding new entry "uid=stefano,cn=Admins,dc=amahoro,dc=bi"
ldap_add: Undefined attribute type (17)
     additional info: add: attribute type undefined

you can see the error message
what is wrong?
Please read on the ldif format, either RFC 2849 or at least man 5 ldif.
With the above ldif you were trying to add an entry with attribute "add".

- --
Ondrej Kuznik
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk9whdkACgkQ9GWxeeH+cXtUbgCfU/QT76qgOdXYivbyvc2nEcyA
LNcAoI/Gn0NWwQ8Q3QBuDaGSj1sZUPxB
=bZXI
-----END PGP SIGNATURE-----

This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you for understanding.