基础测试工具:LookingGlass

LookingGlasss 是一款 web 化的测试工具,可以测试常见的 ping、traceroutemtr等命令,Vultr 等很多提供商也有安装,供大家在购买前进行一些测试。

官网:https://github.com/telephone/LookingGlass

安装前的准备

  • 主机环境需要 PHP 5 及以上;
  • 需要 shell 运行权限;
  • 主机的一些情况,比如 IP 地址,用户和组;

安装步骤

1、下载最新版的 LookingGlass

wget https://github.com/telephone/LookingGlass/archive/v1.3.0.tar.gz

2、解压到当前目录

tar -xzvf v1.3.0.tar.gz --strip-components 1

3、进入 LookingGlass 目录,运行 configure.sh

cd LookingGlass
bash configure.sh

4、根据 configure.sh 的提示,一步一步安装。

安装完成之后,会把配置文件写到 Config.php 文件中,如果以后有更改,可以直接修改。

安装的过程还不算特别复杂,但是由于代码已经7年没维护了,如果使用 PHP 7 运行到时候会提示错误:

Fatal error: Uncaught Error: Function name must be a string in /ajax.php:44 Stack trace: #0 {main} thrown in /ajax.php on line 44

解决的办法很简单,把 ajax.php 文件中第44行替换成如下:

$output = $lg->{$_GET['cmd']}($_GET['host']);

扩展阅读:

同类的测试工具:besttraceMTR

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>