第 1 章 设置和配置 BIND DNS 服务器

BIND 是一个功能丰富的 DNS 服务器,它完全符合互联网工程任务 Force (IETF) DNS 标准和草案标准。例如,管理员经常使用 BIND,如下所示:

  • 在本地网络中缓存 DNS 服务器
  • 区域的权威 DNS 服务器
  • 二级服务器来为区域提供高可用性

1.1. 有关使用 SELinux 保护 BIND 的注意事项,或者在更改 root 环境中运行

要保护 BIND 安装,您可以:

  • 运行 named 而不需要 change-root 环境。在这种情况下,enforcing 模式中的 SELinux 会阻止利用已知的 BIND 安全漏洞。默认情况下,Red Hat Enterprise Linux 在 enforcing 模式中使用 SELinux。

    重要

    在 SELinux 处于 enforcing 模式的 RHEL 上运行 BIND 比在 change-root 环境中运行 BIND 更安全。

  • 在 change-root 环境中运行 named-chroot 服务。

    利用 change-root 功能,管理员可以定义进程的根目录及其子进程与 / 目录不同。当您启动 named-chroot 服务时,BIND 将其根目录切换到 /var/named/chroot/。因此,服务使用 mount --bind 命令使 /etc/named-chroot.files 中列出的文件和目录保存在 /var/named/chroot/ 中,并且进程无法访问 /var/named/chroot/ 以外的文件。

如果您决定使用 BIND:

  • 在正常模式中,使用 named 服务。
  • 在 change-root 环境中,使用 named-chroot 服务。这要求您安装 named-chroot 软件包。

其他资源

  • named(8) man page 的 Red Hat SELinux BIND security profile 部分