* delete "very" old files
@ 2000-09-27 4:00 Daniel Willems
2000-09-27 4:00 ` Joerg Bruehe
0 siblings, 1 reply; 3+ messages in thread
From: Daniel Willems @ 2000-09-27 4:00 UTC (permalink / raw)
Hello,
Since I'm new to Unix I need some help.
Our application generates temporary files and never deletes them.
This is filling up our disks and them the application crashes.
Therefor I'm looking for a script that deletes the tmp-files which are older
than 1 week.
Thanks
--
*** remove spam twice when replying ***
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: delete "very" old files
2000-09-27 4:00 delete "very" old files Daniel Willems
@ 2000-09-27 4:00 ` Joerg Bruehe
2000-09-28 4:00 ` Joerg Bruehe
0 siblings, 1 reply; 3+ messages in thread
From: Joerg Bruehe @ 2000-09-27 4:00 UTC (permalink / raw)
Hello !
Daniel Willems wrote:
>
> Hello,
>
> Since I'm new to Unix I need some help.
Convince your company you need a course if you are to admin a system -
nobody is a "born admin", whatever marketing claims about "ease of use".
>
> Our application generates temporary files and never deletes them.
No comment - to avoid being sued for insults.
> This is filling up our disks and them the application crashes.
"Works as designed" differs from "Works as intended", obviously.
Also sounds like lack of testing before / at delivery.
>
> Therefor I'm looking for a script that deletes the tmp-files which are older
> than 1 week.
RTFM: shell programming, pipes, builtin "xargs"; "find"
find /where/they/are -type f -name some_pattern_* -mtime +7 | xargs rm
-i
This sure is a Unix FAQ, try "Deja" for more hints or ready solutions.
Keywords might be "cleanup", "temp" "files", "disk full", or similar.
HTH,
Joerg Bruehe
--
Joerg Bruehe, SQL Datenbanksysteme GmbH, Berlin, Germany
(speaking only for himself)
mailto: joerg@sql.de
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: delete "very" old files
2000-09-27 4:00 ` Joerg Bruehe
@ 2000-09-28 4:00 ` Joerg Bruehe
0 siblings, 0 replies; 3+ messages in thread
From: Joerg Bruehe @ 2000-09-28 4:00 UTC (permalink / raw)
Hello again !
Joerg Bruehe ( = I myself ) wrote:
>
> [...]
>
> find /where/they/are -type f -name some_pattern_* -mtime +7 | xargs rm
> -i
... and forgot the quotes around the pattern - please use
find /where/they/are -type f -name 'pattern_*' -mtime +7 | xargs rm -i
Sorry,
Joerg Bruehe
--
Joerg Bruehe, SQL Datenbanksysteme GmbH, Berlin, Germany
(speaking only for himself)
mailto: joerg@sql.de
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2000-09-28 4:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-09-27 4:00 delete "very" old files Daniel Willems
2000-09-27 4:00 ` Joerg Bruehe
2000-09-28 4:00 ` Joerg Bruehe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox