mirror of
https://github.com/teddysun/across.git
synced 2025-01-18 22:09:35 +08:00
Update bench.sh (#101)
This commit is contained in:
parent
65b704bf8a
commit
e8b49cae14
10
bench.sh
10
bench.sh
@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Description: Auto test download & I/O speed script
|
||||
# Description: A Bench Script by Teddysun
|
||||
#
|
||||
# Copyright (C) 2015 - 2022 Teddysun <i@teddysun.com>
|
||||
# Thanks: LookBack <admin@dwhd.org>
|
||||
@ -144,6 +144,8 @@ check_virt(){
|
||||
virt="KVM"
|
||||
elif [[ "${virtualx}" == *"VMware Virtual Platform"* ]]; then
|
||||
virt="VMware"
|
||||
elif [[ "${sys_product}" == *"VMware Virtual Platform"* ]]; then
|
||||
virt="VMware"
|
||||
elif [[ "${virtualx}" == *"Parallels Software International"* ]]; then
|
||||
virt="Parallels"
|
||||
elif [[ "${virtualx}" == *VirtualBox* ]]; then
|
||||
@ -221,11 +223,12 @@ install_speedtest() {
|
||||
mkdir -p speedtest-cli && tar zxf speedtest.tgz -C ./speedtest-cli && chmod +x ./speedtest-cli/speedtest
|
||||
rm -f speedtest.tgz
|
||||
fi
|
||||
printf "%-18s%-18s%-20s%-12s\n" " Node Name" "Upload Speed" "Download Speed" "Latency"
|
||||
}
|
||||
|
||||
print_intro() {
|
||||
echo "-------------------- A Bench.sh Script By Teddysun -------------------"
|
||||
echo " Version : $(_green v2022-02-22)"
|
||||
echo " Version : $(_green v2022-06-01)"
|
||||
echo " Usage : $(_red "wget -qO- bench.sh | bash")"
|
||||
}
|
||||
|
||||
@ -358,8 +361,7 @@ ipv4_info
|
||||
next
|
||||
print_io_test
|
||||
next
|
||||
install_speedtest && printf "%-18s%-18s%-20s%-12s\n" " Node Name" "Upload Speed" "Download Speed" "Latency"
|
||||
speed && rm -fr speedtest-cli
|
||||
install_speedtest && speed && rm -fr speedtest-cli
|
||||
next
|
||||
print_end_time
|
||||
next
|
||||
|
Loading…
x
Reference in New Issue
Block a user