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

Re: LDIF help needed -- v1 to v2 structure




On Tuesday, May 7, 2002, at 07:52 , Chad Leigh -- Shire.Net LLC wrote:


On Tuesday, May 7, 2002, at 07:42 , Abhishek Srivastava wrote:

try using this:
ldapmodify -x -c -D "cn=MY, dc=blah, dc=com" -w "Directory password" -f
vd2.ldif

Give the directory password in -w option

Hi

Thanks for your idea. I get the following repeated for each record in the LDIF when doing the above ldapmodify:

ldif_record() = 32
modifying entry "shireNetDomain=piedmontflag.com, dc=blah, dc=com"
ldap_modify: No such object

With v1 I had to add them and could then modify them as needed using ldapadd and ldapmodify respectively.

When I do a -a with it to add it in I get:

ldif_record() = 32
add objectclass:
        shireNetVirtualDomain
add shireNetDomain:
        chromasync.com
add shireNetAcceptAnyMail:
        N
adding new entry "shireNetDomain=chromasync.com, dc=blah, dc=com"
ldap_add: No such object
        additional info: parent does not exist

I am confused at why it expects a parent. I have read and reread the part about schema in the userguide at www.openldap.org and am confused by this...

thanks
Chad



Is there something about how I defined my schema that could be blocking this?


Thanks
Chad



-----Original Message----- From: owner-openldap-software@OpenLDAP.org [mailto:owner-openldap-software@OpenLDAP.org]On Behalf Of Chad Leigh -- Shire.Net LLC Sent: Tuesday, May 07, 2002 4:32 PM To: openldap-software@OpenLDAP.org Cc: chad@shire.net Subject: LDIF help needed -- v1 to v2 structure


Hi

I have a v1 database that is working.  Here is what the schema looked
like:

objectclass virtualDomain
         requires
                 objectClass,
                 domain,
                 acceptanymail

objectclass emailaccount
         requires
                 objectClass,
                 accountName,
                 emailAddress,
                 domain,
                 mailboxLoc,
                 userpassword,
                 accountActive,
                 virusScan,
                 spamFilter

objectclass emailforward
         requires
                 objectClass,
                 accountName,
                 domain,
                 forwardAddress,
                 userpassword,
                 accountActive,
                 virusScan,
                 spamFilter

I made a v2 schema (and added some additional attributes) for the above,
and I changed attribute names to make them my_domain specific




attributetype ( 1.3.6.1.4.1.8250.2.1.1 NAME 'shireNetDomain'
         DESC 'domain name'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )

attributetype ( 1.3.6.1.4.1.8250.2.1.2 NAME 'shireNetAcceptAnyMail'
DESC 'modifies domain -- Y if domain should catchall -- N if not'
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )


attributetype ( 1.3.6.1.4.1.8250.2.1.3 NAME 'shireNetAccountName'
         DESC 'username within the domain '
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.4 NAME 'shireNetEmailAddress'
         DESC 'complete email address'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.5 NAME 'shireNetMailboxLoc'
         DESC 'file system path to where the mailbox is located'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )

attributetype ( 1.3.6.1.4.1.8250.2.1.6 NAME 'shireNetUserPassword'
         DESC 'user password'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 )

attributetype ( 1.3.6.1.4.1.8250.2.1.7 NAME 'shireNetAccountActive'
         DESC 'Y if active N otherwise '
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.8 NAME 'shireNetVirusScan'
DESC 'do a virusscan on this account -- Y if active N otherwise '
EQUALITY caseIgnoreMatch
SUBSTR caseIgnoreSubstringsMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )


attributetype ( 1.3.6.1.4.1.8250.2.1.9 NAME 'shireNetSpamFilter'
         DESC 'do a spamfilter on this account -- Y if active N
otherwise '
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.10 NAME 'shireNetForwardAddress'
         DESC 'address to forward to '
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.11 NAME 'shireNetVacation'
         DESC 'Y for do a vacation mesage -- N otherwise or just not
existant'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.12 NAME 'shireNetVacationSubject'
         DESC ' Subject for vacation email'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.13 NAME 'shireNetVacationText'
         DESC ' text body for vacation email'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )

attributetype ( 1.3.6.1.4.1.8250.2.1.14 NAME 'shireNetDefaultAddress'
         DESC ' text body for vacation email'
         EQUALITY caseIgnoreMatch
         SUBSTR caseIgnoreSubstringsMatch
         SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )


objectclass ( 1.3.6.1.4.1.8250.2.2.1 NAME 'shireNetVirtualDomain' DESC 'defines a virtual domain' MUST ( objectClass $ shireNetDomain $ shireNetAcceptAnyMail ) MAY shireNetDefaultAddress )

objectclass ( 1.3.6.1.4.1.8250.2.2.2 NAME 'shireNetEmailAccount'
DESC 'defines a virtual domain email account'
MUST ( objectClass $ shireNetAccountName $ shireNetEmailAddress $
shireNetDomain $ shirenetMailboxLoc $
shireNetUserPassword $
shireNetAccountActive $ shireNetVirusScan $
shireNetSpamFilter )
MAY ( shireNetVacation $ shireNetVacationSubject $
shireNetVacationText ) )


objectclass ( 1.3.6.1.4.1.8250.2.2.3 NAME 'shireNetEmailForward'
         DESC 'defines a virtual domain email account'
         MUST ( objectClass $ shireNetAccountName $
                 shireNetDomain $ shirenetForwardAddress $
shireNetUserPassword $
                 shireNetAccountActive $ shireNetVirusScan $
shireNetSpamFilter  )
         MAY  ( shireNetVacation $ shireNetVacationSubject $
shireNetVacationText ) )


----

I then dumped the old one into LDIF files and changed the attribute
names and tried to add with ldapadd to the new v2 database.  I get the
error

frog1# ldapadd -W -D "cn=MY, dc=blah, dc=com" -f vd2.ldif
Enter LDAP Password:
adding new entry "shireNetDomain=objectwerks.com, dc=blah, dc=com"
ldap_add: No such object
         additional info: parent does not exist

ldif_record() = 32
frog1#


Here is a sample from the LDIF file:

dn: shireNetDomain=objectwerks.com, dc=blah, dc=com
objectclass: shireNetVirtualDomain
shireNetDomain: objectwerks.com
shireNetAcceptAnyMail: N

dn: shireNetDomain=chromasync.com, dc=blah, dc=com
objectclass: shireNetVirtualDomain
shireNetDomain: chromasync.com
shireNetAcceptAnyMail: N

-----------

I guess my head is not wrapped around this 100%.  Any hints or pointers
or whatever is greatly appreciated.

thanks
Chad