Hello,

Env:
CentOS 6
SAMBA 4.2 (SERNET Package)

i had some problems while importing new schema objects from
http://wiki.sogo.nu/ResourceConfiguration. I used the ldif files for AD. (Of
course i changed DC Parts for my AD before.)

1.)
ldbmodify  -H /var/lib/samba/private/sam.ldb calentry-schema.ldif --
option="dsdb:schema update allowed"=true
ERR: (No such object) "objectclass: Cannot add
CN=Kind,CN=Schema,CN=Configuration,dc=your,dc=domain, parent does not exist!"
on DN CN=Kind,CN=Schema,CN=Configuration,dc=your,dc=domain at block before
line 16
Modify failed after processing 0 records

parent does not exist -> Change your DN !!!

2.)
DN changed and now ...
ldbmodify  -H /var/lib/samba/private/sam.ldb calentry-schema.ldif --
option="dsdb:schema update allowed"=true
...
Unable to find attribute calCalURI in the schema
ERR: (Invalid attribute syntax) "objectclass_attrs: attribute 'mayContain' on
entry 'CN=calEntry,CN=Schema,CN=Configuration,DC=addev,DC=domain,DC=de'
contains at least one invalid value!" on DN
cn=calEntry,cn=Schema,cn=Configuration,dc=addev,dc=domain,dc=de at block
before line 143
Modify failed after processing 9 records
...
Invalid attribute syntax -> I don't know why ... maybe a SAMBA Bug ... I had
to split both ldif files in different parts and delete the "schemaupdatenow"
parts.

Parts:
calentry-schema.ldif -> 2 Parts (attributeSchema|classSchema)
calresource-schema.ldif -> 3 Parts (attributeSchema|classSchema-
>CalendarResource|classSchema->"anything else")

https://lists.samba.org/archive/samba/2014-March/179749.html

3.)
Another import try ...

ldbmodify -H /var/lib/samba/private/sam.ldb calentry-schema_01.ldif --
option="dsdb:schema update allowed"=true
Modified 8 records successfully

ldbmodify -H /var/lib/samba/private/sam.ldb calentry-schema_02.ldif --
option="dsdb:schema update allowed"=true
Modified 1 records successfully

ldbmodify -H /var/lib/samba/private/sam.ldb calresource-schema_01.ldif --
option="dsdb:schema update allowed"=true
Modified 21 records successfully

ldbmodify -H /var/lib/samba/private/sam.ldb calresource-schema_02.ldif --
option="dsdb:schema update allowed"=true
Modified 1 records successfully

ldbmodify -H /var/lib/samba/private/sam.ldb calresource-schema_03.ldif --
option="dsdb:schema update allowed"=true
Modified 4 records successfully

As far as good.

4.)
Then I tried to create a resource with the ldif file from the homepage I
mentioned above under AD-Part.

Btw. this file has a BUG.
...
dn: cn=Big Meetingroom,dc ...
...
cn: Example Meetingroom
...
;-) Please correct this!

ldbadd -H /var/lib/samba/private/sam.ldb a_meetingroom.ldif
ERR: Object class violation : "objectclass_attrs: attribute 'Kind' on entry
'CN=Meetingroom,DC=addev,DC=domain,DC=de' does not exist in the specified
objectclasses!" on DN cn=Meetingroom,dc=addev,dc=domain,dc=de at block before
line 17
Add failed after processing 0 records

And that was the tricky part for me because i don't have much experience with
"Schema" "LDIFS" ... etc. ...

The cause of "Object class violation ... does not exist in the specified
objectclasses" are large and lower cases in calresource-schema_<02|03>.ldif

##########################################
ORIG calresource-schema_02.ldif
...
mayContain: kind
mayContain: nickname
mayContain: description
mayContain: ou
mayContain: calcategories
mayContain: member
mayContain: uniquemember
mayContain: accessibilityurl
mayContain: capacity
mayContain: owner
mayContain: resourcemanager
mayContain: timezoneid
mayContain: multiplebookings
mayContain: maxinstances
mayContain: bookingwindowstart
mayContain: bookingwindowend
mayContain: vcarduid
...

CORRECT calresource-schema_02.ldif
...
mayContain: Kind
mayContain: NickName
mayContain: description
mayContain: ou
mayContain: CalCategories
mayContain: member
mayContain: uniquemember
mayContain: accessibilityURL
mayContain: Capacity
mayContain: owner
mayContain: ResourceManager
mayContain: TimeZoneID
mayContain: Multiplebookings
mayContain: MaxInstances
mayContain: BookingWindowStart
mayContain: BookingWindowEnd
mayContain: VcardUid
...

##########################################
ORIG calresource-schema_03.ldif
...
mayContain: admittanceurl
...
mayContain: inventorylist
mayContain: inventoryurl
...
mayContain: autoschedule
mayContain: approvalinfourl
mayContain: schedadmin
...
mayContain: nocost
mayContain: costurl
...

CORRECT calresource-schema_03.ldif
...
mayContain: AdmittanceURL
...
mayContain: InventoryList
mayContain: InventoryURL
...
mayContain: Autoschedule
mayContain: ApprovalInfoURL
mayContain: SchedAdmin
...
mayContain: Nocost
mayContain: CostURL
##########################################

After changing the mayContain attributes in objectclasses I was able to create
a "meetingroom" and to fill in things in every new attribute.

So ... please.

- Correct add meetingroom ldif file ;-)
- Write another wiki article for samba ...
- ... and upload correct ldif files for samba

Thanks!
-- 
users@sogo.nu
https://inverse.ca/sogo/lists

Reply via email to