

InterviewSolution
Saved Bookmarks
1. |
Solve : FileSystem Monitor Script Issue..Pls Help?? |
Answer» I have a Script that monitors a FileSystem named /Monthly; works MSG=`df - Ik|awk '$6~/Monthly$/{gsub("%"," ");I'm only casually acquainted with awk, but I can certainly see what's going on here. At the highest level, you are storing the OUTPUT of a command into an environment variable named MSG. The back quotes (`` ) run the command and return the text. But I suspect you have not quite correctly copied the command that pipes into awk, that is, "df - Ik". The closest sensible command would be "df -ik", which shows how many inodes, or directory entries, are used up. The $5 part of the awk print command would grab the fifth output COLUMN from df, which is the percentage. As for the change, I think the previous answer was CORRECT, just change the directory. BTW, did you really intend to give your cell phone number to the world? |
|