Centos

barnyard2 的 snort 權限被拒絕

  • August 14, 2015

我為 snort 安裝了 barnyard2,但是當我在下面執行命令時出現此錯誤。

[root@localhost snort]# barnyard2 -c /etc/snort/barnyard2.conf -d /var/log/snort/ -f snort.log -w /etc/snort/bylog.waldo /etc/snort/gen-msg.map /etc/snort/sid-msg.map -C /etc/snort/classification.config 
Running in Continuous mode

   --== Initializing Barnyard2 ==--
Initializing Input Plugins!
Initializing Output Plugins!
Parsing config file "/etc/snort/barnyard2.conf"


+[ Signature Suppress list ]+
----------------------------
+[No entry in Signature Suppress List]+
----------------------------
+[ Signature Suppress list ]+

Barnyard2 spooler: Event cache size set to [2048] 
ERROR: Can not get write access to logging directory "/var/log/barnyard2". (directory doesn't exist or permissions are set incorrectly or it is not a directory at all)
Fatal Error, Quitting..
Barnyard2 exiting

和許可是:

[root@localhost snort]# ls -l /var/log/barnyard2 
-rwxrwxrwx. 1 root root 0 Aug 14 16:35 /var/log/barnyard2

在此連結中,此問題已解決,但我不明白如何…

https://forums.freebsd.org/threads/barnyard2-start-service-error.51378/

那是一個文件,而不是一個目錄。ls 輸出的第一列中有一個“-”,而不是“d”。

引用自:https://serverfault.com/questions/714217