dns issues on ubuntu

This commit is contained in:
Serghey Rodin 2013-10-08 08:44:13 +03:00
parent de68a6bc8f
commit 73be3c7543
2 changed files with 9 additions and 2 deletions

@ -54,7 +54,7 @@ if [ -e '/etc/named.conf' ]; then
fi
if [ -e '/etc/bind/named.conf' ]; then
dns_conf='/etc/bin/named.conf'
dns_conf='/etc/bind/named.conf'
fi
# Remove old user's zone

@ -372,9 +372,16 @@ rebuild_dns_domain_conf() {
# Updating zone
update_domain_zone
# Set permissions
if [ "$DNS_SYSTEM" = 'named' ]; then
dns_group='named'
else
dns_group='bind'
fi
# Set file permissions
chmod 640 $HOMEDIR/$user/conf/dns/$domain.db
chown root:named $HOMEDIR/$user/conf/dns/$domain.db
chown root:$dns_group $HOMEDIR/$user/conf/dns/$domain.db
# Get dns config path
if [ -e '/etc/named.conf' ]; then