[Fedora-directory-users] How can you monitor replication?

Ivan Ferreira iferreir at personal.com.py
Thu Sep 27 15:32:53 UTC 2007


I use a script like this:


#! /bin/bash
# Script para verificar el estado de la replicacion del directorio
# Ivan Ferreira - Enero 2007

MAILTO=iferreir at domain.com.py
STATUSFILE=/var/log/DSLastUpdateStatus.log

ldapsearch -x -D "uid=replmon,ou=Special
Users,dc=sis,dc=personal,dc=net,dc=py" \
  -b 'cn=replica,cn="dc=sis,dc=personal,dc=net,dc=py",cn=mapping
tree,cn=config' \
  -w <password> objectClass=nsDS5ReplicationAgreement \
  nsds5replicaLastUpdateStatus nsds5replicaLastUpdateStart | grep -E \
  "^nsds5replicaLastUpdateStatus|^nsds5replicaLastUpdateStart" >
$STATUSFILE 2>&1

STATUS=`grep "^nsds5replicaLastUpdateStatus" $STATUSFILE |awk '{ print $2
}'`
DETAIL=`grep "^nsds5replicaLastUpdateStatus" $STATUSFILE | awk '{ for (i=3;
i<=NF; i++) printf "%s ", $i }'`
if [ $STATUS -ne 0 ]
then
 echo "ALERT!! Directory replication failed with status: $DETAIL" | mail \
  -s "Directory replication failed" $MAILTO
fi
# echo $STATUS $DETAIL






                                                                           
                                                                           
                                                                           
                                                                      Para 
                                          "General discussion list for the 
                                          Fedora Directory server          
       "Ian Meyer"                        project."                        
       <ianmmeyer at gmail.com>              <fedora-directory-users at redhat.c 
       Enviado por:                       om>                              
       fedora-directory-users-b                                         cc 
       ounces at redhat.com                                                   
                                                                    Asunto 
       27/09/2007 11:28 a.m.              [Fedora-directory-users] How can 
                                          you monitor replication?         
                                                             Clasificación 
                                         Uso Interno                       
        Por favor, responda a                                              
       "General discussion list                                            
       for the Fedora Directory                                            
           server project."                                                
       <fedora-directory-users@                                            
             redhat.com>                                                   
                                                                           
                                                                           




Hello,

We have a decent sized env. (1 master, 16 slaves in different
datacenters across the world) and we're trying to find a way to
effectively monitor the status of replication. When was the last
update? How many changes were made? How long did it take from start to
finish? I know you can get most of this information from the gui, but
we need to tie it in to our monitoring application. Is this
information stored in a db anywhere? In ldap itself? Any insight would
be appreciated.

Thanks in advance!
- Ian

--
Fedora-directory-users mailing list
Fedora-directory-users at redhat.com
https://www.redhat.com/mailman/listinfo/fedora-directory-users


========================================================================================
AVISO LEGAL: Esta información es privada y confidencial y está dirigida
únicamente a su destinatario. Si usted no es el destinatario original de
este mensaje y por este medio pudo  acceder a dicha información por favor
elimine el mensaje. La distribución o copia de este mensaje está
estrictamente prohibida. Esta comunicación es sólo para  propósitos de
información y no debe ser considerada como propuesta, aceptación ni como
una declaración de voluntad oficial de NUCLEO S.A.  La transmisión de
e-mails no garantiza que el correo electrónico sea seguro o libre de error.
Por consiguiente, no manifestamos que esta información sea completa o
precisa.  Toda información está sujeta a alterarse sin previo aviso.

 This information is private and confidential and intended for the
recipient only. If you are not the intended recipient of this message you
are hereby notified that any review,  dissemination, distribution or
copying of this message is strictly prohibited. This communication is for
information purposes only and shall not be regarded neither as a proposal,
acceptance nor as a statement of will or official statement from NUCLEO
S.A. . Email transmission cannot be guaranteed to be secure or error-free.
Therefore,  we do not represent that this information is complete or
accurate and it should not be relied upon as such. All information is
subject to change without notice.




More information about the Fedora-directory-users mailing list