I have just installed the current stable release of OSSEC (2.8.1) for Ubuntu, but at the end of the installation I noticed that it said:
- System is Debian (Ubuntu or derivative).
- Init script modified to start OSSEC HIDS during boot.
- Configuration finished properly.
- To start OSSEC HIDS:
/var/ossec/bin/ossec-control start
- To stop OSSEC HIDS:
/var/ossec/bin/ossec-control stop
- The configuration can be viewed or modified at /var/ossec/etc/ossec.conf
So what is OSSEC HIDS
, is it the actual program or something else? If it is the actual program then does this mean that I need to add the command /var/ossec/bin/ossec-control start
to the list of startup applications?
Information Update:
I have found that unless I run this command to manually start OSSEC HIDS:
sudo /var/ossec/bin/ossec-control start
That if I run the command to check the status:
sudo /var/ossec/bin/ossec-control status
This is the output:
ossec-monitord not running...
ossec-logcollector not running...
ossec-syscheckd not running...
ossec-analysisd not running...
ossec-maild not running...
ossec-execd not running...
So it does not seem that it starts automatically, how can I get it to do this then? I have also found that I cannot add this to the list of startup applications as the start command requires sudo
to be executed.
OS Information:
Description: Ubuntu 14.10
Release: 14.10
/etc/rc.local
, where thesudo
wouldn't be needed. – muru Apr 05 '15 at 10:20sudo
at the start of the command? – Apr 05 '15 at 10:21/var/ossec/bin/ossec-control start
to/etc/rc.local
, and without thesudo
. Commands inrc.local
are run as root. – muru Apr 05 '15 at 10:23#!/bin/sh -e
at least? And should I just leave theexit 0
there? – Apr 05 '15 at 10:24exit 0
in there, should I put my command before or after it, or does it not matter? – Apr 05 '15 at 10:26#!/bin/sh -e
is a shebang, not a comment. – muru Apr 05 '15 at 10:26exit 0
- if the script exits before your command, how will it get executed? – muru Apr 05 '15 at 10:27.sh
file. Using thelocal
mode, all of the installation should have been automated. But I would like to know how it makes it automated, so that maybe I could do that manually. – Apr 10 '15 at 12:51ossec-control
completely away. – JdeBP May 04 '15 at 18:19/etc/rc.local
file as this fixed my problem, but there is no answer to accept here. Also you should probably mention that on 15.04 it works fine without adding that because it already is started on system startup withsystemd
. :) – Aug 20 '15 at 08:52