02
2020
06
19:12:18

在/etc/named.conf 中增加日志选项

在/etc/named.conf 中增加日志选项
/etc/named.conf中logging 选项,增加以下选项后,系统会在/var/log/named/ 下增加dns-default.log,dns-lamer.log,dns-query.log,dns-security.log,dns-security.log五个文件,同时/var/log/named 路径必须有named的相关权限。
logging {
channel default_log {
file "/var/log/named/dns-default.log" versions 10 size 1m;
severity info;
};
channel lamer_log {
file "/var/log/named/dns-lamer.log" versions 3 size 1m;
severity info;
print-severity yes;
print-time yes;
print-category yes;
};
channel query_log {
file "/var/log/named/dns-query.log" versions 10 size 10m;
severity info;
};
channel security_log {
file "/var/log/named/dns-security.log" versions 3 size 1m;
severity info;
print-severity yes;
print-time yes;
print-category yes;
};
category lame-servers { lamer_log; };
category security{ security_log;};
category queries { query_log;};
category default {default_log;};
};


[@more@]



推荐本站淘宝优惠价购买喜欢的宝贝:

image.png

本文链接:https://hqyman.cn/post/1327.html 非本站原创文章欢迎转载,原创文章需保留本站地址!

分享到:
打赏





休息一下~~


« 上一篇 下一篇 »

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

请先 登录 再评论,若不是会员请先 注册

您的IP地址是: