mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-03-26 14:26:10 +01:00
Update check-swap-space.ps1
This commit is contained in:
parent
51487dbaec
commit
ba00df2878
@ -7,7 +7,7 @@
|
||||
Specifies the minimum level (10 GB by default)
|
||||
.EXAMPLE
|
||||
PS> ./check-swap-space.ps1
|
||||
✅ Swap space uses 63GB of 1856GB
|
||||
✅ Swap space uses 122MB (10%) of 1GB
|
||||
.LINK
|
||||
https://github.com/fleschutz/PowerShell
|
||||
.NOTES
|
||||
@ -53,7 +53,7 @@ try {
|
||||
Write-Output "✅ Swap space with $(MB2String $Total) reserved"
|
||||
} elseif ($Used -lt $Free) {
|
||||
[int]$Percent = ($Used * 100) / $Total
|
||||
Write-Output "✅ Swap space uses $(MB2String $Used) or $($Percent)% of $(MB2String $Total)"
|
||||
Write-Output "✅ Swap space uses $(MB2String $Used) ($($Percent)%) of $(MB2String $Total)"
|
||||
} else {
|
||||
Write-Output "✅ Swap space has $(MB2String $Free) of $(MB2String $Total) free"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user