Contribute  :  Advanced Search  :  Directory  :  Forum  :  FAQ's  :  My Downloads  :  Links  :  Polls  
AFP548 Changing the world one server at a time.
Welcome to AFP548
Thursday, July 29 2010 @ 09:27 am MDT
Advertising

 Forum Index > Questions and Answers > Open Directory New Topic Post Reply
 10.5 OD adding custom schemas
 |  Printable Version
jokke
 Friday, November 07 2008 @ 07:10 am MST (Read 899 times)  


Status: offline

Registered: 01/04/01
Posts: 4

I'm finally moving our tiger world to leopard time and I'm having hard time to get custom schemas to be read by slapd. In 10.4 I added my custom schemas at the end of the apple.schema and it worked. I've tried that and also tried the new way that slapd versions > 2.3 seems to offer to load new schemas even at the runtime but I'm failing badly. I don't get any errors at start time but when I try to add the new objectClass or extended attribute I get 'additional info: objectClass: value #0 invalid per syntax' which seems to point that I'm adding oc that slapd has no idea about.

Anybody done this? Any hints what to look for?


tia,
Yogi


 
Profile Email
Quote
jokke
 Wednesday, November 12 2008 @ 04:58 am MST  


Status: offline

Registered: 01/04/01
Posts: 4

Well it seems that there's some trickery how to correctly format the slapd configuration files when they follow the new LDAP enabled config model. And if you have both, the new way to store configs and the old single file way, the new way takes precedence and what ever you store to slapd.conf file doesn't get read at startup nor are the schema files at schema directory read. By naming the slapd.d directory at /etc/openldap/ to something else, the old config files (and schema files) get read so if you've had your custom schemas there on tiger server this way you can restore that behavior.

On the other hand the new way to store configs and have the changes to be read at runtime is quite nice, so I'll try to figure out how to do correctly custom schemas with that and post results here in case anybody stumbles to this thread at later day.

jokke


 
Profile Email
Quote
jokke
 Wednesday, November 12 2008 @ 05:49 am MST  


Status: offline

Registered: 01/04/01
Posts: 4

Seems that if you want custom schemas you have to let openldap do the conversion to the new model. To the point, set up your custom schema file as you would have done previously (include statement in slapd.conf and the schema file under schema directory). Then stop slapd and trash (or stash) the old slapd.d directory and create a new slapd.d (check that the permissions are the same on) directory. After that you just type

#> slaptest -f slapd.conf -F slapd.d

and boom, you have slapd.d hierarchy that has your custom schemas. Now just start slapd again and start adding yuor attributes.

jokke


 
Profile Email
Quote
macshome
 Wednesday, November 12 2008 @ 02:07 pm MST  
Forum Admin
Admin

Status: offline

Registered: 01/04/01
Posts: 1271

Thanks for the tips!


Breaking my server to save yours. Josh Wisenbaker www.afp548.com
 
Profile Email Website
Quote
MacTroll
 Thursday, November 13 2008 @ 07:43 am MST  
Forum Admin
Admin

Status: offline

Registered: 01/04/01
Posts: 2871

Just be careful when you create a new replica after you've setup custom schema like that. In fact, that would be a good thing for you to test, as I haven't spent much time with that on 10.5.


Changing the world, one server at a time. Joel Rennich
 
Profile Email Website
Quote
jokke
 Monday, November 17 2008 @ 05:28 am MST  


Status: offline

Registered: 01/04/01
Posts: 4

I'll be setting up a test replica and post the results here also.

jokke


 
Profile Email
Quote
Content generated in: 0.26 seconds
New Topic Post Reply



 All times are MDT. The time is now 09:27 am.
Normal Topic Normal Topic
Locked Topic Locked Topic
Sticky Topic Sticky Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Anonymous users can post 
Full HTML Allowed 
Censored Content