Amanda-Users

Re: size estimate puts very high load on my LDAP server

2007-11-23 04:21:31
Subject: Re: size estimate puts very high load on my LDAP server
From: Cyrille Bollu <Cyrille.Bollu AT fedasil DOT be>
To: Francis Galiegue <fg AT one2team DOT com>
Date: Fri, 23 Nov 2007 10:15:17 +0100

owner-amanda-users AT amanda DOT org a écrit sur 22/11/2007 20:44:34 :

> Le Thursday 22 November 2007 17:53:08 Cyrille Bollu, vous avez écrit :
> > Hi all,
> >
> > is there something to do to prevent "tar" to lookup for username when it's
> > estimating the size of the DLE's (like when you do "ls -ln" instead of "ls
> > -l")?
> >
> > It seems that this process puts a very high load on my LDAP server... Such
> > a high load that I'm planing to install a new LDAP slave only for the
> > backup
> >
> > Any clue?
> >
>
> Could be... But the problem is, it won't be synchronized in real time AND it
> requires that you have shadow passwords!
>
> You could put in a cron, at regular enough intervals, these two commands:
>
> getent passwd >/etc/passwd
> getent group >/etc/group
>
> But of course DO A BACKUP OF /etc/passwd FIRST.
>
> This based on the premise that you use nsswitch.conf and that your passwd and
> group entries read both "files ldap".


That's a good idea. However, I prefer to install a new server (that I would remove when I'll be able to install an openldap slave on my backup server (I've compatibility problems. Those who are using openldap slaves will probably understand what I'm talking about :-).)

>
> However, the fact that it puts a high load on the LDAP server means
> one of two
> things (sorry,veering off topic here):
>
> 1. you have a s*load of files;

I have around 2.000.000 files

> 2. your LDAP database is not indexed correctly.

I think the problem is more that it is a very old version of openldap (2.0) that's still using ldbm databases...

Can you see something missing in my indexes though?

index   objectClass,uid,uidNumber,gidNumber,memberUid   eq
index   cn,mail,surname,givenname                           eq,subinitial

>
> You should try and investigate on the LDAP front as well.
>
> --
> Francis Galiegue, fg AT one2team DOT com - Ingénieur système
> [ATTENTION : CHANGEMENT DE COORDONNÉES !]
> One2team - 42 Av. Raymond Poincaré - 75116 PARIS CEDEX
> +33683877875, +33178945552
>