OK
I understand if the -r switch (to slurpd, not slapd) redirects the output to a file for debugging purposes, this is just not apparent in the man pages. The man pages to not tell me that slurpd will be "redirecting" with the -r switch.
It is just usual replication I was setting up originally.
This is the variable I was using in an "openldaprc" file:
# -r replication-log-file. Directory must be created.
#SLURPD_REPL_LOG_FILE=/var/openldap-slurp/log
When uncommenting this line, the result is that it does not open network connections to the replication slaves. _All_ data goes to the file, none to the slaves. This isn't documented correctly, it took me a long time to figure out why the replication was not happening.
Chris
-----Original Message-----
From: Pierangelo Masarati [mailto:ando@sys-net.it]
Sent: Sun, March 11, 2007 11:52 PM
To: Eubank, Chris LCS:EX
Cc: openldap-its(a)openldap.org
Subject: Re: (ITS#4864) -r option "redirects" to logfile, breaks replication
[please keep the ITS in CC]
Eubank, Chris LCS:EX wrote:
> Am running Solaris 10, and the version I stuck in the log.
>
> When I created an "openldaprc" and used the variable for the
> replication log,
What is the "variable for the replication log"? All one usually needs to do is define a replogfile in slapd.conf(5)
> (which ends up obviously running the slurpd daemon with the -r
> switch),
Again: there's no need to use -r if replogfile is in slapd.conf(5); if there is no replogfile in slapd.conf(5), slapd(8) will not generate any log, so slurpd(8) will have nothing to do
> it sent the replication data to the logfile and not to the replication
> hosts being specified.
Who sent the replication data to the logfile? slapd(8) is supposed to write replication data to the file specified in replogfile (sladp.conf(5)); slurpd(8) is supposed to read that file (whose existence and location is known by parsing slapd.conf(5)), copy the content it is able to process to its own replication log, which resides in slurpd's working directory (default or passed with -t) and is called slurpd.replog, send that content to the slaves, and remove the data that has been handled from slapd's replication log.
This is how things are expected to work. As you may see, -r never comes into play; it's intended to be used to force slurpd processing of a different file, which may be required for special purposes. Do you have any special needs, or are you simply trying to set up usual replication?
> Does that make more sense?
See comments above.
p.
Ing. Pierangelo Masarati
OpenLDAP Core Team
SysNet s.n.c.
Via Dossi, 8 - 27100 Pavia - ITALIA
http://www.sys-net.it
------------------------------------------
Office: +39.02.23998309
Mobile: +39.333.4963172
Email: pierangelo.masarati(a)sys-net.it
------------------------------------------
Le Lun 12 mars 2007 06:37, Pierangelo Masarati a écrit :
> I don't see so much similarity: set_chase() is intended to use the
> gatherer to fetch objects and extract a value from them, including
> "closure" (recursion). Sublevel does not require fetching, and takes a
> negative digit as extra argument, rather than an attribute type, so
> you'd need to add an outer test before calling set_chase() anyway,
> extend the interface of set_chase() to allow an AttributeDescription and
> an integer, and so on, while you don't need any callback capability to
> fetch an object or expand values or so. I'd keep it simple as it is now.
OK. You'll find a new version here:
ftp://ftp.openldap.org/incoming/raphael-ouazana-070313.patch
It takes care of your notices.
Regards,
Raphael Ouazana.
>----- Original Message ----
>From: Pierangelo Masarati <ando(a)sys-net.it>
>To: vargok(a)yahoo.com
>Cc: openldap-its(a)openldap.org
>Sent: Monday, March 12, 2007 4:52:04 PM
>Subject: Re: (ITS#4868) Binary Attribute Patch(es)
>
>
>> These address the use of Binary-valued attributes (#3113, #3386):
>>
>> For example, inetOrgPerson.userCertificate is usually transferred with the
>> ";binary" directive. ";binary" is not handled by OpenLDAP/Back-SQL.
>
>Well, the solution you propose is not correct, since you are altering
>schema data, which is supposed to be read-only. In any case, the point is:
Yeah; I think the actual submission found the ";binary" and reset the
reference to it, not actually doing anything to it.
>- if we decide that back-sql should ignore tags, then the solution
>consists in using the canonical name of the underlying AttributeType
>when looking up data;
>
>- however, this would destroy the possibility to use different storages
>for differently encoded data; for example, a column for "cn;lang-en" and
>a column for "cn;lang-jp". I don't know how many users would prefer one
>solution over another, but in any case either we find a solution that
>preserves both capabilities or we choose one. I'd vote in favor of
>ignoring ";binary" since it's obsolete and related to transport only,
>but in favor of honoring language tags.
Sounds great to me. I just want support for ";binary" both on storage and
retrieval to be supported. I'll accept that it's obsolete -- I'll also put
forth that a lot of things still use it (e.g. Lotus Domino v6).
>> There remains an issue with selecting attributes using, e.g.,
>> "userCertificate;binary" -- nothing is returned. Someone with a better
>> understanding of the attribute-processing method would be much more effective in
>> terms of finding the correct place to remove the ";binary" from the
>> "attribute-name." (i.e. "userCertificate;binary" is NOT the attribute-name;
>> "userCertificate" is the attribute-name, ";binary" is a transport directive (see
>> #3113).
>
>In fact, "userCertificate;binary" is the attribute description. The
>attribute name is in ad_type->sat_cname.
And, in fact, none of what I did appears to have been sufficient. I'm
still looking at why selecting "userCertificate;binary" as part of an ldapsearch attribute-list doesn't pull the data. "userCertificate" does. The issue appears
to be related to the ad_inlist verification on the search-supplied attribute --
"userCertificate;binary" doesn't resolve.
If you know where I can look to figure this out, that would help. I've been
through some areas and not found exactly where just yet.
Thanks for your assistance.
Kevin Vargo
____________________________________________________________________________________
The fish are biting.
Get more visitors on your site using Yahoo! Search Marketing.
http://searchmarketing.yahoo.com/arp/sponsoredsearch_v2.php
dieter(a)dkluenter.de wrote:
> Howard Chu <hyc(a)symas.com> writes:
>
>> What is the original rootdn?
>>
> cn=admin,o=avci,c=de
>
> -Dieter
>
I don't see anything like that here. You'll probably have to post your
slapd.conf. Have you checked for extraneous white space in the original
rootdn config?
--
-- Howard Chu
Chief Architect, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc
Chief Architect, OpenLDAP http://www.openldap.org/project/
Howard Chu <hyc(a)symas.com> writes:
> What is the original rootdn?
>
cn=admin,o=avci,c=de
-Dieter
--
Dieter Klünter | Systemberatung
http://www.dkluenter.de
GPG Key ID:8EF7B6C6
Full_Name: Carsten Agger
Version: 2.3.20
OS: OSE
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (194.237.142.21)
On our architecture (OSE running on an AXE processor), time_t is an unsigned
int.
This means that this code, as found in the wait4msg function in
libraries/libldap/result.c, will break:
>
> if ( rc == LDAP_MSG_X_KEEP_LOOKING && tvp != NULL ) {
> tmp_time = time( NULL );
> tv0.tv_sec -= ( tmp_time - start_time );
> if ( tv0.tv_sec <= 0 ) {
> rc = 0; /* timed out */
> ld->ld_errno = LDAP_TIMEOUT;
> break;
> }
> tv.tv_sec = tv0.tv_sec;
> ...
> }
Why? Because if (start_time > tmp_time), the condition
( tv0.tv_sec <= 0 ) will never evaluate to TRUE, and the break will
never be executed - yielding an infinite loop.
Solution: rewrite in a portable way, e.g. (as suggested by Pierangelo Masarati
on
the bugs mailing list) by testing if the
value of tv_sec would be negative after subtracting ( tmp_time -
start_time ) before assigning it.
We have found a bug in libraries/libldap/result.c which may cause an
infinite loop in some situations.
The error is this, in the function wait4msg():
if ( rc == LDAP_MSG_X_KEEP_LOOKING && tvp != NULL ) {
tmp_time = time( NULL );
tv0.tv_sec -= ( tmp_time - start_time );
if ( tv0.tv_sec <= 0 ) {
rc = 0; /* timed out */
ld->ld_errno = LDAP_TIMEOUT;
break;
}
tv.tv_sec = tv0.tv_sec;
...
}
The problem is this: The check ( tv0.tv_sec <= 0 ) is always true, since tv_sec (on our
system, at least) is an unsigned int.
The problem is fixed by casting it to int:
if ( (int) tv0.tv_sec <= 0 ) {
...
}
however this might not be the most suitable way to fix it.
best regards,
Carsten Agger
Software Consultant,
TietoEnator A/S, Denmark
http://www.tietoenator.dk
Full_Name: Quanah Gibson-Mount
Version: 2.3/2.4/HEAD
OS: NA
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (171.66.155.86)
The slapd.conf(5) man page talks about the various ways in which indices can be
tuned, such as index_substr_if_maxlen, but it does not actually mention the
index directive. It may be worthwhile to have text like
[b]index[/b] See the man page for the specific backend you are using for more
information about the index directive {ex: slapd-bdb(5)}
so that users can more easily find that information (and the necessity to run
slapindex on bdb, for example)
etc.
vargok(a)yahoo.com wrote:
> These address the use of Binary-valued attributes (#3113, #3386):
The proposed patches have been applied (with changes) to HEAD code (you
should be able to easily generate the diffs between HEAD and re23 code);
please test. In detail, please check the solution for the ";binary"
issue. If you report the behavior as satisfactory, backporting to re23
could be an option, since the fix should be well isolated, and it
configures as borderline between new feature and bug fix.
p.
Ing. Pierangelo Masarati
OpenLDAP Core Team
SysNet s.n.c.
Via Dossi, 8 - 27100 Pavia - ITALIA
http://www.sys-net.it
------------------------------------------
Office: +39.02.23998309
Mobile: +39.333.4963172
Email: pierangelo.masarati(a)sys-net.it
------------------------------------------