Commit ed86f6a3 authored by Benoît's avatar Benoît
Browse files

Fixed fulldir variable + showing which host has connectivty issue

parent 9268859d
......@@ -8,7 +8,7 @@ psa_db="psa"
psa_sql="select name from dns_zone where status=0 and type='master'"
script_name=$(basename "$0")
export "$(grep -v ^# /etc/sysconfig/named | grep ROOTDIR | xargs)"
temp=$(grep directory /etc/named.conf | awk '{print $2}') ; temp=${temp//\"/} ; named_dir=${temp//\;/}
temp=$(grep directory /etc/named.conf | head -n1 | awk '{print $2}') ; temp=${temp//\"/} ; named_dir=${temp//\;/}
fulldir=$ROOTDIR$named_dir
if [ "$1" == "-h" ]||[ "$1" == "--help" ]; then
......@@ -125,7 +125,7 @@ for i in $var; do
echo -e "\\nVérification des zones sur le serveur $host (DirectAdmin)\\n"
ssh root@"$host" 'cat /etc/virtual/domainowners | cut -d ":" -f 1' > "/opt/dns1zones.txt"
else
echo "Error : Your server does not seem to run Plesk or DirectAdmin, or there is a connectivity issue."
echo "Error : Your server $host does not seem to run Plesk or DirectAdmin, or there is a connectivity issue."
echo "Please check that you can access this server through SSH or SQL."
exit
fi
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment