Importing Schema Extensions
Novell Cool Solutions: Feature
By Israel Forst
Digg This -
Posted: 6 Dec 2002
I've created some schema extensions in a test tree on my laptop, now I need to get it on to my office system, and I don't see any other way except to type them all in again by hand (which is fraught with peril). I know I've done this before, but if you could tell me why I can't import this schema LDIF file, I would appreciate it.
I use Textpad to massage prepare the files for import:
Export your schema as such
C:\Novell\xsl>ldapsearch -h hostname -D cn=admin,o=novell -w password -b cn=schema -s base objectclass=* >c:\temp\schema.txtOpen the file in textpad:
1) delete all the syntax lines i.e.
ldapSyntaxes: ( 220.127.116.11.4.1.1418.104.22.168.1 X-NDS_SYNTAX '9' ) ldapSyntaxes: ( 22.214.171.124.4.1.14126.96.36.199.2 X-NDS_SYNTAX '9' ) and dn: cn=schema objectClass: top objectClass: subschema
2)search for "\nobjectClasses:" and replace with "\n\ndn:
cn=schema\nchangetype: modify\nadd: objectClasses\nobjectClasses:"
3) search for "\nattributeTypes:" and replace with "\n\ndn: cn=schema\nchangetype: modify\nadd: attributeTypes\nattributeTypes:"
Don't include the "" around the search or replace criteria.
Also, be sure you have use regular expressions checked.
Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com