阿里云-云小站(无限量代金券发放中)
【腾讯云】云服务器、云数据库、COS、CDN、短信等热卖云产品特惠抢购

RHEL/CentOS 7中安装并配置 PowerDNS 和 PowerAdmin

211次阅读
没有评论

共计 12614 个字符,预计需要花费 32 分钟才能阅读完成。

PowerDNS 是一个运行在许多 Linux/Unix 衍生版上的 DNS 服务器,它可以使用不同的后端进行配置,包括 BIND 类型的区域文件、关系型数据库,或者负载均衡 / 失效转移算法。它也可以被配置成一台 DNS 递归器,作为服务器上的一个独立进程运行。

PowerDNS 授权服务器的最新版本是 3.4.4,但是当前 EPEL 仓库中可以获得的版本是 3.4.3。我推荐安装 EPEL 仓库中提供的那一个,因为该版本已经在 CentOS 和 Fedora 中测试过。那样,你也可以在今后很容易地更新 PowerDNS。

本文用于向你演示如何在 RHEL/CentOS 7 中安装并配置以 MariaDB 作为后端的 PowerDNS,以及它的界面友好的 Web 管理工具 PowerAdmin。

CentOS 下的 PowerDNS +Poweradmin  http://www.linuxidc.com/Linux/2013-04/82884.htm

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

出于本文的写作目的,我将使用以下服务器:

  1. 主机名: centos7.localhost
  2. IP 地址:192.168.0.102

第一部分:安装带有 MariaDB 后端的 PowerDNS

1、首先,你需要为你的系统启用 EPEL 仓库,只需使用:

  1. # yum install epel-release.noarch

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用 Epel 仓库

2、下一步是安装 MariaDB 服务器。运行以下命令即可达成:

  1. # yum -y install mariadb-server mariadb

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

安装 MariaDB 服务器

3、接下来,我们将配置并启用 MariaDB,并设置开机启动:

  1. # systemctl enable mariadb.service
  2. # systemctl start mariadb.service

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用 MariaDB 开机启动

4、现在 MariaDB 服务运行起来了,我们将为 MariaDB 设置密码进行安全加固,运行以下命令:

  1. # mysql_secure_installation

按照指示做

  1. /bin/mysql_secure_installation: line 379: find_mysql_client: command not found
  2. NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
  3. SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!
  4. In order to log intoMariaDB to secure it, we'll need the current
  5. password for the root user. If you've just installed MariaDB,and
  6. you haven't set the root password yet, the password will be blank,
  7. so you should just press enter here.
  8. Enter current password for root (enter for none): Press ENTER
  9. OK, successfully used password, moving on...
  10. Setting the root password ensures that nobody can log into the MariaDB
  11. root user without the proper authorisation.
  12. Set root password? [Y/n] y
  13. New password: ← Set New Password
  14. Re-enter new password: ← Repeat Above Password
  15. Password updated successfully!
  16. Reloading privilege tables..
  17. ... Success!
  18. By default, a MariaDB installation has an anonymous user, allowing anyone
  19. to log into MariaDB without having to have a user account created for
  20. them. This is intended only for testing, and to make the installation
  21. go a bit smoother. You should remove them before moving into a
  22. production environment.
  23. Remove anonymous users? [Y/n] y ← Choose“y”to disable that user
  24. ... Success!
  25. Normally, root should only be allowed to connect from 'localhost'. This
  26. ensures that someone cannot guess at the root password from the network.
  27. Disallow root login remotely? [Y/n] n ← Choose“n”for no
  28. ... skipping.
  29. By default, MariaDB comes with a database named 'test' that anyone can
  30. access. This is also intended only for testing, and should be removed
  31. before moving into a production environment.
  32. Remove test database and access to it? [Y/n] y ← Choose“y”for yes
  33. - Dropping test database...
  34. ... Success!
  35. - Removing privileges on test database...
  36. ... Success!
  37. Reloading the privilege tables will ensure that all changes made so far
  38. will take effect immediately.
  39. Reload privilege tables now? [Y/n] y ← Choose“y”for yes
  40. ... Success!
  41. Cleaning up...
  42. All done! If you've completed all of the above steps, your MariaDB
  43. installation should now be secure.
  44. ThanksforusingMariaDB!

5、MariaDB 配置成功后,我们可以继续去安装 PowerDNS。运行以下命令即可轻易完成:

  1. # yum -y install pdns pdns-backend-mysql

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

安装带有 MariaDB 后端的 PowerDNS

6、PowerDNS 的配置文件位于 /etc/pdns/pdns,在编辑之前,我们将为 PowerDNS 服务配置一个 MariaDB 数据库。首先,我们将连接到 MariaDB 服务器并创建一个名为 powerdns 的数据库:

  1. # mysql -u root -p
  2. MariaDB[(none)]> CREATE DATABASE powerdns;

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建 PowerDNS 数据库

7、接下来,我们将创建一个名为 powerdns 的数据库用户:

  1. MariaDB[(none)]> GRANT ALL ON powerdns.* TO 'powerdns'@'localhost' IDENTIFIED BY tecmint123’;
  2. MariaDB[(none)]> GRANT ALL ON powerdns.* TO 'powerdns'@'centos7.localdomain' IDENTIFIED BY 'tecmint123';
  3. MariaDB[(none)]> FLUSH PRIVILEGES;

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建 PowerDNS 用户

注意 :请将“tecmint123”替换为你想要设置的实际密码。

8、我们继续创建 PowerDNS 要使用的数据库表。像堆积木一样执行以下这些:

  1. MariaDB[(none)]> USE powerdns;
  2. MariaDB[(none)]> CREATE TABLE domains (
  3. id INT auto_increment,
  4. name VARCHAR(255) NOT NULL,
  5. master VARCHAR(128) DEFAULT NULL,
  6. last_check INT DEFAULT NULL,
  7. type VARCHAR(6) NOT NULL,
  8. notified_serial INT DEFAULT NULL,
  9. account VARCHAR(40) DEFAULT NULL,
  10. primary key (id)
  11. );

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建用于 PowerDNS 的表 domains

  1. MariaDB[(none)]> CREATE UNIQUE INDEX name_index ON domains(name);
  2. MariaDB[(none)]> CREATE TABLE records (
  3. id INT auto_increment,
  4. domain_id INT DEFAULT NULL,
  5. name VARCHAR(255) DEFAULT NULL,
  6. type VARCHAR(6) DEFAULT NULL,
  7. content VARCHAR(255) DEFAULT NULL,
  8. ttl INT DEFAULT NULL,
  9. prio INT DEFAULT NULL,
  10. change_date INT DEFAULT NULL,
  11. primary key(id)
  12. );

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建用于 PowerDNS 的表 records

  1. MariaDB[(none)]> CREATE INDEX rec_name_index ON records(name);
  2. MariaDB[(none)]> CREATE INDEX nametype_index ON records(name,type);
  3. MariaDB[(none)]> CREATE INDEX domain_id ON records(domain_id);

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建表索引

  1. MariaDB[(none)]> CREATE TABLE supermasters (
  2. ip VARCHAR(25) NOT NULL,
  3. nameserver VARCHAR(255) NOT NULL,
  4. account VARCHAR(40) DEFAULT NULL
  5. );

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建表 supermasters

你现在可以输入以下命令退出 MariaDB 控制台:

  1. MariaDB[(none)]> quit;

9、最后,我们可以继续配置 PowerDNS 了,以 MariaDB 作为后台。请打开 PowerDNS 的配置文件:

  1. # vim /etc/pdns/pdns.conf

在该文件中查找像下面这样的行:

  1. #################################
  2. # launch Which backends to launch and order to query them in
  3. #
  4. # launch=

在这后面放置以下代码:

  1. launch=gmysql
  2. gmysql-host=localhost
  3. gmysql-user=powerdns
  4. gmysql-password=user-pass
  5. gmysql-dbname=powerdns

修改“user-pass”为你先前设置的实际密码,配置如下:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

配置 PowerDNS

保存修改并退出。

10、现在,我们将启动并添加 PowerDNS 到系统开机启动列表:

  1. # systemctl enable pdns.service
  2. # systemctl start pdns.service

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用并启动 PowerDNS

到这一步,你的 PowerDNS 服务器已经起来并运行了。要获取更多关于 PowerDNS 的信息,你可以参考手册 http://downloads.powerdns.com/documentation/html/index.html。

更多详情见请继续阅读下一页的精彩内容 :http://www.linuxidc.com/Linux/2015-06/118817p2.htm

第二部分:安装 PowerAdmin 来管理 PowerDNS

11、现在,我们将安装 PowerAdmin——一个界面友好的 PowerDNS 服务器的 Web 管理器。由于它是用 PHP 写的,我们将需要安装 PHP 和一台网络服务器(Apache):

  1. # yum install httpd php php-devel php-gd php-imap php-ldap php-mysql php-odbc php-pear php-xml php-xmlrpc php-mbstring php-mcrypt php-mhash gettext

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

安装 Apache 和 PHP

PowerAdmin 也需要两个 PEAR 包:

  1. # yum -y install php-pear-DB php-pear-MDB2-Driver-mysql

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

安装 Pear

你也可以参考一下文章了解 CentOS 7 中安装 LAMP 的完整指南:http://www.linuxidc.com/Linux/2015-06/118818.htm

安装完成后,我们将需要启动并设置 Apache 开机启动:

  1. # systemctl enable httpd.service
  2. # systemctl start httpd.service

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用 Apache 开机启动

12、由于已经满足 PowerAdmin 的所有系统要求,我们可以继续下载软件包。因为 Apache 默认的网页目录位于 /var/www/html/,我们将下载软件包到这里。

  1. # cd /var/www/html/
  2. # wget http://downloads.sourceforge.net/project/poweradmin/poweradmin-2.1.7.tgz
  3. # tar xfv poweradmin-2.1.7.tgz

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

下载 PowerAdmin

13、现在,我们可以启动 PowerAdmin 的网页安装器了,只需打开:

  1. http://192.168.0.102/poweradmin-2.1.7/install/

这会进入安装过程的第一步:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

选择安装语言

上面的页面会要求你为 PowerAdmin 选择语言,请选择你想要使用的那一个,然后点击“进入步骤 2”按钮。

14、安装器需要 PowerDNS 数据库:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

PowerDNS 数据库

15、因为我们已经创建了一个数据库,所以我们可以继续进入下一步。你会被要求提供先前配置的数据库详情,你也需要为 Poweradmin 设置管理员密码:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

输入 PowerDNS 数据库配置

16、输入这些信息后,进入步骤 4。你将创建为 Poweradmin 创建一个受限用户。这里你需要输入的字段是:

  • 用户名(Username)– PowerAdmin 用户名。
  • 密码(Password)– 上述用户的密码。
  • 主机管理员(Hostmaster)– 当创建 SOA 记录而你没有指定主机管理员时,该值会被用作默认值。
  • 主域名服务器 – 该值在创建新的 DNS 区域时会被用于作为主域名服务器。
  • 辅域名服务器 – 该值在创建新的 DNS 区域时会被用于作为辅域名服务器。

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

PowerDNS 配置设置

17、在下一步中,Poweradmin 会要求你在数据库表中创建一个新的受限数据库用户,它会提供你需要在 MariaDB 控制台输入的代码:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建新的数据库用户

18、现在打开终端并运行:

  1. # mysql -u root -p

提供你的密码并执行由 PowerAdmin 提供的代码:

  1. MariaDB[(none)]> GRANT SELECT, INSERT, UPDATE, DELETE
  2. ON powerdns.*
  3. TO 'powermarin'@'localhost'
  4. IDENTIFIED BY '123qweasd';

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

为用户授予 Mysql 权限

19、现在,回到浏览器中并继续下一步。安装器将尝试创建配置文件到 /var/www/html/poweradmin-2.1.7/inc。

文件名是 config.inc.php。为防止该脚本没有写权限,你可以手动复制这些内容到上述文件中:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

配置 PowerDNS 设置

20、现在,进入最后页面,该页面会告知你安装已经完成以及如何访问安装好的 PowerAdmin:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

PowerDNS 安装完成

你可以通过运行以下命令来启用用于其他动态 DNS 提供商的 URL:

  1. # cp install/htaccess.dist .htaccess

出于该目的,你将需要在 Apache 的配置中启用 mod_rewrite。

21、现在,需要移除从 PowerAdmin 的根目录中移除“install”文件夹,这一点很重要。使用以下命令:

  1. # rm -fr /var/www/html/poweradmin/install/

在此之后,你可以通过以下方式访问 PowerAdmin:

  1. http://192.168.0.102/poweradmin-2.1.7/

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

PowerDNS 登录

在登录后,你应该会看到 PowerAdmin 的主页:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

PowerDNS 仪表盘

到这里,安装已经完成了,你也可以开始管理你的 DNS 区域了。

PowerDNS 是一个运行在许多 Linux/Unix 衍生版上的 DNS 服务器,它可以使用不同的后端进行配置,包括 BIND 类型的区域文件、关系型数据库,或者负载均衡 / 失效转移算法。它也可以被配置成一台 DNS 递归器,作为服务器上的一个独立进程运行。

PowerDNS 授权服务器的最新版本是 3.4.4,但是当前 EPEL 仓库中可以获得的版本是 3.4.3。我推荐安装 EPEL 仓库中提供的那一个,因为该版本已经在 CentOS 和 Fedora 中测试过。那样,你也可以在今后很容易地更新 PowerDNS。

本文用于向你演示如何在 RHEL/CentOS 7 中安装并配置以 MariaDB 作为后端的 PowerDNS,以及它的界面友好的 Web 管理工具 PowerAdmin。

CentOS 下的 PowerDNS +Poweradmin  http://www.linuxidc.com/Linux/2013-04/82884.htm

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

出于本文的写作目的,我将使用以下服务器:

  1. 主机名: centos7.localhost
  2. IP 地址:192.168.0.102

第一部分:安装带有 MariaDB 后端的 PowerDNS

1、首先,你需要为你的系统启用 EPEL 仓库,只需使用:

  1. # yum install epel-release.noarch

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用 Epel 仓库

2、下一步是安装 MariaDB 服务器。运行以下命令即可达成:

  1. # yum -y install mariadb-server mariadb

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

安装 MariaDB 服务器

3、接下来,我们将配置并启用 MariaDB,并设置开机启动:

  1. # systemctl enable mariadb.service
  2. # systemctl start mariadb.service

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用 MariaDB 开机启动

4、现在 MariaDB 服务运行起来了,我们将为 MariaDB 设置密码进行安全加固,运行以下命令:

  1. # mysql_secure_installation

按照指示做

  1. /bin/mysql_secure_installation: line 379: find_mysql_client: command not found
  2. NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB
  3. SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!
  4. In order to log intoMariaDB to secure it, we'll need the current
  5. password for the root user. If you've just installed MariaDB,and
  6. you haven't set the root password yet, the password will be blank,
  7. so you should just press enter here.
  8. Enter current password for root (enter for none): Press ENTER
  9. OK, successfully used password, moving on...
  10. Setting the root password ensures that nobody can log into the MariaDB
  11. root user without the proper authorisation.
  12. Set root password? [Y/n] y
  13. New password: ← Set New Password
  14. Re-enter new password: ← Repeat Above Password
  15. Password updated successfully!
  16. Reloading privilege tables..
  17. ... Success!
  18. By default, a MariaDB installation has an anonymous user, allowing anyone
  19. to log into MariaDB without having to have a user account created for
  20. them. This is intended only for testing, and to make the installation
  21. go a bit smoother. You should remove them before moving into a
  22. production environment.
  23. Remove anonymous users? [Y/n] y ← Choose“y”to disable that user
  24. ... Success!
  25. Normally, root should only be allowed to connect from 'localhost'. This
  26. ensures that someone cannot guess at the root password from the network.
  27. Disallow root login remotely? [Y/n] n ← Choose“n”for no
  28. ... skipping.
  29. By default, MariaDB comes with a database named 'test' that anyone can
  30. access. This is also intended only for testing, and should be removed
  31. before moving into a production environment.
  32. Remove test database and access to it? [Y/n] y ← Choose“y”for yes
  33. - Dropping test database...
  34. ... Success!
  35. - Removing privileges on test database...
  36. ... Success!
  37. Reloading the privilege tables will ensure that all changes made so far
  38. will take effect immediately.
  39. Reload privilege tables now? [Y/n] y ← Choose“y”for yes
  40. ... Success!
  41. Cleaning up...
  42. All done! If you've completed all of the above steps, your MariaDB
  43. installation should now be secure.
  44. ThanksforusingMariaDB!

5、MariaDB 配置成功后,我们可以继续去安装 PowerDNS。运行以下命令即可轻易完成:

  1. # yum -y install pdns pdns-backend-mysql

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

安装带有 MariaDB 后端的 PowerDNS

6、PowerDNS 的配置文件位于 /etc/pdns/pdns,在编辑之前,我们将为 PowerDNS 服务配置一个 MariaDB 数据库。首先,我们将连接到 MariaDB 服务器并创建一个名为 powerdns 的数据库:

  1. # mysql -u root -p
  2. MariaDB[(none)]> CREATE DATABASE powerdns;

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建 PowerDNS 数据库

7、接下来,我们将创建一个名为 powerdns 的数据库用户:

  1. MariaDB[(none)]> GRANT ALL ON powerdns.* TO 'powerdns'@'localhost' IDENTIFIED BY tecmint123’;
  2. MariaDB[(none)]> GRANT ALL ON powerdns.* TO 'powerdns'@'centos7.localdomain' IDENTIFIED BY 'tecmint123';
  3. MariaDB[(none)]> FLUSH PRIVILEGES;

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建 PowerDNS 用户

注意 :请将“tecmint123”替换为你想要设置的实际密码。

8、我们继续创建 PowerDNS 要使用的数据库表。像堆积木一样执行以下这些:

  1. MariaDB[(none)]> USE powerdns;
  2. MariaDB[(none)]> CREATE TABLE domains (
  3. id INT auto_increment,
  4. name VARCHAR(255) NOT NULL,
  5. master VARCHAR(128) DEFAULT NULL,
  6. last_check INT DEFAULT NULL,
  7. type VARCHAR(6) NOT NULL,
  8. notified_serial INT DEFAULT NULL,
  9. account VARCHAR(40) DEFAULT NULL,
  10. primary key (id)
  11. );

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建用于 PowerDNS 的表 domains

  1. MariaDB[(none)]> CREATE UNIQUE INDEX name_index ON domains(name);
  2. MariaDB[(none)]> CREATE TABLE records (
  3. id INT auto_increment,
  4. domain_id INT DEFAULT NULL,
  5. name VARCHAR(255) DEFAULT NULL,
  6. type VARCHAR(6) DEFAULT NULL,
  7. content VARCHAR(255) DEFAULT NULL,
  8. ttl INT DEFAULT NULL,
  9. prio INT DEFAULT NULL,
  10. change_date INT DEFAULT NULL,
  11. primary key(id)
  12. );

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建用于 PowerDNS 的表 records

  1. MariaDB[(none)]> CREATE INDEX rec_name_index ON records(name);
  2. MariaDB[(none)]> CREATE INDEX nametype_index ON records(name,type);
  3. MariaDB[(none)]> CREATE INDEX domain_id ON records(domain_id);

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建表索引

  1. MariaDB[(none)]> CREATE TABLE supermasters (
  2. ip VARCHAR(25) NOT NULL,
  3. nameserver VARCHAR(255) NOT NULL,
  4. account VARCHAR(40) DEFAULT NULL
  5. );

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

创建表 supermasters

你现在可以输入以下命令退出 MariaDB 控制台:

  1. MariaDB[(none)]> quit;

9、最后,我们可以继续配置 PowerDNS 了,以 MariaDB 作为后台。请打开 PowerDNS 的配置文件:

  1. # vim /etc/pdns/pdns.conf

在该文件中查找像下面这样的行:

  1. #################################
  2. # launch Which backends to launch and order to query them in
  3. #
  4. # launch=

在这后面放置以下代码:

  1. launch=gmysql
  2. gmysql-host=localhost
  3. gmysql-user=powerdns
  4. gmysql-password=user-pass
  5. gmysql-dbname=powerdns

修改“user-pass”为你先前设置的实际密码,配置如下:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

配置 PowerDNS

保存修改并退出。

10、现在,我们将启动并添加 PowerDNS 到系统开机启动列表:

  1. # systemctl enable pdns.service
  2. # systemctl start pdns.service

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

启用并启动 PowerDNS

到这一步,你的 PowerDNS 服务器已经起来并运行了。要获取更多关于 PowerDNS 的信息,你可以参考手册 http://downloads.powerdns.com/documentation/html/index.html。

更多详情见请继续阅读下一页的精彩内容 :http://www.linuxidc.com/Linux/2015-06/118817p2.htm

第三部分:PowerDNS 中添加、编辑和删除 DNS 区域

22、要添加新的主区域,只需点击“添加主区域”:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

添加主区域

在下一页中,你需要填写一些东西:

  • 域(Domain)– 你要添加区域的域。
  • 所有者(Owner)– 设置 DNS 区域的所有者。
  • 模板(Template)– DNS 模板 – 留空。
  • DNSSEC – 域名系统安全扩展(可选——看看你是否需要)。

点击“添加区域”按钮来添加 DNS 区域。

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

主 DNS 区域

现在,你可以点击“首页”链接回到 PowerAdmin 的首页。要查看所有现存的 DNS 区域,只需转到“列出区域(List Zones)”:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

查看区域列表

你现在应该看到一个可用 DNS 区域列表:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

检查 DNS 区域列表

23、要编辑现存 DNS 区域或者添加新的记录,点击编辑图标:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

编辑 DNS 区域

在接下来的页面,你会看到你选择的 DNS 区域的条目:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

域名的 DNS 区域条目

24、在此处添加新的 DNS 条目,你需要设置以下信息:

  • 名称(Name)– 条目名称。只需添加域 / 子域的第一部分,PowerAdmin 会添加剩下的。
  • 类型(Type)– 选择记录类型。
  • 优先级(Priority)– 记录优先级。
  • TTL – 存活时间,以秒计算。

出于本文目的,我将为子域 new.example.com 添加一个 A 记录用于解析 IP 地址 192.168.0.102,设置存活时间为 14400 秒:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

添加新 DNS 记录

最后,点击“添加记录”按钮。

25、如果你想要删除 DNS 区域,你可以回到“列出区域”页面,然后点击你想要删除的 DNS 区域旁边“垃圾桶”图标:

RHEL/CentOS 7 中安装并配置 PowerDNS 和 PowerAdmin

删除 DNS 区域

Poweradmin 将问你是否确定想要删除 DNS 区域。只需点击“是”来完成删除。

如要获取更多关于怎样创建、编辑和删除区域的说明,你可以参与 Poweradmin 的文档:https://github.com/poweradmin/poweradmin/wiki/Documentation

我希望你已经发现本文很有趣,也很有用。一如既往,如果你有问题或要发表评论,请别犹豫,在下面评论区提交你的评论吧。

更多 CentOS 相关信息见 CentOS 专题页面 http://www.linuxidc.com/topicnews.aspx?tid=14


via: http://www.tecmint.com/install-powerdns-poweradmin-mariadb-in-centos-rhel/

作者:Marin Todorov 译者:GOLinux 校对:wxy

本文由 LCTT 原创翻译,Linux 中国 荣誉推出

本文永久更新链接地址 :http://www.linuxidc.com/Linux/2015-06/118817.htm

正文完
星哥说事-微信公众号
post-qrcode
 0
星锅
版权声明:本站原创文章,由 星锅 于2022-01-20发表,共计12614字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
【腾讯云】推广者专属福利,新客户无门槛领取总价值高达2860元代金券,每种代金券限量500张,先到先得。
阿里云-最新活动爆款每日限量供应
评论(没有评论)
验证码
【腾讯云】云服务器、云数据库、COS、CDN、短信等云产品特惠热卖中