Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

bash script check if enough available disk space

FREE=`df -k --output=avail "$PWD" | tail -n1`   # df -k not df -h
if [[ $FREE -lt 10485760 ]]; then               # 10G = 10*1024*1024k
     # less than 10GBs free!
fi;
Comment

PREVIOUS NEXT
Code Example
Shell :: docker remove all image 
Shell :: how to update all packages debian 
Shell :: how to close sockets ubuntu 
Shell :: kill port in windows 
Shell :: install drush 
Shell :: journalctl clear logs 
Shell :: no build file in linux headers 
Shell :: kivy install windows 
Shell :: albert for ubuntu 
Shell :: -bash: : Permission denied 
Shell :: ubuntu empty swap 
Shell :: git new repo instructions 
Shell :: delete all files in a folder in ubuntu 
Shell :: android turn off emulator 
Shell :: github epitech 
Shell :: windows services list 
Shell :: how to check used ports linux 
Shell :: git init remoce 
Shell :: generate pgp key linux 
Shell :: QNAP NAS crontab reset 
Shell :: install all pack kubectl kubens kubectx 
Shell :: yandex browser not playing videos 
Shell :: bash time execution 
Shell :: linux rename command incremental 
Shell :: install free dbeaver ubuntu 16.04 
Shell :: archlinux install chrome 
Shell :: tar gz 
Shell :: ubuntu 22 install gstreamer0.10-plugins-bad 
Shell :: xlsx Module ../../xlsx/types has no exported member IProperties. Did you mean Properties? 
Shell :: brew stop redis 
ADD CONTENT
Topic
Content
Source link
Name
3+7 =