WEB service monitoring Statping

Reproduced, please indicate the source ^ _ ^
Original starting in: www.zhangruibin.com
This article comes from: RebornChang's blog

Statping WEB Service Monitoring

There are mentioned in the previous article, use the linux shell script monitoring service, and send the message to the specified mailbox when the hang of service, links to articles .
At that time I was thinking, but there is no such a thing like that can interface You can see real-time operating conditions of each system, graphical interface, at a glance.
So some people say, and one by one the system access on the line chanting. Indeed that is the safest, but when your hands dozens of items one by one, then you go and get it, too complicated to understand what is meant by Statping.

What is Statping

To borrow a moving map Statping GitHub repository to see an effect:

See, the interface is simple and elegant. what? Interface style do not like? You can change the theme.

都能在什么环境上运行?
看官方介绍:
No Requirements
Statping is built in Go Language so all you need is the precompile binary based on your operating system. You won’t need to install anything extra once you have the Statping binary installed. You can even run Statping on a Raspberry Pi.

Simply put, the following picture:

I do not want to install on the server? Can be downloaded APP seal the deal.

Operating trouble? No trouble, trouble, then bloggers will engage in a kind of lazy.

看了上面的效果,是不是想来一把试试?看下面。

Linux安装Statping

仓库地址

Statping是开源的,项目托管在GitHub上,仓库地址: https://github.com/hunterlong/statping

linux安装教程:https://github.com/hunterlong/statping/wiki/Linux

就几句英文应该难不倒各位看官,但是对于博主这种能一句话搞定的事绝不说两句话,那就来更简单的,在docker中安装Statping。

没有安装docker的请参考这个链接:docker的安装及简单使用

docker安装Statping

首先运行这句话

docker pull hunterlong/statping

然后运行这句话

docker run -it -d -p 9000:8080 hunterlong/statping

完事。

注意:
1.命令中的8080端口不可改,9000端口,只要不跟本地冲突随意改。
2.博主映射到主机上的端口是9000端口,那一定要开启9000端口的。iptables端口开启的方法参考:https://blog.csdn.net/donglynn/article/details/73530542

Statping的使用

安装配置

经过上面的安装我们访问安装主机的9000端口就可以进入到安装界面了,在安装界面会让你选择数据库,还有主机地址及用户密码。其他的不多说,数据库推荐选择SQLlit。安装配置界面如下图所示:

进入到控制台

填写完成之后点击下一步,就可以进入到监控的demo界面了。进去之后可以看到模拟监控了几个web服务,Google的什么的。那么怎么进入控制台配置自己的呢?
页面滑到最低端,点击: Dashboard就可以跳到登录界面了,输入刚才安装时候配置的账号密码就可以登进去了。

配置想要监控的网站链接

这里博主要监控自己的两个博客,所以,点击Settings配置,配置如下图所示:

值得一提的是,配置的时候注意,在Expected Response (Regex)一栏,写入正常情况下应该返回的东西。比如博主配置的连接访问之后应该返回一个页面,页面包含字段。所以在这一栏填写的就是:。

配置完毕的效果图

直接上图:

Guess you like

Origin blog.csdn.net/m0_37190495/article/details/91975517