服务器作业3
关闭防火墙:
[root@localhost ~]# systemctl stop firewalld
[root@localhost ~]# setenforce 0
从dns服务器
[root@localhost ~]# vim /etc/named.conf
options {
listen-on port 53 { 192.168.61.111; };
directory “/var/named/slaves”;
allow-query { any; };
};
zone “openlab.com” IN { //正向解析域
type slave; //slave
file “named.openlab.com”; //正向解析的资源记录文件(数据文件)
masters { 192.168.61.100; };//主dns服务器
};
zone “61.168.192.in-addr.arpa” IN { //网络位地址倒序表示
type slave;
file “named.192”;
masters { 192.168.61.100; };
};
[root@localhost ~]# systemctl restart named
[root@localhost ~]# watch ls -l /var/named/slaves/
进行正反解析