mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-11-21 23:43:25 +01:00
Renamed to ping-internet.ps1
This commit is contained in:
parent
53381691df
commit
34b569cbc7
@ -22,7 +22,7 @@ Write-Host "`n N E T W O R K" -foregroundColor green
|
|||||||
& "$PSScriptRoot/ping-local-devices.ps1"
|
& "$PSScriptRoot/ping-local-devices.ps1"
|
||||||
& "$PSScriptRoot/check-vpn.ps1"
|
& "$PSScriptRoot/check-vpn.ps1"
|
||||||
& "$PSScriptRoot/list-internet-ip.ps1"
|
& "$PSScriptRoot/list-internet-ip.ps1"
|
||||||
& "$PSScriptRoot/ping-remote-hosts.ps1"
|
& "$PSScriptRoot/ping-internet.ps1"
|
||||||
& "$PSScriptRoot/check-dns.ps1"
|
& "$PSScriptRoot/check-dns.ps1"
|
||||||
& "$PSScriptRoot/list-ssh-key.ps1"
|
& "$PSScriptRoot/list-ssh-key.ps1"
|
||||||
exit 0 # success
|
exit 0 # success
|
||||||
|
@ -6,8 +6,8 @@
|
|||||||
.PARAMETER hosts
|
.PARAMETER hosts
|
||||||
Specifies the hosts to ping, seperated by commata (10 Internet servers by default)
|
Specifies the hosts to ping, seperated by commata (10 Internet servers by default)
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./ping-remote-hosts.ps1
|
PS> ./ping-internet.ps1
|
||||||
✅ Internet latency 12ms (9...18ms range)
|
✅ Internet ping latency 12ms (9...18ms range)
|
||||||
.LINK
|
.LINK
|
||||||
https://github.com/fleschutz/PowerShell
|
https://github.com/fleschutz/PowerShell
|
||||||
.NOTES
|
.NOTES
|
||||||
@ -36,7 +36,7 @@ try {
|
|||||||
Write-Host "⚠️ Internet offline (100% ping loss)"
|
Write-Host "⚠️ Internet offline (100% ping loss)"
|
||||||
} elseif ($loss -eq 0) {
|
} elseif ($loss -eq 0) {
|
||||||
$avg /= $success
|
$avg /= $success
|
||||||
Write-Host "✅ Internet latency $($avg)ms ($($min)...$($max)ms range)"
|
Write-Host "✅ Internet ping latency $($avg)ms ($($min)...$($max)ms range)"
|
||||||
} else {
|
} else {
|
||||||
$avg /= $success
|
$avg /= $success
|
||||||
Write-Host "✅ Online with $loss/$total ping loss and $($min)...$($max)ms latency - $($avg)ms average"
|
Write-Host "✅ Online with $loss/$total ping loss and $($min)...$($max)ms latency - $($avg)ms average"
|
Loading…
Reference in New Issue
Block a user