Hi,
I am not able to update the data by using ldapmodify command. I am giving a ldif file to ldapmodify which is having update statements but its giving error message as ldapmodify: invalid format (line 5) entry: "mdn=9874938748,dc=onmobile,dc=com".
Command: ldapmodify -D "cn=Manager,dc=onmobile,dc=com" -w secret -x -f insert2.ldif Output: ldapmodify: invalid format (line 5) entry: "mdn=9874938748,dc=onmobile,dc=com".
Sample Data in insert2.ldif
# Subscriber Data number 10000410 dn:mdn=9874942807,dc=onmobile,dc=com changetype: modify replace: model model:Vodafone225 - replace: gprsEnabled gprsEnabled:false
# Subscriber Data number 10000411 dn:mdn=9874942816,dc=onmobile,dc=com changetype: modify replace: model model:Nokia7310Classic - replace: gprsEnabled gprsEnabled:false
# Subscriber Data number 10000412 dn:mdn=9874942825,dc=onmobile,dc=com changetype: modify replace: model model:Nokia1208 - replace: gprsEnabled gprsEnabled:false
# Subscriber Data number 10000413 dn:mdn=9874942826,dc=onmobile,dc=com changetype: modify replace: model model:Nokia1100 - replace: gprsEnabled gprsEnabled:false
# Subscriber Data number 10000414 dn:mdn=9874942833,dc=onmobile,dc=com changetype: modify replace: model model:Nokia5200b - replace: gprsEnabled gprsEnabled:false
# Subscriber Data number 10000415 dn:mdn=9874942855,dc=onmobile,dc=com changetype: modify replace: model model:Nokia1600 - replace: gprsEnabled gprsEnabled:false
# Subscriber Data number 10000416 dn:mdn=9874942861,dc=onmobile,dc=com changetype: modify replace: model model:SamsungS3500 - replace: gprsEnabled gprsEnabled:false
Please help me to resolve this issue.
Best Regards, Kiran Sama 9663371026
--On Wednesday, November 04, 2009 2:59 PM +0530 Kiran Sama kiran.sama@onmobile.com wrote:
# Subscriber Data number 10000410
dn:mdn=9874942807,dc=onmobile,dc=com
Is "mdn" an attribute defined in a schema you loaded?
Also, the format is generally
dn: mdn=....
Note the space
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration
Kiran Sama wrote:
Hi,
I am not able to update the data by using ldapmodify command. I am giving a ldif file to ldapmodify which is having update statements but its giving error message as
ldapmodify: invalid format (line 5) entry: "mdn=9874938748,dc=onmobile,dc=com".
Command:
ldapmodify -D "cn=Manager,dc=onmobile,dc=com" -w secret -x -f insert2.ldif
Output:
ldapmodify: invalid format (line 5) entry: "mdn=9874938748,dc=onmobile,dc=com".
Sample Data in insert2.ldif
# Subscriber Data number 10000410
dn:mdn=9874942807,dc=onmobile,dc=com
changetype: modify
replace: model
model:Vodafone225
replace: gprsEnabled
gprsEnabled:false
# Subscriber Data number 10000411
dn:mdn=9874942816,dc=onmobile,dc=com
changetype: modify
replace: model
model:Nokia7310Classic
replace: gprsEnabled
gprsEnabled:false
# Subscriber Data number 10000412
dn:mdn=9874942825,dc=onmobile,dc=com
changetype: modify
replace: model
model:Nokia1208
replace: gprsEnabled
gprsEnabled:false
# Subscriber Data number 10000413
dn:mdn=9874942826,dc=onmobile,dc=com
changetype: modify
replace: model
model:Nokia1100
replace: gprsEnabled
gprsEnabled:false
# Subscriber Data number 10000414
dn:mdn=9874942833,dc=onmobile,dc=com
changetype: modify
replace: model
model:Nokia5200b
replace: gprsEnabled
gprsEnabled:false
# Subscriber Data number 10000415
dn:mdn=9874942855,dc=onmobile,dc=com
changetype: modify
replace: model
model:Nokia1600
replace: gprsEnabled
gprsEnabled:false
# Subscriber Data number 10000416
dn:mdn=9874942861,dc=onmobile,dc=com
changetype: modify
replace: model
model:SamsungS3500
replace: gprsEnabled
gprsEnabled:false
Please help me to resolve this issue.
Best Regards,
Kiran Sama
9663371026
Hello Kiran,
I'd almost say you are missing some spaces between attribute name and value. As I understood, OpenLDAP's maintenance commands are very strict about this. Please, make sure you have everything like eg.: dn: mdn=9874942861,dc=onmobile,dc=com
for comparsion:
dn:mdn=9874942861,dc=onmobile,dc=com
This applies to all lines and attributes (I think).
I hope this helps.
Regards, Zdenek
openldap-technical@openldap.org