OSSEC is typically compiled on each system it is installed on, but this may not always be easy. To help in these cases there are a few methods of binary installation available. OSSEC can be compiled on one system, and copied to the destination systems. This installation method still requires GNU make on the target system.
There are also RPM and deb packages available for some systems.
Note
OSSEC has very limited cross compiling facilities. Windows binaries can be built on Linux systems, but binaries for other systems should be built on a system of the same OS and CPU platform.
First download the OSSEC package corresponding to the version you want to install and unpack it (on the system with a compiler).
# wget -U ossec http://www.ossec.net/files/ossec-hids-2.8.1.tar.gz
# tar -zxvf ossec-hids-latest.tar.gz
Enter in the source directory of the downloaded package, and configure OSSEC to build the agent
version.
The make
commands should compile the correct binaries.
# cd ossec-*/src
# make setagent
# make all
# make build
Modify ossec-hids-*/etc/preloaded-vars.conf to set BINARY_INSTALL to yes.
# echo "USER_BINARYINSTALL=\"y\"" >> ossec-hids*/etc/preloaded-vars.conf
Finally create an OSSEC package.
# tar -cvf ossec-binary.tar ossec-hids*
On the target system (that does not have a C compiler) download your ossec-binary.tar created in the steps above.
Complete the installation by unarchiving the binary package and running ./install.sh.
# tar xfv ossec-binary.tar
# cd ossec-*
# ./install.sh
After following the installation prompts the install will be complete.