赞
踩
- ubuntu@dns:~$ sudo su -
- [sudo] password for ubuntu:
- root@dns:~# apt install bind9
- root@dns:~# vim /etc/bind/named.conf.default-zones
- // prime the server with knowledge of the root servers
- zone "." {
- type hint;
- file "/usr/share/dns/root.hints";
- };
-
- // be authoritative for the localhost forward and reverse zones, and for
- // broadcast zones as per RFC 1912
-
- zone "localhost" {
- type master;
- file "/etc/bind/db.local";
- };
-
- zone "127.in-addr.arpa" {
- type master;
- file "/etc/bind/db.127";
- };
-
- zone "0.in-addr.arpa" {
- type master;
- file "/etc/bind/db.0";
- };
-
- zone "255.in-addr.arpa" {
- type master;
- file "/etc/bind/db.255";
- };
-
- zone "openstack.jiangxi" { # 此处指定域名
- type master;
- file "/etc/bind/db.openstack.jiangxi"; #指定域名数据库存放位置
- };
-
- root@dns:~# vim /etc/bind/db.openstack.jiangxi
- $TTL 1D
- @ IN SOA master admin.openstack.jiangxi. ( 1 1D 5H 5H 2H )
- NS master
- master A 192.168.80.83
- controller A 192.168.80.80
- compute01 A 192.168.80.81
- compute02 A 192.168.80.82
-
-
- root@dns:~# systemctl restart bind9 #重启bind9服务
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。