mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
1. reformulation, because i thought it's easier to read like this, the other version sounds strange to me...
2.1 KiB
2.1 KiB
source: Extensions/Agent-Setup.md
The agent can be used to gather data from remote systems you can use LibreNMS in combination with check_mk (found here). The agent can be extended to include data about applications on the remote system.
Make sure that systemd or xinetd is installed on the host you want to run the agent on.
The agent uses TCP-Port 6556, please allow access from the LibreNMS host and poller nodes if you're using the Distributed Polling setup.
On each of the hosts you would like to use the agent on, you need to do the following:
- Clone the
librenms-agent
repository:
cd /opt/
git clone https://github.com/librenms/librenms-agent.git
cd librenms-agent
- Copy the relevant check_mk_agent to
/usr/bin
:
linux | freebsd |
---|---|
cp check_mk_agent /usr/bin/check_mk_agent |
cp check_mk_agent_freebsd /usr/bin/check_mk_agent |
chmod +x /usr/bin/check_mk_agent
- Copy the service file(s) into place.
xinetd | systemd |
---|---|
cp check_mk_xinetd /etc/xinetd.d/check_mk |
cp check_mk@.service check_mk.socket /etc/systemd/system |
- Create the relevant directories.
mkdir -p /usr/lib/check_mk_agent/plugins /usr/lib/check_mk_agent/local
- Copy each of the scripts from
agent-local/
into/usr/lib/check_mk_agent/local
that you require to be graphed. You can find detail setup instructions for specific applications above. - Make each one executable that you want to use with
chmod +x /usr/lib/check_mk_agent/local/$script
- Enable the check_mk service
xinetd | systemd |
---|---|
/etc/init.d/xinetd restart |
systemctl enable check_mk.socket && systemctl start check_mk.socket |
- Login to the LibreNMS web interface and edit the device you want to monitor. Under the modules section, ensure that unix-agent is enabled.
- Then under Applications, enable the apps that you plan to monitor.
- Wait for around 10 minutes and you should start seeing data in your graphs under Apps for the device.