Escravo do servidor de nomes Bind9 com problemas de transferência de arquivos mestre

Escravo do servidor de nomes Bind9 com problemas de transferência de arquivos mestre

Tenho um servidor de nomes mestre configurado e agora estou tentando configurar o escravo. O Bind9 parece carregar e funcionar bem, mas estou recebendo o seguinte erro:

Apr 27 12:47:21 ns2 named[23563]: dumping master file: slaves/tmp-oJ5LJ1RtO4: open: file not found

Aqui está meu arquivo nomeado.conf.options:

options {

recursion yes;
allow-recursion { trusted; };
listen-on { 10.0.1.11; }; //this machines IP. 
allow-transfer { none; };

// If there is a firewall between you and nameservers you want
// to talk to, you may need to fix the firewall to allow multiple
// ports to talk.  See http://www.kb.cert.org/vuls/id/800113

// If your ISP provided one or more IP addresses for stable 
// nameservers, you probably want to use them as forwarders.  
// Uncomment the following block, and insert the addresses replacing 
// the all-0's placeholder.

forwarders {
    10.0.1.12;
    x.x.x.x; //keeping my ISPs nameservers private for post in askUbunutu
    x.x.x.x; //
};

//========================================================================
// If BIND logs error messages about the root key being expired,
// you will need to update your keys.  See https://www.isc.org/bind-keys
//========================================================================
dnssec-validation auto;

auth-nxdomain no;    # conform to RFC1035
listen-on-v6 { any; };

};

Escravos nomeados arquivo.conf.local:

//
// Do any local configuration here
//

// Consider adding the 1918 zones here, if they are not used in your
// organization
//include "/etc/bind/zones.rfc1918";
zone "mycity.example.com" {
type slave;
file "slaves/db.mycity.example.com";
masters { 10.0.1.12; };
};

zone "1.0.10.in-addr.arpa" {
    type slave;
    file "slaves/db.10";
    masters { 10.0.1.12; };
};

Permissões de diretório para /etc/bind/slaves

drwxr-sr-x   2 bind bind  4096 Apr 27 09:41 slaves

Alguma ideia do que estou fazendo de errado?

Responder1

A diretiva file é relativa ao diretório bind var no Ubuntu cujo padrão é o seguinte:

/var/cache/bind

A menos que seja alterado usando a diretiva de diretório nas opções, portanto, ele está procurando o seguinte diretório para salvar os dados:

/var/cache/bind/escravos

Observe que este é provavelmente um local melhor, de qualquer maneira, na verdade, não é ideal dar acesso de gravação de bind ao seu próprio diretório /etc, pois isso permite que alguém altere potencialmente sua configuração de bind se de alguma forma explorar o bind de forma mais segura para manter os dados variáveis ​​em outro lugar e deixar o servidor escreva aí.

informação relacionada