Send alert if website is down using the Contact ID protocol

In this guide, we explain to you how you can create a solution that will monitor your server and will send an alert in case the server is down. This system will make sure that you have fast reaction to a server error so the recovery will take less time. Reading this article will give you all the information you need when building such system with Contact ID capabilities. Using the Contact ID protocol means that you system will be supported by all security companies central monitoring station. The article is short and is supplemented with screenshots of the process and detailed descriptions of the pictures. First, you will learn how to create a new alarm source and then how to setup a new Contact ID sender. As the last step, you are going to see how to finalize the routing between the alarm source and the sender. The whole tutorial is based on the Ozeki SMS Gateway. It means that you will be working with the excellent and easy to use dashboard of the Ozeki SMS Gateway. You will have no problem with following the steps and recreating them yourself. Now don’t waste any time. Let’s start now!

Send alert if website is down using the Contact ID protocol (Quick commands)

To send alert if website is down using the Contact ID protocol:

  1. Launch Ozeki SMS Gateway
  2. Open Ozeki Alarm System app
  3. Add new Web server down source
  4. Configure the alarm source
  5. Enable Web server down connection
  6. Set up Contact ID sender channel
  7. Configure SIP user account details
  8. Enable Contact ID sender connection
  9. Add new Route to the connection
  10. Check logs and alert if server is down

Send alert if website is down using the Contact ID protocol (Video tutorial)

In this video, you are going to see the process of setting up a Contact ID sending monitoring system using Ozeki Alarm System. The video start with creating a new alarm source and will take you all the way to checking the log for the first Contact ID sending event. You are going to learn how to setup the alarm source, how install a new Contact ID sender and how to create the routing between them. The video is only 2:51 long but it features all the necessary steps you need to take to have a working Contact ID sending alarm system. You are going to use the Ozeki Alarm System meaning that you will have no problem with understanding the dashboard or the control panels of the software.

How monitoring and contact ID sending works using a mobile phone

The system consists of a server, a mobile running the Ozeki alarm system and a Security Monitoring Station. This monitoring setup is working the following way (Figure 1): The Monitoring Mobile sends a download request periodically to your server. If the server does not respond, the Monitoring Mobile will send a Contact ID alert to the Security Monitoring Station that states the problem.

send contact id alert to mobile if website is down
Figure 1 - Send Contact ID alert to mobile if website is down

How monitoring and contact ID sending works using a PC

This following system will monitor your server with periodical download requests and will notify the Security Monitoring Station in case of a server error. The system consists of a server that needs to be monitored, a monitoring PC running the Ozeki Alarm System and a Security Monitoring Station. This system works the following way: The Monitoring PC will try to download data from the server periodically. If it does now succeed, it means that the server is down. In that case, the monitoring PC will send a Contact ID Alert to the Security Monitoring Station.

send contact id alert to pc if website is down
Figure 2 - Send Contact ID alert to PC if website is down

Launch the Ozeki SMS Gateway

As the first step of the process, you need to launch the Ozeki Alarm System application. Start with opening the Ozeki 10 desktop and search for the ‘Alarm system’ icon (Figure 1). Click it to open the alarm system. This application is responsible for managing all your alarm sources and routes them to alarm stations. All the steps that we are going to do will be in this program.

open alarm system application
Figure 3 - Open Alarm System application

Create a new alarm source

Now you need to create a new alarm source. This will act as a supervisor that monitors your server 24/7. To create this, click the ‘Source’ button located on the toolbar of the Ozeki Alarm System (Figure 4). There you will see all the possible alarm sources. Search for the 'IT infrastructure monitoring' section where you will find a ‘Web server offline’ option. Click the blue ‘Install’ button next to the name of the alarm source to start the setup process.

add webserver offline source
Figure 4 - Add Webserver offline source

Configure the alarm source

In the next step, you will configure the alarm source. You need to provide a URL that the system will try to download data from. Type in the URL to the textbox located in the Webserver groupbox. Below it you will find the Downloaded groupbox. There you need to type two texts, that the system will scan for in the response of the webserver. If the first Text to look for is in the response, the server works correctly. If the second Text of error is found, the system know that the webserver is currently offline. Under these settings, you can find a Frequency groupbox where you can set how frequent should the system check the webserver (Figure 5).

configure host
Figure 5 - Configure Host

Turn on the source

Now that you have finished with creating the alarm source, make sure to turn it on. This means that the alarm source will start sending download requests to your server periodically. Use the ‘Connection’ swich button to turn the alarm source on (Figure 6). If it is green, your alarm source is constantly checking your server. You can see more information about the connecting process and the first download request in the ‘Events’ tab.

enable webserver offline source
Figure 6 - Enable Webserver offline source

Install new Contact ID Sender

To setup a new notification channel, open the Channels page. There you will be able to find the install notification channel list. You can see here all the options you can choose to install. In this case, choose the Contact ID sender option (Figure 7). Contact ID is an international set of event codes that monitoring equipment sends to identify an error. This notification channel will send a predefined contact ID to a predefined connection.

install contact id sender
Figure 7 - Install Contact ID sender

Provide the SIP account details

In this step, you need to provide the SIP account details. A SIP account is a set of credentials that allows users to make voice and video calls over the Internet using VoIP technology. Scroll down until you can see textboxes for display name, username, register name, password, domain, port and proxy (Figure 8). If you have provided all the information, click the Ok button to proceed to the next step.

provide sip account details
Figure 8 - Provide SIP account details

Check all the checkboxes for logging

Having log turned on means that all the events that happened on the connection will have a record with details in it. To turn on logging, click the Advanced tab located next to the General tab. You will find the Log level groupbox there. If you check all the checkboxes, your connection will record all the communication event, all the messaging event and even attach them to every message. This way you will know every detail about your connection.

enable logging
Figure 9 - Enable logging

Turn on the Contact ID Sender

The last step of setting up the Contact ID Sender is to turn it on. You can do so using the ‘Connection’ switch button located in the details panel of the newly created sender (Figure 10). If the switch is green, it means that the sender is active and now it can send Contact ID alerts to the monitoring station. You can see the details of the connection process in the ‘Events’ tabe.

register to pbx
Figure 10 - Register to PBX

Create a new Route

Click the Routes button to open the list of current routes. To create a new one click the Create new Route button located next to the Routes title. After clicking it, you will see the settings of the new route on the right-side panel (Figure 11). Here you need to provide the two ends of the connection. In the From textbox, you need to provide the web server checker. In the TO textbox, you need to newly created notification channel. Click the Ok button to proceed.

add new route
Figure 11 - Add new route

Report sent

In the alarm source’s details page you will find a tab called Events. Click it to inspect the log of the source. On Figure 10, you can see that the example source detected that the server is offline (Figure 12). In this case it sends a request to the Contact ID Sender to send the predefined contact ID to the address.

send report when webserver goes offline
Figure 12 - Send report when webserver goes offline

Message sent

In the Contact ID Sender details page you will find an events tab. Click it to see the Events happened on the contact sender notification channel. As you can see on Figure 13, it received a request to send the predefined Contact ID to the address because the server is currently down (Figure 11). In this case, the sender starts the transmission and it delivers the contact ID.

contact id alarm sent
Figure 13 - Contact ID alarm sent

Summary

In this article, we showed you how to setup a Contact ID sending server monitoring system. This solution will make it easier for the monitoring station to supervise the server, which will result in less down-time in case of a server error and an easier recovery after it.

This topic offers you more solutions. You can virtually setup an alarm system for any server or connection in your organization. To learn more about this topic, feel free to visit the Ozeki webpage, where you can find articles about sending e-mails when webserver is down and sending SMS when webserver is down.

Make sure to not stop learning here. Download the Ozeki Alarm System and start developing alarm functionalities right now!