[Samba] Device ends up with multiple dns records and IP addresses

Rowland Penny rpenny at samba.org
Thu Nov 11 14:06:28 UTC 2021


On Thu, 2021-11-11 at 13:53 +0000, Sebastian Arcus via samba wrote:
> > > > > 
> 
> Thank you for the suggestion. I've already tried 0.9.3 yesterday. It 
> does look like the code is a bit more robust - but the basic issue
> still 
> exists. If somehow the dns back-end ends up with an A record with 
> multiple IP addresses, or a PTR record with multiple hostnames (or 
> both), the "samba-tool dns query" command returns multiple lines and
> the 
> script is unable to delete the existing records - as it passes a 
> multi-line argument to "samba-tool dns delete ..." command - which 
> fails. So it just keeps on adding more IPs and/or hostnames to the 
> existing records anyway, without deleting existing ones.
> 
> Would it be safer for the script to at least detect the presence of 
> multi IP / multi host records, and maybe abort trying to add the 
> IP/hostname to the DNS back-end - and exit with an error? Or simply
> exit 
> if the "samba-tool dns delete ..." command returns an error? Or
> maybe 
> delete one by one all the IP addresses for the respective A record,
> and 
> all the hostnames for the PTR record - and then create the new A /
> PTR 
> record?

Anything is possible, (well nearly anything), let me have look at this
and see if I can come up with something.

Rowland





More information about the samba mailing list