-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQE+38vx3VVncqMjOZsRAgNbAJ9bSnd8ZtWGfteWEa5I5HWijc6k1QCfbi2p CtNhAj3ELXwh+Sr3XNXSVew= =HN70 -----END PGP SIGNATURE-----
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
Umm I'm guessing rm -rf /PATH/TO/DOWNLOAD/DIRECTORY/* might do the trick.
DB Troll wrote:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer. -- Computers are useless. They can only give you answers. Pablo Picasso
On Sun, 08 Jun 2003 16:22:00 +1000 Basil Chupin <blchupin@tpg.com.au> wrote:
DB Troll wrote:
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer.
There is a setting in yast2 somewhere for "max days in temp", but honestly I can't find it in yast2. I delete everything out of my temp directory evertime I shut the machine down, of course I just have a desktop dialout. You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################ #or if you never reboot........you can delete files older than a certain time ############################# #!/usr/bin/perl # For each file in the folder.. while(</temp/*>) { # If the file is not a directory, and is older than 45 minutes, delete it if ((!-d $_) && (-M $_ > .03124)) { unlink $_; } } ############################## -- use Perl; #powerful programmable prestidigitation
In SuSE 8.0 there is a script in /etc/cron.daily called 'suse.de-clean-tmp' This script is called by the 'cron' or anacron daemon. The exact actions are set in the file /etc/sysconfig/cron. When booting, arrange for the cron and/or anacron daemons to be launched - use the runlevel editor - The file /etc/crontab gives the timings - for details see man cron and man -S5 crontab. I use it to keep my /tmp directory in order. I am sorry to refer you to the command line. I only use GUIs if I have to. Hope this helps Basil Fowler On Sunday 08 Jun 2003 11:47, zentara wrote:
On Sun, 08 Jun 2003 16:22:00 +1000 Basil Chupin <blchupin@tpg.com.au> wrote:
DB Troll wrote:
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer.
There is a setting in yast2 somewhere for "max days in temp", but honestly I can't find it in yast2.
I delete everything out of my temp directory evertime I shut the machine down, of course I just have a desktop dialout.
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
#or if you never reboot........you can delete files older than a certain time ############################# #!/usr/bin/perl # For each file in the folder.. while(</temp/*>) { # If the file is not a directory, and is older than 45 minutes, delete it if ((!-d $_) && (-M $_ > .03124)) { unlink $_; } } ##############################
-- use Perl; #powerful programmable prestidigitation
-- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com
Yast2 file cleanup is in yast2/system/editor for (/etc/sysconfig files) system/cron. You can adjust days, directory etc... On Sun, 2003-06-08 at 07:35, Basil Fowler wrote:
In SuSE 8.0 there is a script in /etc/cron.daily called 'suse.de-clean-tmp' This script is called by the 'cron' or anacron daemon. The exact actions are set in the file /etc/sysconfig/cron.
When booting, arrange for the cron and/or anacron daemons to be launched - use the runlevel editor -
The file /etc/crontab gives the timings - for details see man cron and man -S5 crontab.
I use it to keep my /tmp directory in order.
I am sorry to refer you to the command line. I only use GUIs if I have to.
Hope this helps
Basil Fowler
On Sunday 08 Jun 2003 11:47, zentara wrote:
On Sun, 08 Jun 2003 16:22:00 +1000 Basil Chupin <blchupin@tpg.com.au> wrote:
DB Troll wrote:
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer.
There is a setting in yast2 somewhere for "max days in temp", but honestly I can't find it in yast2.
I delete everything out of my temp directory evertime I shut the machine down, of course I just have a desktop dialout.
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
#or if you never reboot........you can delete files older than a certain time ############################# #!/usr/bin/perl # For each file in the folder.. while(</temp/*>) { # If the file is not a directory, and is older than 45 minutes, delete it if ((!-d $_) && (-M $_ > .03124)) { unlink $_; } } ##############################
-- use Perl; #powerful programmable prestidigitation
-- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Robert Schwedler wrote:
Yast2 file cleanup is in yast2/system/editor for (/etc/sysconfig files) system/cron. You can adjust days, directory etc...
On Sun, 2003-06-08 at 07:35, Basil Fowler wrote:
In SuSE 8.0 there is a script in /etc/cron.daily called 'suse.de-clean-tmp' This script is called by the 'cron' or anacron daemon. The exact actions are set in the file /etc/sysconfig/cron.
When booting, arrange for the cron and/or anacron daemons to be launched - use the runlevel editor -
The file /etc/crontab gives the timings - for details see man cron and man -S5 crontab.
I use it to keep my /tmp directory in order.
I am sorry to refer you to the command line. I only use GUIs if I have to.
Hope this helps
Basil Fowler
On Sunday 08 Jun 2003 11:47, zentara wrote:
On Sun, 08 Jun 2003 16:22:00 +1000 Basil Chupin <blchupin@tpg.com.au> wrote:
DB Troll wrote:
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer.
There is a setting in yast2 somewhere for "max days in temp", but honestly I can't find it in yast2.
I delete everything out of my temp directory evertime I shut the machine
down,
of course I just have a desktop dialout.
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
#or if you never reboot........you can delete files older than a certain
time
############################# #!/usr/bin/perl # For each file in the folder.. while(</temp/*>) { # If the file is not a directory, and is older than 45 minutes,
delete it
if ((!-d $_) && (-M $_ > .03124)) { unlink $_; } } ##############################
-- use Perl; #powerful programmable prestidigitation
-- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com
Thanks to all who replied, this is what I was looking for. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQE+5BaB3VVncqMjOZsRAjNzAJ42F22MlgiOelGeYTa9Q8g1p9p+CACeN0ei G8YpyNN08PVGciGDOxw/XOc= =kGCt -----END PGP SIGNATURE-----
On Mon, Jun 09, 2003 at 12:09:08AM -0500, DB Troll wrote: **many layers of quotes later someone wrote**
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
But won't the line rm -r /tmp/.* also recursively move to .. and then start deleting files from root level?? Happened to me one time when I was trying to backup the rc files in my home directory: I did a recursive copy of ~/.* rather than ~/.[a-bA-B]* and copied a whole disk. Henry Harpending
On Sun, 8 Jun 2003 23:31:06 -0600 Henry Harpending <harpend@xmission.com> wrote:
On Mon, Jun 09, 2003 at 12:09:08AM -0500, DB Troll wrote:
**many layers of quotes later someone wrote**
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
But won't the line
rm -r /tmp/.*
also recursively move to .. and then start deleting files from root level??
It dosn't for me, but I can see why you ask. I don't think * matches . or .., otherwise you would always get infinite looping on . -- use Perl; #powerful programmable prestidigitation
Basil Fowler wrote:
In SuSE 8.0 there is a script in /etc/cron.daily called 'suse.de-clean-tmp' This script is called by the 'cron' or anacron daemon. The exact actions are set in the file /etc/sysconfig/cron.
When booting, arrange for the cron and/or anacron daemons to be launched - use the runlevel editor -
The file /etc/crontab gives the timings - for details see man cron and man -S5 crontab.
I use it to keep my /tmp directory in order.
I am sorry to refer you to the command line. I only use GUIs if I have to.
Hope this helps
Basil Fowler
On Sunday 08 Jun 2003 11:47, zentara wrote:
On Sun, 08 Jun 2003 16:22:00 +1000 Basil Chupin <blchupin@tpg.com.au> wrote:
DB Troll wrote:
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer.
There is a setting in yast2 somewhere for "max days in temp", but honestly I can't find it in yast2.
I delete everything out of my temp directory evertime I shut the machine
down,
of course I just have a desktop dialout.
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
#or if you never reboot........you can delete files older than a certain
time
############################# #!/usr/bin/perl # For each file in the folder.. while(</temp/*>) { # If the file is not a directory, and is older than 45 minutes,
delete it
if ((!-d $_) && (-M $_ > .03124)) { unlink $_; } } ##############################
-- use Perl; #powerful programmable prestidigitation
-- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com
Thank you for this information. I'll now go looking into the control files you mention.
-- Computers are useless. They can only give you answers. Pablo Picasso
zentara wrote:
On Sun, 08 Jun 2003 16:22:00 +1000 Basil Chupin <blchupin@tpg.com.au> wrote:
DB Troll wrote:
What is the best way to go about cleaning up the hard drive af no longer needed files and directory left over from various downloads etc. My temp directory alone is almost 400mb. TIA
I, too, am interested in knowing the best way (specifically, which files can be deleted) so would appreciate someone who knows the answer responding to the request above -- or at least providing the place to go to to find the answer.
There is a setting in yast2 somewhere for "max days in temp", but honestly I can't find it in yast2.
I delete everything out of my temp directory evertime I shut the machine down, of course I just have a desktop dialout.
You can put this in halt.local ############################ #!/bin/sh rm -r /tmp/.* rm -r /tmp/* rm -r /var/tmp/.* rm -r /var/tmp/* ############################
#or if you never reboot........you can delete files older than a certain time ############################# #!/usr/bin/perl # For each file in the folder.. while(</temp/*>) { # If the file is not a directory, and is older than 45 minutes, delete it if ((!-d $_) && (-M $_ > .03124)) { unlink $_; } } ##############################
Thank you for this. But aren't there any other files, not in the temp directory, which need deleting? For example, in Windows log files, amongst others, are candidates for regular deletion. BTW, look in Yast2 Control Centre>System>Editor for /etc/sysconfig Files>System>Cron for max_days_in_temp. -- Computers are useless. They can only give you answers. Pablo Picasso
participants (7)
-
Basil Chupin
-
Basil Fowler
-
DB Troll
-
Henry Harpending
-
jrn@oregonhanggliding.com
-
Robert Schwedler
-
zentara