[Samba] Floating IP breaks AD replication
Sven Wick
sven.wick at gmx.de
Mon Nov 23 16:50:31 UTC 2020
> we point them to somedom.contoso.com which is then
> resolved to both and the client can pick
I want to avoid Round-Robin DNS
> You cannot use CTDB with AD DCs
You can.
/etc/ctdb/nodes
192.168.30.11
192.168.30.12
/etc/ctdb/public_addresses
192.168.30.10/24 ens18
/etc/ctdb/events/legacy/20.samba-ad.script
#!/usr/bin/env bash
function monitor_ldap() {
ldbsearch -H ldap://127.0.0.1 -s base -b "" vendorName 2>/dev/null | grep -qi samba
if [[ $? -eq 0 ]]; then
return 0
else
echo "ldbsearch received no info"
return 1
fi
}
case "$1" in
monitor)
monitor_ldap || exit 1
;;
esac
exit 0
I used to use keepalived for this kind of setups
but ctdb is a neat solution so I switched.
When I change
/etc/ctdb/public_addresses
from 192.168.30.10/24 ens18
to 192.168.60.10/24 ens18
the replication does not break
because x.x.60.0 is not the internal DNS Zone
This setup allows me to upgrade, reboot
each DC without downtime because
ctdb checks for samba and moves the floating IP.
More information about the samba
mailing list