[SCM] CTDB repository - branch master updated - ctdb-1.0.72-14-g9ce84a7

Ronnie Sahlberg sahlberg at samba.org
Tue Mar 10 02:48:25 GMT 2009


The branch, master has been updated
       via  9ce84a7915abaa987160ecbcae63128a9ed0a741 (commit)
      from  ecf26af22245d0f55aded50e8768b0c21495f98c (commit)

http://gitweb.samba.org/?p=sahlberg/ctdb.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 9ce84a7915abaa987160ecbcae63128a9ed0a741
Author: root <root at rcn1.VSOFS1.COM>
Date:   Sat Mar 10 13:45:38 2007 +1100

    check the static-routes file   if it exists

-----------------------------------------------------------------------

Summary of changes:
 tools/ctdb_diagnostics |   30 +++++++++++++++++++++++++++---
 1 files changed, 27 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/tools/ctdb_diagnostics b/tools/ctdb_diagnostics
index 8304a68..df5a799 100755
--- a/tools/ctdb_diagnostics
+++ b/tools/ctdb_diagnostics
@@ -4,7 +4,13 @@
 
 PATH="$PATH:/sbin:/usr/sbin:/usr/lpp/mmfs/bin"
 
-CONFIG_FILES="/etc/krb5.conf /etc/hosts /etc/ctdb/nodes /etc/sysconfig/ctdb /etc/ctdb/public_addresses /etc/resolv.conf /etc/nsswitch.conf /etc/sysctl.conf /etc/samba/smb.conf /etc/fstab /etc/multipath.conf /etc/pam.d/system-auth /etc/sysconfig/nfs /etc/exports /etc/vsftpd/vsftpd.conf"
+# list of config files that must exist and that we check are the same 
+# on all nodes
+CONFIG_FILES_MUST="/etc/krb5.conf /etc/hosts /etc/ctdb/nodes /etc/sysconfig/ctdb /etc/resolv.conf /etc/nsswitch.conf /etc/sysctl.conf /etc/samba/smb.conf /etc/fstab /etc/multipath.conf /etc/pam.d/system-auth /etc/sysconfig/nfs /etc/exports /etc/vsftpd/vsftpd.conf"
+
+# list of config files that may exist and should be checked that they
+# are the same on all nodes
+CONFIG_FILES_MAY="/etc/ctdb/public_addresses /etc/ctdb/static-routes"
 
 2>&1
 
@@ -54,9 +60,27 @@ cat <<EOF
 Comping critical config files on all nodes
 EOF
 
-for f in $CONFIG_FILES; do
+for f in $CONFIG_FILES_MUST; do
+ [ -r "$f" ] || {
+    error "$f is missing on this node"
+    continue;
+ }
+ show_file $f
+ for i in `seq 0 $MAX_NODE`; do
+     echo "Testing for same config file $f on node $i"
+     tmpf=/tmp/`basename $f`.node$i
+     onnode $i cat $f > $tmpf 2>&1
+     cmp $f $tmpf 2>&1 || {
+	 error "File $f is different on node $i"
+	 diff -u $f $tmpf
+     }
+     rm -f $tmpf
+ done
+done
+
+for f in $CONFIG_FILES_MAY; do
  [ -r "$f" ] || {
-    error "$f is missing"
+    echo "Optional file $f is not present on local node"
     continue;
  }
  show_file $f


-- 
CTDB repository


More information about the samba-cvs mailing list