unx100
September 30, 2009, 7:36am
1
Hi Friends,
I have an urgent requirement.
I have many files huge in size which has occupied almost the entire disk space. The files are not being moved to the archived folder.
But at present I need to purge those files, new to shell scripting, not sure how to proceed.
Eg.
Directory > /usr/logfiles/
Filenames > a1.log
a2.log
a3.log
a4.log
Please advise.
Thanks
rdcwayx
September 30, 2009, 7:44am
2
use the command: split, rm ??
unx100
September 30, 2009, 7:47am
3
As far as I know, split command will split the file into multiple files.
Here Im faced with a problem there is no disk space at all, even I cant do gzip.
rdcwayx
September 30, 2009, 8:47am
4
cd /usr
tar cvf - logfiles |gzip > /BIGSPACE/logfiles.tar.gz
rm logfiles/*.log