[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Corrupt LDAP DB ... ans 2.3.11 syncrepl



Sorry :) Here it is:

This is the slave config, the master does not change and works OK with type=refreshOnly

There is a comment line:

#type=refreshAndPersist

the type line is the only line I changed. When type=refrechOnly the slave connects to the master and
copues the entire directory over (after I deleted it). When I use refreshAndPersist the slave connects and
copies nothing. If I use refreshOnly to copy the inital tree and then change to refreshAndPersist not even
the delta of the initial and the changes are propagated.


I have about 50k entries on the directory and the following DB_CONFIG:

set_cachesize 0 104857600 0
set_lg_bsize 2097512
set_lg_dir /var/tmp/bdb-log
set_flags DB_LOG_AUTOREMOVE

This seems to store the entire directory in memory, there are no changes to the files in the database directory
when the slave is filling up. I assume this is because the entries are being held in memory? Will they ever
get written to disk?


Here is slapd.conf on the slave:

#slapd.conf
include         /usr/local/etc/openldap/schema/core.schema
include         /usr/local/etc/openldap/schema/cosine.schema
include         /usr/local/etc/openldap/schema/nis.schema
include         /usr/local/etc/openldap/schema/inetorgperson.schema
include         /usr/local/etc/openldap/schema/qmail.schema
include         /usr/local/etc/openldap/schema/openldap.schema

pidfile         /usr/local/var/run/slapd.pid
argsfile        /usr/local/var/run/slapd.args

threads 10
loglevel 5
conn_max_pending 100

# BDB database
database        bdb
suffix          "dc=ukbboss,dc=co,dc=uk"
rootdn          "cn=Manager,dc=ukbboss,dc=co,dc=uk"
rootpw  cheesypoofs
directory       /database/openldap/openldap-data
index   objectClass     eq
index mailMessageStore sub,eq,pres
index mailServices sub,eq,pres
index mailUsername sub,eq,pres
index mail sub,eq,pres
index cn,uid eq
index uidNumber eq
index gidNumber eq
index entryCSN eq
index entryUUID eq

sizelimit unlimited
cachesize 100000
dbcachesize 5000000
syncrepl rid=123
provider=ldap://10.100.100.30:389
type=refreshOnly
interval=00:00:00:20
searchbase="dc=ukbboss,dc=co,dc=uk"
filter="(objectClass=qmailUser)"
scope=sub attrs="sn,cn,mailDomain,mailUsername,mail,mailMessageStore,qmailUID,mailServices,accountStatus,mailQuotaSize,userPassword,Tie
schemachecking=off
bindmethod=simple
binddn="cn=Manager,dc=ukbboss,dc=co,dc=uk"
credentials=cheese
#type=refreshAndPersist


# We are a slave, updates get sent to the master
updateref ldap://10.100.100.30
database monitor


--
Leigh Porter


Buchan Milne wrote:

On Tuesday 01 November 2005 12:52, Leigh Porter wrote:


Hiya all,

I tried refreshAndPersist and replication died - did I do something
stoopid?





Can't tell if you don't give the *real* config you used when testing it. Based on what you have below I would assume a bad configuration was the problem, but depending on what the differences are to what you really tested, it may be something else ...




syncrepl rid=123
       provider=ldap://10.100.100.30:389
       type=refreshOnly
       interval=00:00:00:20
       searchbase="dc=ukbboss,dc=co,dc=uk"
       filter="(objectClass=qmailUser)"
       scope=sub
attrs="sn,cn,mailDomain,mailUsername,mail,mailMessageStore,qmailUID,mailSer
vices,accountStatus,mailQuotaSize,userPassword,Tier-Of-service,Roaming-Indic
ation,PrimaryUser,Additional-PDP-Contexts-Allowed,User-Trace-Indicator"
schemachecking=off
       bindmethod=simple
       binddn="cn=Manager,dc=ukbboss,dc=co,dc=uk"
       credentials=cheese


#type=refreshAndPersist
#