Output of the below code includes unmatched date.Please correct it
df -k|awk '$4>50 {print $1, "\t"$4,"\t" $7}'
It gives output less than 50% also.
Output of the below code includes unmatched date.Please correct it
df -k|awk '$4>50 {print $1, "\t"$4,"\t" $7}'
It gives output less than 50% also.
Can you provide us the output of "df -k". I get available space as 4th column and the above code is working fine for me
yes it gives output to me also but it includes 40% used space in output as well for the above while expected is 50%+ only.
If you are sure about 4th field, use the below code
df -k | awk '{split($4, a, "%")} a[1] > 50 {print $1 "\t" $4 "\t" $7}'
If it is 5th field, change $4 to $5 in split function
Try
df -k | awk '$4+0>50{print $1, "\t"$4,"\t" $7}'
thanks all. Last 2 code snippet provided above works . Thanks again.