This tutorial will guide through the process of setting up and using the SlapOS Monitor, a tool to monitor the health of a SlapOS network.
This tutorial requires you to have a computer with a SlapOS node installed and ready to use as well as access to and an account on a SlapOS Master. This can be Vifib (how to register on vifib) or a any other master (tutorial to create a SlapOS Master).
The Monitor can connect to and monitor any SlapOS deployment covering overall network status as well as individual computers down to separate partitions and processes running. Once connected with a SlapOS deployment it is tightly integrated into the SlapOS Master Dashboard and can be accessed in multiple ways shown in this section.
The easiest way to access the monitor is via the Access button on the side menu of the SlapOS Dashboard. Click Access Monitor in the left hand menu.
The Monitor has a different side menu than the SlapOS Dashboard. It gives access to:
By default the Monitor is not connected to an application. It is necessary to load a deployment configuration (the data sources) to "feed" the Monitor with the network parameters to observe. This configuration can be provided directly (Settings Content) or via a remote storage.
To continue select SlapOS Master ERP5 and click Proceed
Provide the Frontend url of your SlapOS Master and append
/hateoas/ (note, that this url must have a valid XXX wildcard SSL XXX certificate).
The Frontend url can be found in the connection parameters of the Frontend Slave you
are using to access the Master or - in case no Frontend is used - it is the url returned when calling
erp5 show -s
after finishing installation of a SlapOS Master.
Click Proceed to launch synchronisation of the SlapOS Master and the monitor.
XXX Review XXX Once synchronisation finishes the Monitor will load and display the list of Promises for the SlapOS Master.
Promises in SlapOS are executables doing arbitrary tasks and exiting with exit code 0 ("it works") or greater ("it doesn't work"). Everything in SlapOS is based on such Promises in order to automate the management of a SlapOS network (for more information on Promises, see understanding Promises in SlapOS).
In case a Promise fails (for example a computer not responding), a ticket will be created on the SlapOS Master in order for a user to follow up with this failing promise (see managing a SlapOS network).
Note, that the Monitor reports detailed instance status but does not provide any management functions such as handling of tickets. This has to be done in the SlapOS Master Dashboard which in turn only displays the global status of an instance (green, orange, red). Also note that the Monitor works autonomously from the SlapOS Master, so even if the Master is down, the Monitor will continue working.
You can use the Filter button in the subheader and the search field to filter the list of promises.
One common use case for the filter is to filter for failing Promises by filtering for the status field with exact match
This helps to keeping track of what to fix only.
Head back to the SlapOS Dashboard to see the different ways to accessing the monitor.
On the map displaying your sites (how to classify computers in a network), click on the small screen icon next to the site name (next to FIRST-SITE on the screenshot).
This will list all promises for software instances deployed on this computer. In the example, the computer is the COMP-0 (SlapOS Architecture) machine which runs an instance of the Re6st Registry for connecting all nodes in a network, the Frontend (Apache) for managing access between nodes and the monitor as well as the Frontend Slave to provide a user-friendly url to the SlapOS Master Dashboard. The status of all three instances can be monitored here.
Head back to the SlapOS Master Dashboard
In the side menu, click on Services to access all services on your SlapOS Network. Click on one of the Instances buttons on a service.
This will show the list of Hosting Subscriptions of this service (a Hosting Subscription is the instantiation of an installed software on a computer partition of a SlapOS node) along with their status.
Head back to the SlapOS Master Dashboard.
In the side menu, click on Servers to access all services on your SlapOS network. Click on one the Computers without any partitions (instances).
If the server is still "empty" (no instances of software have been installed yet), the monitor will not report anything.
This section will show how the monitor can be used to analyse data collected from a SlapOS network.
Stay in the Monitor and click Software Instances to access the list of all instances in the network. A software instance (or hosting subscription) is one instantiated and configured instance of a software available on the SlapOS Master and installed on a computer).
Click on any of the available instances
The detailed view of an instance will provide configuration and promise status information for this instance. All promises are listed in the bottom table, the global promise status is shown on top.
Click on Instance Promise Status (the title of the table at the bottom).
This is the overview of the history of promise failures (similar to or basis of the graph displayed on the previous menu.
Go back to the software instance (clicking on the header). Then click on Processes in the subheader.
This will show details on this specific Promise and the processes it contains.
Click on "Resources" in the subheader.
This will show details on the resource consumption.
You can switch back to the processes by clicking Processes in the subheader, then click in the top navigation to access the main instance view again.
Click on Access Private Files.
This allows to access the private files of this computer partition.
Click on log to continue
This will open the folder of log files. Open one of the files.
This way allows to easily monitor and dig down into log files of a specific service in case of a failing Promise for example.