Re: [Pdns-users] Question regarding backend threads inPDNS

"Aki Tuomi" <[email protected]>
Newsgroups gmane.network.dns.powerdns.devel,gmane.network.dns.powerdns.user
Message-ID <[email protected]>
On Wed, Oct 30, 2013 at 06:31:19AM +0000, Seema Datar wrote:
> 
> Hi All,
> 
> I run PDNS with multiple backend threads. I need to introduce counters in the threads.  I also need to flush those counters periodically to a data store. I was evaluating spawning another thread to periodically flush these counters to the datastore. The question is can I spawn another backend thread that does not necessarily implement all the interface methods (lookup, getSOA etc.). What will be a recommended way to achieve this?
> 
> Thanks,
> Seema

If you don't mind some ruby/python, you can use remotebackend for this.

# file /etc/powerdns/handler.rb

require 'pdns/remotebackend'

class EmptyHandler < Pdns::Remotebackend::Handler
end

Pdns::Remotebackend::PipeConnector(EmptyHandler).run()

# eof

# file /etc/powerdns/pdns.conf

...

launch+=remote
remote-connection-string=pipe:command=/etc/powerdns/handler.rb

...

# eof

sparing any typos you should now have a backend thread that does not 
respond to any queries other than "does not exist here". 

you can now set it up to do other stuff as well. 

Aki

> _______________________________________________
> Pdns-dev mailing list
> [email protected]
> http://mailman.powerdns.com/mailman/listinfo/pdns-dev

_______________________________________________
Pdns-users mailing list
[email protected]
http://mailman.powerdns.com/mailman/listinfo/pdns-users

_______________________________________________
Pdns-dev mailing list
[email protected]
http://mailman.powerdns.com/mailman/listinfo/pdns-dev
signature.asc (application/pgp-signature, 198 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEYEARECAAYFAlJwstcACgkQahHbMDrZuj4VLgCfb3JBzun0NZAIXxpDQwDauCAZ
CKcAn3x+qHOdFUWyOMOaEhfWc1T6+yHu
=I0Ap
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.