Hi, for particular reasons entries have to have a multi valued otherMailbox attribute, something like
dn: cn=foo bar,ou=some ou objectclass: inetorgPerson objectclass: extensibleObject ... otherMailbox: SMTP$joe@example.com otherMailbox: smtp$foo@bar.com
Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
-Dieter
Dieter Kluenter skrev, on 12-10-2007 16:39:
for particular reasons entries have to have a multi valued otherMailbox attribute, something like
dn: cn=foo bar,ou=some ou objectclass: inetorgPerson objectclass: extensibleObject ... otherMailbox: SMTP$joe@example.com otherMailbox: smtp$foo@bar.com
Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
Why "particular reasons entries have to have a multi valued otherMailbox attribute"? Design fault, or inescapable idiot client?
Explanation: At my high school site, users (i.e. cn, uid) often have to have multiple mail attributes (objectClasses: courierMailAccount, courierMailAlias, evolutionPersonlist, inetOrgPerson, mailRecipient and a couple of others). It is important that they have multiple mail attributes for a couple or three reasons, all to do with Postfix.
Why can't you do the same?
Best,
--Tonni
Tony Earnshaw skrev, on 12-10-2007 17:56:
[...]
Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
Hmmm ... I see that otherMailbox an attribute is of objectClass pilotPerson (schemas [cosine|openldap].schema. Using gq I also see that there are no Equality, Ordering or Substrings specified. Whereas there are for attribute mail. It would seem that there is no matching rule in the schemas. There doesn't seem to be any bug in OL, it's simply doing its job.
Pity you don't quote your OL version, mine is 2.3.38.
--Tonni
Tony,
Tony Earnshaw tonni@hetnet.nl writes:
Tony Earnshaw skrev, on 12-10-2007 17:56:
[...]
Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
Hmmm ... I see that otherMailbox an attribute is of objectClass pilotPerson (schemas [cosine|openldap].schema. Using gq I also see that there are no Equality, Ordering or Substrings specified. Whereas there are for attribute mail. It would seem that there is no matching rule in the schemas. There doesn't seem to be any bug in OL, it's simply doing its job.
Pity you don't quote your OL version, mine is 2.3.38.
Come on Tony, if you really want to know, take your pick from 2.3.35 to yesterdays HEAD on SuSE-9,3, openSUSE-10.2, openSUSE-10.3, Sun Solaris-10 on x86 and x86_64 platforms.
-Dieter
Tony Earnshaw tonni@hetnet.nl writes:
Dieter Kluenter skrev, on 12-10-2007 16:39:
for particular reasons entries have to have a multi valued otherMailbox attribute, something like dn: cn=foo bar,ou=some ou objectclass: inetorgPerson objectclass: extensibleObject ... otherMailbox: SMTP$joe@example.com otherMailbox: smtp$foo@bar.com Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
Why "particular reasons entries have to have a multi valued otherMailbox attribute"? Design fault, or inescapable idiot client?
Because it is not my job nore my position to discuss the directory design.
Explanation: At my high school site, users (i.e. cn, uid) often have to have multiple mail attributes (objectClasses: courierMailAccount, courierMailAlias, evolutionPersonlist, inetOrgPerson, mailRecipient and a couple of others). It is important that they have multiple mail attributes for a couple or three reasons, all to do with Postfix.
Why can't you do the same?
Because my only job is to investigate into this displayed error and document it.
-Dieter
Dieter Kluenter wrote:
Hi, for particular reasons entries have to have a multi valued otherMailbox attribute, something like
dn: cn=foo bar,ou=some ou objectclass: inetorgPerson objectclass: extensibleObject ... otherMailbox: SMTP$joe@example.com otherMailbox: smtp$foo@bar.com
Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
otherMailbox has no matching rule, so you can't add other values, you need to replace the existing values with the new set.
p.
Ing. Pierangelo Masarati OpenLDAP Core Team
SysNet s.r.l. via Dossi, 8 - 27100 Pavia - ITALIA http://www.sys-net.it --------------------------------------- Office: +39 02 23998309 Mobile: +39 333 4963172 Email: pierangelo.masarati@sys-net.it ---------------------------------------
Pierangelo Masarati ando@sys-net.it writes:
Dieter Kluenter wrote:
Hi, for particular reasons entries have to have a multi valued otherMailbox attribute, something like
dn: cn=foo bar,ou=some ou objectclass: inetorgPerson objectclass: extensibleObject ... otherMailbox: SMTP$joe@example.com otherMailbox: smtp$foo@bar.com
Adding the second attribute value I get error 18, inappropriate matching. Is this intended behaviour or is this a bug?
otherMailbox has no matching rule, so you can't add other values, you need to replace the existing values with the new set.
I know there are no matching rules, but still the attribute type is not declared single value, or are matching rules a requirement for multi values?
-Dieter
Dieter Kluenter wrote:
I know there are no matching rules, but still the attribute type is not declared single value, or are matching rules a requirement for multi values?
They are a requirement for adding new values where there already exist some, because if there's no equality rule, no duplicate check can take place. So you need to delete;add (i.e. replace) instead of just add. This way, the client commits to making sure no duplicates are present in the set of values that are added, and the server trusts the client and does not try to check for duplicates.
p.
Ing. Pierangelo Masarati OpenLDAP Core Team
SysNet s.r.l. via Dossi, 8 - 27100 Pavia - ITALIA http://www.sys-net.it --------------------------------------- Office: +39 02 23998309 Mobile: +39 333 4963172 Email: pierangelo.masarati@sys-net.it ---------------------------------------
openldap-software@openldap.org