Statping is an open-source monitoring tool that is easy to use and very lightweight. It is a very appealing free alternative to Pingdom, Better Uptime by Better Stack, among other providers' services. It lets you intuitively configure monitors for applications, services, and websites. For example, you will have a control panel for monitoring with a basic HTTP GET request or a POST request with its own JSON to post to the endpoint. You can also monitor other services using TCP and UDP, as well as gRCP or the protocol ICMP.
It includes email notifications through SMTP and integration with Slack, Mattermost, Discord through Incoming Webhook. Simply insert the webhook URL on the statping settings page and enable integration with your favorite messaging application. Whenever a service fails, you will receive a message/alert in the specified channel, and you can also use LINE Notify, Telegram, Twilio, among other solutions.
Additionally, there is a mobile application available for free in the App Store and on Google Play. The application lets you view services, receive notifications when a service is offline, update groups, users, services, messages, and much more. To link it, log in to your statping server and easily connect it to the application by scanning the QR code in the settings.
Installing Snap
On Ubuntu or distributions based on it, Snap comes preinstalled and you can click here to skip installation. However, you can use any distribution from the Linux Images and install it:
Installing Snap:
# apt update && apt upgrade -y && apt install snapd -y
Installing Snap:
# yum upgrade -y && yum install snapd -y
Next, enable snapd and restart the system:
# systemctl enable --now snapd.socket && ln -s /var/lib/snapd/snap /snap && reboot
Once the system has restarted, you can install packages with it and try installing a test package:
# snap install hello-world
The following output will appear when installation is complete:
hello-world 6.4 from Canonical✓ installed
Then try running it:
# hello-world
You should get the following output:
Hello World!
Installing statping
With snapd on the server, simply run the following to perform the statping installation:
# snap install statping-ng
Next, start the service:
# snap start statping-ng
Also enable the service and check its status:
# systemctl enable snap.statping-ng.statping.service && systemctl status snap.statping-ng.statping.service
Then install Certbot to obtain the SSL certificate:
# snap install --classic certbot
If you have not previously installed NGINX and MySQL, install them:
# apt install nginx mysql-server -y
If you have not previously installed NGINX and MySQL, install them:
# yum install nginx mysql-server -y
Then create an NGINX configuration file for the site for statping:
# nano /etc/nginx/sites-enabled/statping
Add the following content (modify the server_name record):
server {
listen 80;
server_name statping.ejemplo.com;
location / {
proxy_pass http://127.0.0.1:8080;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
}
}
Save and exit the editor, then restart NGINX to reload the configuration:
# systemctl restart nginx.service
To obtain and automatically configure the certificate, simply run (modify the example record*):
# certbot --nginx --redirect -d statping.ejemplo.com
*Remember to point the record to the server's IP address.
Then create a database for statping by running the following command:
# mysqladmin -u root --verbose create statping
Next, create a user for the database (replace "contraseña" with the desired password):
# mysql -u root --verbose -e "create user 'statping'@'localhost' identified by 'contraseña';"
Assign it permissions on the database and perform a flush:
# mysql -u root --verbose -e "grant all on statping.* to 'statping'@'localhost' with grant option; flush privileges;"
Also set the time zone in MySQL. For example, UTC:
# mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root mysql && mysql -u root --verbose -e "SET time_zone = '+00:00';"
Finally, access it with a web browser using your record and add the configuration:
Once statping is configured, it will redirect you to the dashboard:
You can log in with the statping user by adding "login" to the end of the URL to configure monitors and notifications.
We hope this article has helped you. If you have any questions about this or any other issue related to your servers on Clouding, write to us at soporte@clouding.io. We're here to help! 😉