firnsy / barnyard2

Barnyard2 is a dedicated spooler for Snort's unified2 binary output format.
GNU General Public License v2.0
344 stars 190 forks source link

barnyard2 on centos error sysmtemctl status barnyard2 - Missing '='. #235

Open cherazo opened 6 years ago

cherazo commented 6 years ago

Hi Guys,

Please apologize if this is not the correct place to put this.

I installed barnyard2 from source following and how to from google.

The issue is when I tried to run it as a service, even manually or by the startup script.

which barnyard2 (output)

/usr/local/bin/barnyard2

/etc/rc.d/init.d/barnyard2 - https://pastebin.com/NxHRA41N

/etc/systemd/system/barnyard2.service - https://pastebin.com/f0jR6wGS

/etc/init/barnyard2.conf - https://pastebin.com/kQwvK2uS

Everything as the proper permissions.

This is the error that I get when running-- systemctl status barnyard2

May 31 18:15:45 snort systemd[1]: [/etc/systemd/system/barnyard2.service:8] Missing '='.

Obviously, it says Missing '='. but where?

Thanks for the help.

vmichnowicz commented 4 years ago

I had this same problem. For me it was a copy / paste issue. Try putting your ExecStart on one line. Here is my full barnyard2.service file:

[Unit]
Description=Barnyard2 Daemon
After=syslog.target network.target

[Service]
Type=simple
User=snort
Group=snort
ExecStart=/usr/local/bin/barnyard2 -c /etc/snort/barnyard2.conf -d /var/log/snort -f snort.log -w /var/log/barnyard2/barnyard2.waldo

[Install]
WantedBy=multi-user.target