Product:
Search Type:

How could I configure PowerDNS server to work with remote MySQL database?

Article ID: 2019 
Last Review: Jul,13 2007
APPLIES TO:
  • HSPcomplete 3.3.x

RESOLUTION

In case you are using database on a separate server you also should properly configure MySQL server and PowerDNS server.

  • Grant privileges for management node and host running PowerDNS server:

    IP_ADDR_DNS - the address of HSPcomplete node where PowerDNS server is running or IP address of server where PowerDNS installed in case PowerDNS server runs separately from HSPcomplete.

    Run the following SQL commands to grant privileges on database in mysql command shell:

    use aspc;
    grant select on dm_zone to pdns@IP_ADDR_DNS;
    grant select on dm_record to pdns@IP_ADDR_DNS;
    grant select on dm_zone_suspended to pdns@IP_ADDR_DNS;
    grant select on dm_record_suspended to pdns@IP_ADDR_DNS;
    grant all on pdns_data to pdns@IP_ADDR_DNS;
    FLUSH PRIVILEGES;
  • Configure PowerDNS server. Please perform the following changes in /etc/powerdns/pdns.conf file:
    • Comment out gmysql-socket parameter
    • Setup parameter gmysql-host=IP_DB_SRV where IP_DB_SRV is IP address of MySQL server.
    • restart PowerDNS server:
      /etc/init.d/pdns restart

After that please review logs of PowerDNS server at /var/log/messages file to make sure PowerDNS successfully connected to database server.

Keywords: PowerDNS, pdns, remote database

Please provide feedback on this article

Did this article help you solve your issue?
Yes
No
Partially
I do not know yet
 
Strongly Agree   Strongly Disagree
  9 8 7 6 5 4 3 2 1
The article is easy to understand
The article is accurate
Additional Comments:
*Please provide us with your email address in case we need to contact you.
*Please type the code you can see.
* - required fields