Marcio Vogel Merlone dos Santos
2018-Aug-17 16:11 UTC
[Samba] ldbadd: objectclass top is not a valid objectClass
Hi, Trying to add an OU via ldbadd but I get the following error: root at araucaria:~# ldbadd --url=/var/lib/samba/private/sam.ldb /root/ou.ldif ERR: No such attribute : "objectclass topĀ is not a valid objectClass in schema" on DN OU=A1,DC=ad,DC=a1,DC=ind,DC=br at block before line 4 Add failed after processing 0 records root at araucaria:~# root at araucaria:~# cat /root/ou.ldif dn: OU=A1,DC=ad,DC=a1,DC=ind,DC=br objectClass: top objectClass: organizationalunit description: A1 Engenharia root at araucaria:~# DC=ad,DC=a1,DC=ind,DC=br already exists. Any hint? -- *Marcio Merlone*
Rowland Penny
2018-Aug-17 16:35 UTC
[Samba] ldbadd: objectclass top is not a valid objectClass
On Fri, 17 Aug 2018 13:11:34 -0300 Marcio Vogel Merlone dos Santos via samba <samba at lists.samba.org> wrote:> Hi, > > Trying to add an OU via ldbadd but I get the following error: > > root at araucaria:~# ldbadd > --url=/var/lib/samba/private/sam.ldb /root/ou.ldif ERR: No such > attribute : "objectclass topĀ is not a valid objectClass in schema" > on DN OU=A1,DC=ad,DC=a1,DC=ind,DC=br at block before line 4 Add > failed after processing 0 records root at araucaria:~# > > root at araucaria:~# cat /root/ou.ldif > dn: OU=A1,DC=ad,DC=a1,DC=ind,DC=br > objectClass: top > objectClass: organizationalunit > description: A1 Engenharia > root at araucaria:~# > > DC=ad,DC=a1,DC=ind,DC=br already exists. > > Any hint? >I normally use ldbmodify, in which case the ldif syntax would be: dn: OU=A1,DC=ad,DC=a1,DC=ind,DC=br changetype: add objectClass: top objectClass: organizationalunit description: A1 Engenharia So the command would be: ldbmodify --url=/var/lib/samba/private/sam.ldb /root/ou.ldif But I wonder if the problem is 'a1', you are trying to add an OU 'OU=A1' and there is already 'DC=a1' Rowland