:title: Server Density Tutorial :description: How to install server density monitoring platform in your dotCloud stack. :keywords: dotCloud, tutorial, documentation, server density Server Density ============== `Server Density `_ is a monitoring-as-a-service platform. If you have an account with them, and want to use their service to monitor your dotCloud stack, you can! (If you don't have an account with them, but still want to have a look, they have a 15 days trial.) The installation is actually pretty easy; it is based on the manual install. .. note:: Important! The basic Server Density setup requires only Python, without any special extra dependency. Therefore, it can run on any dotCloud service. However, if you want to monitor a database, you will need additional Python packages. The easiest way to install those packages will be to run an extra Server Density agent from a python-worker service. .. contents:: :local: :depth: 1 Basic Installation ------------------ Go to your service application root. It is the directory pointed by the "approot" parameter in your "dotcloud.yml" file. If you did not specify an approot, it defaults to the directory containing "dotcloud.yml". For the sake of clarity, we will assume that it's named "approot":: cd approot Download the Server Density agent:: wget http://www.serverdensity.com/downloads/sd-agent.tar.gz Uncompress it:: tar -zxf sd-agent.tar.gz You can now remove the tarball:: rm sd-agent.tar.gz Configure the agent with your favourite editor (*vi* or anything else), and enter the *sd_url* and *agent_key* shown in your Server Density dashboard:: vi sd-agent/config.cfg You will now need a little supervisord.conf file to start the agent automatically (if you already have a supervisord.conf file, the following will add a new section to it, without breaking anything):: cat >>supervisord.conf <>supervisord.conf <`_. Else only the first service will be monitored (others will be blocked). Updating the Agent ------------------ You can run "python agent.py update" in your local repository. This will download the latest agent version and overwrite the current version. Then push your application again to push the new agent to your services.