Issue 5908 - slapo-unique man page misleading
Summary: slapo-unique man page misleading
Status: VERIFIED DUPLICATE of issue 9264
Alias: None
Product: OpenLDAP
Classification: Unclassified
Component: documentation (show other issues)
Version: 2.3
Hardware: All All
: --- normal
Target Milestone: ---
Assignee: OpenLDAP project
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-01-28 01:00 UTC by magne.land@citrix.com
Modified: 2020-08-28 23:18 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description magne.land@citrix.com 2009-01-28 01:00:10 UTC
Full_Name: Magne Land
Version: 2.3.43
OS: RHEL 5.1 64-bit
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (72.37.244.20)


Currently the man page of slapo-unique says "enforce uniqueness", which I find
misleading.
Would it be possible to change it to say "makes the best effort to enforce
uniqueness" or something to that effect?

Comment 1 Gavin Henry 2009-01-28 22:31:35 UTC
moved from Incoming to Documentation
Comment 2 Gavin Henry 2009-01-28 22:33:03 UTC
> Full_Name: Magne Land
> Version: 2.3.43
> OS: RHEL 5.1 64-bit
> URL: ftp://ftp.openldap.org/incoming/
> Submission from: (NULL) (72.37.244.20)
> 
> 
> Currently the man page of slapo-unique says "enforce uniqueness", which I
find
> misleading.
> Would it be possible to change it to say "makes the best effort to enforce
> uniqueness" or something to that effect?
> 
> 

It would need more words than that to comment on what exactly happens i.e. why
it is a "best effort".

Comment 3 magne.land@citrix.com 2009-01-28 22:39:11 UTC
Hi,
Please see this thread for background info:
http://www.openldap.org/lists/openldap-software/200901/msg00112.html

To me, something is either guaranteed or not. And I think "enforce" means something that is guaranteed.
In this case, the uniqueness is not guaranteed, therefore it is not enforced.

Regards,
Magne Land

On 1/28/09 2:33 PM, "Gavin Henry" <openldap-its@OpenLDAP.org> wrote:

> Full_Name: Magne Land
> Version: 2.3.43
> OS: RHEL 5.1 64-bit
> URL: ftp://ftp.openldap.org/incoming/
> Submission from: (NULL) (72.37.244.20)
>
>
> Currently the man page of slapo-unique says "enforce uniqueness", which I
find
> misleading.
> Would it be possible to change it to say "makes the best effort to enforce
> uniqueness" or something to that effect?
>
>

It would need more words than that to comment on what exactly happens i.e. why
it is a "best effort".




Comment 4 Quanah Gibson-Mount 2009-01-29 00:25:23 UTC

--On January 28, 2009 10:39:41 PM +0000 Magne.Land@citrix.com wrote:

> Hi,
> Please see this thread for background info:
> http://www.openldap.org/lists/openldap-software/200901/msg00112.html
>
> To me, something is either guaranteed or not. And I think "enforce" means
> something that is guaranteed. In this case, the uniqueness is not
> guaranteed, therefore it is not enforced.

Set up slapo-accesslog on your master.  Then uniqueness is guaranteed.

--Quanah


--

Quanah Gibson-Mount
Principal Software Engineer
Zimbra, Inc
--------------------
Zimbra ::  the leader in open source messaging and collaboration

Comment 5 Gavin Henry 2009-01-29 11:15:18 UTC
----- quanah@zimbra.com wrote:

> --On January 28, 2009 10:39:41 PM +0000 Magne.Land@citrix.com wrote:
> 
> > Hi,
> > Please see this thread for background info:
> >
> http://www.openldap.org/lists/openldap-software/200901/msg00112.html
> >
> > To me, something is either guaranteed or not. And I think "enforce"
> means
> > something that is guaranteed. In this case, the uniqueness is not
> > guaranteed, therefore it is not enforced.
> 
> Set up slapo-accesslog on your master.  Then uniqueness is
> guaranteed.

We don't document this requirement in slapo-unique.5 though.

-- 
Kind Regards,

Gavin Henry.
Managing Director.

T +44 (0) 1224 279484
M +44 (0) 7930 323266
F +44 (0) 1224 824887
E ghenry@suretecsystems.com

Open Source. Open Solutions(tm).

http://www.suretecsystems.com/

Suretec Systems is a limited company registered in Scotland. Registered
number: SC258005. Registered office: 13 Whiteley Well Place, Inverurie,
Aberdeenshire, AB51 4FP.

Subject to disclaimer at http://www.suretecgroup.com/disclaimer.html

Comment 6 ando@openldap.org 2009-01-29 13:34:37 UTC
quanah@zimbra.com wrote:
> --On January 28, 2009 10:39:41 PM +0000 Magne.Land@citrix.com wrote:
> 
>> Hi,
>> Please see this thread for background info:
>> http://www.openldap.org/lists/openldap-software/200901/msg00112.html
>>
>> To me, something is either guaranteed or not. And I think "enforce" means
>> something that is guaranteed. In this case, the uniqueness is not
>> guaranteed, therefore it is not enforced.
> 
> Set up slapo-accesslog on your master.  Then uniqueness is guaranteed.

Are you sure about this?  I didn't look in detail to the code, so I 
can't tell whether serializing writes that way will cause the desired 
behavior, since slapo-unique is using internal writes.  As Gavin says,. 
if this is the case then it should be at least documented, and not only 
in slapo-unique, but also for any overlay/module that does internal writes.

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
Fax:     +39 0382 476497
Email:   ando@sys-net.it
-----------------------------------

Comment 7 Howard Chu 2009-01-29 14:03:20 UTC
ando@sys-net.it wrote:
> quanah@zimbra.com wrote:
>> --On January 28, 2009 10:39:41 PM +0000 Magne.Land@citrix.com wrote:
>>
>>> Hi,
>>> Please see this thread for background info:
>>> http://www.openldap.org/lists/openldap-software/200901/msg00112.html
>>>
>>> To me, something is either guaranteed or not. And I think "enforce" means
>>> something that is guaranteed. In this case, the uniqueness is not
>>> guaranteed, therefore it is not enforced.
>> Set up slapo-accesslog on your master.  Then uniqueness is guaranteed.
>
> Are you sure about this?  I didn't look in detail to the code, so I
> can't tell whether serializing writes that way will cause the desired
> behavior, since slapo-unique is using internal writes.

Huh? slapo-unique only does internal searches. The writes are all user ops, 
and accesslog will serialize all of them.

>  As Gavin says,.
> if this is the case then it should be at least documented, and not only
> in slapo-unique, but also for any overlay/module that does internal writes.

-- 
   -- Howard Chu
   CTO, Symas Corp.           http://www.symas.com
   Director, Highland Sun     http://highlandsun.com/hyc/
   Chief Architect, OpenLDAP  http://www.openldap.org/project/

Comment 8 Gavin Henry 2009-01-29 15:47:57 UTC
----- hyc@symas.com wrote:

> ando@sys-net.it wrote:
> > quanah@zimbra.com wrote:
> >> --On January 28, 2009 10:39:41 PM +0000 Magne.Land@citrix.com
> wrote:
> >>
> >>> Hi,
> >>> Please see this thread for background info:
> >>>
> http://www.openldap.org/lists/openldap-software/200901/msg00112.html
> >>>
> >>> To me, something is either guaranteed or not. And I think
> "enforce" means
> >>> something that is guaranteed. In this case, the uniqueness is not
> >>> guaranteed, therefore it is not enforced.
> >> Set up slapo-accesslog on your master.  Then uniqueness is
> guaranteed.
> >
> > Are you sure about this?  I didn't look in detail to the code, so I
> > can't tell whether serializing writes that way will cause the
> desired
> > behavior, since slapo-unique is using internal writes.
> 
> Huh? slapo-unique only does internal searches. The writes are all user
> ops, 
> and accesslog will serialize all of them.

So, where does this leave us? 

-- 
Kind Regards,

Gavin Henry.
Managing Director.

T +44 (0) 1224 279484
M +44 (0) 7930 323266
F +44 (0) 1224 824887
E ghenry@suretecsystems.com

Open Source. Open Solutions(tm).

http://www.suretecsystems.com/

Suretec Systems is a limited company registered in Scotland. Registered
number: SC258005. Registered office: 13 Whiteley Well Place, Inverurie,
Aberdeenshire, AB51 4FP.

Subject to disclaimer at http://www.suretecgroup.com/disclaimer.html

Comment 9 Quanah Gibson-Mount 2009-01-30 19:04:53 UTC
--On Thursday, January 29, 2009 3:48 PM +0000 ghenry@suretecsystems.com 
wrote:

>> Huh? slapo-unique only does internal searches. The writes are all user
>> ops,
>> and accesslog will serialize all of them.
>
> So, where does this leave us?

If you want guaranteed atomic writes, use slapo-accesslog on your master to 
serialize them.

--Quanah

--

Quanah Gibson-Mount
Principal Software Engineer
Zimbra, Inc
--------------------
Zimbra ::  the leader in open source messaging and collaboration

Comment 10 Gavin Henry 2009-01-30 19:08:45 UTC
Ok, so this should be in the man page. Where else should this be listed that affects other overlays?

------Original Message------
From: Quanah Gibson-Mount
Sender: 
To: Gavin Henry
To: openldap-its@openldap.org
Subject: Re: slapo-unique man page misleading (ITS#5908)
Sent: 30 Jan 2009 19:04

--On Thursday, January 29, 2009 3:48 PM +0000 ghenry@suretecsystems.com 
wrote:

>> Huh? slapo-unique only does internal searches. The writes are all user
>> ops,
>> and accesslog will serialize all of them.
>
> So, where does this leave us?

If you want guaranteed atomic writes, use slapo-accesslog on your master to 
serialize them.

--Quanah

--

Quanah Gibson-Mount
Principal Software Engineer
Zimbra, Inc
--------------------
Zimbra ::  the leader in open source messaging and collaboration


-- 
Kind Regards,

Gavin Henry.
Managing Director.

T +44 (0) 1224 279484
M +44 (0) 7930 323266
F +44 (0) 1224 824887
E ghenry@suretecsystems.com

Open Source. Open Solutions(tm).

http://www.suretecsystems.com/

Suretec Systems is a limited company registered in Scotland. Registered
number: SC258005. Registered office: 13 Whiteley Well Place, Inverurie,
Aberdeenshire, AB51 4FP.

Subject to disclaimer at http://www.suretecgroup.com/disclaimer.html

Comment 11 Quanah Gibson-Mount 2009-01-30 19:13:11 UTC
--On Friday, January 30, 2009 7:08 PM +0000 Gavin Henry 
<ghenry@suretecsystems.com> wrote:

> Ok, so this should be in the man page. Where else should this be listed
> that affects other overlays?

Eh, I'm not sure it should be in the man page.  The point is, if you ever 
want guaranteed atomic writes, you have to use slapo-accesslog to serialize 
them.  That's an issue that affects other LDAP servers as well.

AS Pierangelo said:


There is no guarantee of DSA-wide or even database-wide atomicity in write 
operations, including internal ones.  This was never even intended to be in 
place.  This is a known design limitation not only of slapo-unique, but 
also of slapd (and, I'd say, of LDAP itself).

--Quanah

--

Quanah Gibson-Mount
Principal Software Engineer
Zimbra, Inc
--------------------
Zimbra ::  the leader in open source messaging and collaboration

Comment 12 Gavin Henry 2009-01-30 19:19:50 UTC
Ok, but we should mention this somewhere like in the admin guide perhaps. 

------Original Message------
From: Quanah Gibson-Mount
Sender: 
To: Gavin Henry
To: openldap-its@openldap.org
Subject: Re: slapo-unique man page misleading (ITS#5908)
Sent: 30 Jan 2009 19:13

--On Friday, January 30, 2009 7:08 PM +0000 Gavin Henry 
<ghenry@suretecsystems.com> wrote:

> Ok, so this should be in the man page. Where else should this be listed
> that affects other overlays?

Eh, I'm not sure it should be in the man page.  The point is, if you ever 
want guaranteed atomic writes, you have to use slapo-accesslog to serialize 
them.  That's an issue that affects other LDAP servers as well.

AS Pierangelo said:


There is no guarantee of DSA-wide or even database-wide atomicity in write 
operations, including internal ones.  This was never even intended to be in 
place.  This is a known design limitation not only of slapo-unique, but 
also of slapd (and, I'd say, of LDAP itself).

--Quanah

--

Quanah Gibson-Mount
Principal Software Engineer
Zimbra, Inc
--------------------
Zimbra ::  the leader in open source messaging and collaboration


-- 
Kind Regards,

Gavin Henry.
Managing Director.

T +44 (0) 1224 279484
M +44 (0) 7930 323266
F +44 (0) 1224 824887
E ghenry@suretecsystems.com

Open Source. Open Solutions(tm).

http://www.suretecsystems.com/

Suretec Systems is a limited company registered in Scotland. Registered
number: SC258005. Registered office: 13 Whiteley Well Place, Inverurie,
Aberdeenshire, AB51 4FP.

Subject to disclaimer at http://www.suretecgroup.com/disclaimer.html

Comment 13 Gavin Henry 2009-02-09 17:10:05 UTC
> Ok, but we should mention this somewhere like in the admin guide perhaps. 
> 
> ------Original Message------
> From: Quanah Gibson-Mount
> Sender: 
> To: Gavin Henry
> To: openldap-its@openldap.org
> Subject: Re: slapo-unique man page misleading (ITS#5908)
> Sent: 30 Jan 2009 19:13
> 
> --On Friday, January 30, 2009 7:08 PM +0000 Gavin Henry 
> <ghenry@suretecsystems.com> wrote:
> 
>> Ok, so this should be in the man page. Where else should this be listed
>> that affects other overlays?
> 
> Eh, I'm not sure it should be in the man page.  The point is, if you ever 
> want guaranteed atomic writes, you have to use slapo-accesslog to serialize 
> them.  That's an issue that affects other LDAP servers as well.
> 
> AS Pierangelo said:
> 
> 
> There is no guarantee of DSA-wide or even database-wide atomicity in write 
> operations, including internal ones.  This was never even intended to be in 
> place.  This is a known design limitation not only of slapo-unique, but 
> also of slapd (and, I'd say, of LDAP itself).
> 

Should this be in the Admin Guide? I can't think of a place for it at the
moment. Should we suspend the ITS until there is a right place?

Thanks.
Comment 14 Quanah Gibson-Mount 2020-08-28 23:18:13 UTC
With Issue#9264 it is now possible to do full locking with slapo-unique if in single master, which resolves this issue.

With multi-provider, there can never be a fixed guarantee if two conflicting write operations come into two different providers at near the same time.  This sort of limitation with MPR is already well documented however.

*** This issue has been marked as a duplicate of issue 9264 ***