[Pdns-users] powerdns frequently crashes and restarts
klaus.darilion at nic.at
Fri Feb 18 09:28:52 UTC 2022
So, when a zone gets updated, PowerDNS checks if it has to notify slaves and send NOTIFYs to the slaves. Once this is done, it updates the notified_serial in the domains table. This UPDATE, for whatever reason, causes a deadlock.
Maybe you can work around that problem. You mentioned that you use DB replication. So, if all the slaves get their zones via DB replication and NOT via NOTIFY/AXFR, then you can disable the NOTIFYs and "UPDATE notified_serial...." query by setting master=no in pdns.conf.
So, if Powerdns need not send NOTIFYs, then set master=no.
Von: Pdns-users <pdns-users-bounces at mailman.powerdns.com> Im Auftrag von Klaus Darilion via Pdns-users
Gesendet: Freitag, 18. Februar 2022 09:58
An: Riccardo Brunetti <riccardo.brunetti at host.it>; Pdns-users at mailman.powerdns.com
Betreff: Re: [Pdns-users] powerdns frequently crashes and restarts
Look in the mysql-server log. Maybe it mentions which other transaction causes the deadlock. That my help to find the cause.
Is this problem something new? I.e. started it after a PDNs or Mysql Upgrade?
Von: Pdns-users <pdns-users-bounces at mailman.powerdns.com<mailto:pdns-users-bounces at mailman.powerdns.com>> Im Auftrag von Riccardo Brunetti via Pdns-users
Gesendet: Freitag, 18. Februar 2022 09:55
An: pdns-users at mailman.powerdns.com<mailto:pdns-users at mailman.powerdns.com>
Betreff: [Pdns-users] powerdns frequently crashes and restarts
We are having quite frequent crashes of our pdns server with the following syslog messages:
Feb 17 13:39:33 xxxx.xxxxx.xxx.xxxx pdns_server: Exiting because communicator thread died with error: GSQLBackend unable to refresh domain_id XXXXX: Could not execute mysql statement: update domains set notified_serial=? where id=?: Deadlock found when trying to get lock; try restarting transaction
Feb 17 13:39:34 xxxx.xxxxx.xxx.xxxx systemd: pdns.service: main process exited, code=exited, status=1/FAILURE
Feb 17 13:39:34 xxxx.xxxxx.xxx.xxxx systemd: Unit pdns.service entered failed state.
Feb 17 13:39:34 xxxx.xxxxx.xxx.xxxx systemd: pdns.service failed.
Feb 17 13:39:35 xxxx.xxxxx.xxx.xxxx systemd: pdns.service holdoff time over, scheduling restart.
Feb 17 13:39:35 xxxx.xxxxx.xxx.xxxx systemd: Stopped PowerDNS Authoritative Server.
Feb 17 13:39:35 xxxx.xxxxx.xxx.xxxx systemd: Starting PowerDNS Authoritative Server...
Feb 17 13:39:35 xxxx.xxxxx.xxx.xxxx pdns_server: Loading '/usr/lib64/pdns/libgmysqlbackend.so'
Feb 17 13:39:35 xxxx.xxxxx.xxx.xxxx pdns_server: This is a standalone pdns
I don't know if this can be related, but just before those crashes we see messages like:
Feb 17 13:39:32 xxxx.xxxxx.xxx.xxxx pdns_server: Request to queue notification for domain yyyyy.yy was processed, but no valid nameserver or ALSO-NOTIFYs found. Not notifying!
Just to mention briefly our setup: we are running:
PowerDNS Authoritative Server 4.5.2 (C)
in a percona mysql cluster with three nodes, each node having it's own mysql and pdns server (in order to have redundancy of database and APIs).
This cluster acts as a "backend master" for the real authoritative slaves, placed elsewhere, replicating the db.
Can you help us to understand why we have those crashes?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Pdns-users