Skip to content

Instantly share code, notes, and snippets.

@jonbrouse
Last active May 17, 2017 23:34
Show Gist options
  • Save jonbrouse/3dd74183507b149249c578fbb2308afb to your computer and use it in GitHub Desktop.
Save jonbrouse/3dd74183507b149249c578fbb2308afb to your computer and use it in GitHub Desktop.
def disk_usage():
cmd = "df -h | grep /mnt/log-storage"
df = subprocess.Popen(cmd,shell=True,stdout=subprocess.PIPE,stderr=subprocess.STDOUT)
output = df.communicate()[0]
print output
disk_usage()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment