interesting problem ( sh script and logs )
Hi GuysI am running plesk and want to check some logfiles as one of my users is killing bandwidth to a rediculous amount, now plesks stats are no good and the virtual domain name setup on plesk means that the main apache access_log file has very little info to tell me, so what i am trying to do is to look at all the log files for each virtual domain name and then check to see which log file has grown the fastest in say the past 30mins or has say grown by Xmb in 30mins, trying to use comman line to find and pipe the results is proving to complex, so an sh cript that could locate all access_log files and delete them, then when run in say 10min can check the size of each log file and display ones that are bigger than say 10Mb this way i can see which file has grown by this amount and then i can analyse a handfull of them, this is a drastic solution as in involves deleting the access_files, but a script that would check files sizes, write them to a file and then do a comparative search a few minutes later will take too much time to write....
Does any one have any suggestions on how i should write this shell script...
any help will be greatly appreciated