Hope someone could help me with my issue )
So, I have several VHost which managed by puppet, including DNS (unbound). One vhost was deleted some time ago and and recreated recently with new IP address (I can't use old IP :( ). But, when puppet running on dns server I got next error:
Nov 17 15:30:19 dns puppet-agent[39154]: Could not retrieve catalog
from remote server: Error 400 on SERVER: Duplicate declaration:
Unbound::Record[host.example.com] is already declared in file
puppetdb_entry.pp:13; cannot redeclare at puppetdb_entry.pp:13
on node dns.example.com
Here is content of puppetdb_entry.pp:
define component::unbound::puppetdb_entry (
$hostname,
$ipaddress_eth0,
$fqdn = $name
) {
$desired_fqdn =
"${hostname}.${component::unbound::puppetdb_hosts::mock_domain}"
unbound::record { $desired_fqdn:
type => 'A',
content => $ipaddress_eth0,
ttl => 380
}
}
I've read related topics on serverfault but most of them has declaring parameters twice but I'm not (at least I can't see where I declare twice).
So I hope you guys could help me understand where I'm wrong.
Thanks in advance!