VPS 三网测速教程(实验性)
本教程说明如何尝试用实验性脚本 xyz.sh/speedtest-cn 测试电信 / 联通 / 移动节点。从境外经常无法完成国内测速,日常请使用 xyz.sh/speedtest --overseas 或 xyz.sh/all。
$ curl -fsSL xyz.sh/speedtest-cn | bash
说明 · xyz.sh/speedtest-cn · 最后更新:
适用条件
一台可以访问 speedtest.net 的 Linux VPS(x86_64、aarch64、armv7 等),root 不是必须。
测速会消耗流量,单节点大约几百 MB。
步骤
可选:先阅读源码 curl -fsSL xyz.sh/speedtest-cn.sh,并核对 xyz.sh/speedtest-cn.sh.sha256。
先看可用节点:curl -fsSL xyz.sh/speedtest-cn | bash -s -- --list
默认每家运营商测 1–2 个节点:curl -fsSL xyz.sh/speedtest-cn | bash -s -- -y
按地区筛选(east / north / south / west):curl -fsSL xyz.sh/speedtest-cn | bash -s -- --region east -y
只测某些运营商:--carrier ct,cu(ct 电信、cu 联通、cm 移动);测全部节点:--all-nodes;自定义节点:--servers 5396,24447。
如何验证
结束时会打印 “运营商 / 节点 / 下载 / 上传 / 延迟 / 丢包” 表格;失败的节点显示为 skipped。全部节点都失败时退出码为 2。
如何撤销或卸载
以非 root 或拒绝安装运行时,CLI 只放在临时目录,结束即删除。若安装到了 /usr/local/bin/speedtest,可运行 curl -fsSL xyz.sh/speedtest | bash -s -- --uninstall 删除。