Skip to content

Instantly share code, notes, and snippets.

@vladpurga
Created July 16, 2019 14:37
Show Gist options
  • Save vladpurga/2ce4106f465e6e94407ee604d2c372cc to your computer and use it in GitHub Desktop.
Save vladpurga/2ce4106f465e6e94407ee604d2c372cc to your computer and use it in GitHub Desktop.
[tune2fs space reserved]
ssh -t host "sudo tune2fs -l /dev/sdb1 | grep -i 'block count' | cut -d':' -f2 | tr -d ' ' | awk 'BEGIN {FS=\"\n\"; RS=\"\"} {print \"/dev/sdb1 space reserved: \"\$2/\$1*100\"%\"}'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment