Home
This is the lightweight, open source Python monitoring agent for serverdensity.com. It is licensed under the New FreeBSD open source license.
Installation instructions
- Download the agent to your server
- Extract the .tar.gz archive
- Edit the config for your server
- Start the daemon
Or use the Debian/Ubuntu and Red Hat/Fedora packages for yum/apt-get.
config.cfg
The agent page in the Server Density interface will give you the actual values for each server.
| Option | Description |
| sd_url | Your Server Density URL |
| agent_key | A key to uniquely identify this server |
See the documentation for a full list of config options.
Requirements
To monitor your server, you must install the Server Density monitoring agent. This is a small daemon written in Python which polls the server every 60 seconds for the necessary statistical data. The data is then posted back to the main application to be displayed and graphed on the server view.
The daemon will only work on Python 2.4+. Python 3 is not supported. We test each release on a wide range of systems – check out the full list on the FAQ.
Daemon control
The sd-agent daemon works like any other *nix daemon in that it will accept the commands start, stop and restart. Just remember you need to execute it using Python from within the directory the files are in. You can confirm it is running by the existence of the PID file at /tmp/sd-agent.pid.
python agent.py start|stop|restart|update|status
Linux startup
By default the monitoring agent will not start on boot. We provide a Linux startup script that can be quickly installed to allow the agent to be automatically started on boot. Follow the instructions here to install this script.
Note: The usual PID file location /tmp/sd-agent.pid changes when using the init.d script to /var/run/sd-agent.pid.
Ports and firewalls
The agent will need to be able to communicate with our servers. Data is only sent one way – from your server to our servers – over standard HTTP port 80.
For added security, you can set the agent to use SSL by entering https as part of the sd_url in the agent config.cfg file. If you do this, port 443 must be open on your firewall.
