File Deletion Script
Hello all, long time since i have posted here hope everyone is well;
I'm wanting to make a little script that can be run as a cron job, the scripts should;
mount my organisations file server;
scan for "contraband" i.e. exe's mp3's
delete the files
Can anyone point me in the right direction for the commands i would need to use for finding and then deleting.
I will admit i haven't invested much time into this yes, am just under a bit of pressure and any help would be greatly appreciated.
Thanks in advance.
Sorry i should add;
I know how to mount the fileservers share, and i know how to search for the files i need with the find command,
i really need help with passing the output to the delete command
Hm, maybe as an example a simple
hi thanks for your help;
i came to a similar conclusion myself, but using the xargs command with the -0 option.
find /server1/home -name "*.mp3" | xargs -0 rm -f
|All times are GMT -5. The time now is 03:22 PM.|