About rsmonitor Installation Configuration and use Preview

Installation

A dedicated non-privileged user and associated group should be added on both the monitoring server and each of the monitored servers. This document assumes that both the user and group is called "rsmon".

If you want the server status to be available over the network you should also have a webserver configured on the monitoring server, and rsmonitor should be configured to put its generated files where the web server can get to them. Web server configuration will not be discussed here.

On the monitoring server:

  # Add rsmon group and user
  sudo /usr/sbin/groupadd rsmon
  sudo /usr/sbin/useradd -c "Server Monitoring User" \
       -m -s /bin/sh -g rsmon rsmon

  # The rest should be done as the rsmon user
  sudo su - rsmon
  
  # Create an ssh rsa public key
  ssh-keygen -t rsa -b 2048
  # Just hit enter on the passphrase question, it should be blank

  # untar the distribution
  tar xvzf /somewhere/download/rsmonitor_<version>.tgz
  # Adjust the paths in rsmonitor.conf
  # Add your servers to rsmonitor_servers.conf 
  # If AppMonDir and OutputDir is set to non-default values it is safe
  # to unpack a new version of rsmonitor over an existing one.
  
  # Schedule rsmon_runall.sh to be run in cron
  crontab -e
  # Add a line looking like this:
  #   * * * * * /home/rsmon/rsmonitor/app/rsmon_runall.sh
  # This will poll servers once each minute.
  # If the config directory is another than $HOME/rsmonitor/conf this can
  # be overridden with the command line option --confdir

The monitoring server installation should now be complete. To set up the clients the rsmon user and group will have to be added, and public key authentication will have to be set up to allow for password-free login from the monitoring server to the monitored servers.

On the monitored servers:

  # Add rsmon group and user
  sudo /usr/sbin/groupadd rsmon
  sudo /usr/sbin/useradd -c "Server Monitoring User" \
       -m -s /bin/sh -g rsmon rsmon

  # The rest should be done as the rsmon user
  sudo su - rsmon

  # Set up public key authentication
  mkdir .ssh
  chmod 700 .ssh
  cat >> .ssh/authorized_keys
  # paste in id_rsa.pub from /home/rsmon/.ssh at monitoring server
  chmod go-w .ssh/authorized_keys

Now the monitored server should be set up correctly.

Finally the monitoring server needs to update its list of known host keys, so you will have to do a single login from the monitoring server to the monitored server.

On the monitoring server:

  sudo su - rsmon
  ssh monitored_server exit
  # Answer yes to accept the monitored_servers host key

rsmonitor should now be up and running.


Last modified: Sat Mar 3 23:48:35 CET 2007
Rune Sætre < rune.saetre at netcom-gsm.no >