Jump to content

Recommended Posts

Guest kunalks
Posted

Hello

I have on equestion that i want to check the disk space of mounted drive

 

df -h /path to drive and then i want to write a script which will genrate a messsage if drive space will be above 80% .

 

means

script how i can make if condition which for drive space .

 

if (df -h /path to drive <= 80 %); then

echo "it has only 20 % left"

else

null

fi

can some one help me with this ?

 

 

thanks in advanced

 

Continue reading...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...