mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
config can be in /etc/default/ instead of /etc/sysconfig/
... on Debian system and derivated. (ctdb_diagnostics still hardcodes /etc/sysconfig/) (This used to be ctdb commit 1341329f6125d491b82c873f793af819e677f714)
This commit is contained in:
parent
91431262be
commit
4617a0e9cf
@ -22,7 +22,7 @@ ctdb status 2>/dev/null && {
|
||||
exit 0
|
||||
}
|
||||
|
||||
(cat /etc/sysconfig/ctdb | egrep "^CTDB_NATGW_PUBLIC_IP" | sed -e "s/.*=//" -e "s/\/.*//";cat "$CTDB_PUBLIC_ADDRESSES" | cut -d/ -f1) | while read _IP; do
|
||||
(cat /etc/{sysconfig,default}/ctdb | egrep "^CTDB_NATGW_PUBLIC_IP" | sed -e "s/.*=//" -e "s/\/.*//";cat "$CTDB_PUBLIC_ADDRESSES" | cut -d/ -f1) | while read _IP; do
|
||||
_IP_HELD=`/sbin/ip addr show | grep "inet $_IP/"`
|
||||
[ -z "$_IP_HELD" ] || {
|
||||
_IFACE=`echo $_IP_HELD | sed -e "s/.*\s//"`
|
||||
|
@ -83,7 +83,13 @@ sleep_for "${out#*= }"
|
||||
|
||||
if try_command_on_node any "test -r /etc/ctdb/events.d/61.nfstickle" ; then
|
||||
echo "Trying to determine NFS_TICKLE_SHARED_DIRECTORY..."
|
||||
if [ -f /etc/sysconfig/nfs ]; then
|
||||
f="/etc/sysconfig/nfs"
|
||||
elif [ -f /etc/default/nfs ]; then
|
||||
f="/etc/default/nfs"
|
||||
elif [ -f /etc/ctdb/sysconfig/nfs ]; then
|
||||
f="/etc/ctdb/sysconfig/nfs"
|
||||
fi
|
||||
try_command_on_node -v any "[ -r $f ] && sed -n -e s@^NFS_TICKLE_SHARED_DIRECTORY=@@p $f" || true
|
||||
|
||||
nfs_tickle_shared_directory="${out:-/gpfs/.ctdb/nfs-tickles}"
|
||||
|
@ -460,7 +460,13 @@ rpc_set_service_failure_response ()
|
||||
# the flexibility to set the number of failures.
|
||||
_numfails="${2:-${iteration}}"
|
||||
|
||||
if [ -f /etc/sysconfig/nfs ]; then
|
||||
_c="${CTDB_ETCDIR}/sysconfig/nfs"
|
||||
elif [ -f /etc/default/nfs ]; then
|
||||
_c="${CTDB_ETCDIR}/default/nfs"
|
||||
elif [ -f /etc/ctdb/sysconfig/nfs ]; then
|
||||
_c="${CTDB_ETCDIR}/ctdb/sysconfig/nfs"
|
||||
fi
|
||||
if [ -r "$_c" ] ; then
|
||||
. "$_c"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user