LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 02-29-2008, 02:37 PM   #1
STARHARVEST
Member
 
Registered: Nov 2005
Location: Russia, republic of Bashkiria
Distribution: Slackware 12.1
Posts: 294

Rep: Reputation: 31
Temporary files.


What is the purpose of /var/log/removed_packages and /var/log/removed_scripts. Can I remove them?
And one more thing - what tmp directories can be cleaned safely?
 
Old 02-29-2008, 03:33 PM   #2
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 564

Rep: Reputation: Disabled
Quote:
What is the purpose of /var/log/removed_packages and /var/log/removed_scripts. Can I remove them?
I don't know, but if I wanted to experiment, I would move them into another directory & see what happens.
Quote:
And one more thing - what tmp directories can be cleaned safely?
I currently run "rm -rf /tmp/*" in my rc.local.shutdown file. I used to do the same for /var/tmp, but read somewhere that that was not a good idea, so removed it, but I never had any problems with it.
Regards,
Bill
 
Old 02-29-2008, 04:25 PM   #3
Poetics
Senior Member
 
Registered: Jun 2003
Location: California
Distribution: Slackware
Posts: 1,181

Rep: Reputation: 49
Here in the office we have a script that runs every evening to see what files in /tmp haven't been touched in the past month. If there are any such files, they are deleted.

Fairly easy to set up with cron and find, but a one-month rolling timeline has been my general ideology for some time.
 
Old 02-29-2008, 09:26 PM   #4
chess
Member
 
Registered: Mar 2002
Location: 127.0.0.1
Distribution: Slackware and OpenBSD
Posts: 740

Rep: Reputation: 190Reputation: 190
Quote:
Originally Posted by Poetics View Post
Here in the office we have a script that runs every evening to see what files in /tmp haven't been touched in the past month. If there are any such files, they are deleted.

Fairly easy to set up with cron and find, but a one-month rolling timeline has been my general ideology for some time.
I have done something similar over the years.
 
Old 03-01-2008, 01:32 AM   #5
evilDagmar
Member
 
Registered: Mar 2005
Location: Right behind you.
Distribution: NBG, then randomed.
Posts: 480

Rep: Reputation: 31
Quote:
Originally Posted by TSquaredF View Post
I don't know, but if I wanted to experiment, I would move them into another directory & see what happens.
I currently run "rm -rf /tmp/*" in my rc.local.shutdown file. I used to do the same for /var/tmp, but read somewhere that that was not a good idea, so removed it, but I never had any problems with it.
Someone misinformed you then. Nothing in /tmp or /var is supposed to be required to be preserved between boots. You could clear them both each and every time and everything runtime should still work. I just wouldn't make a habit of wiping out /var entirely (/var/tmp would be fine) because Slackware keeps it's package accounting data in there. Losing it won't break any daemons or anything, but it would effectively break the packaging tool for upgrades or package removals.
 
Old 03-01-2008, 05:29 AM   #6
STARHARVEST
Member
 
Registered: Nov 2005
Location: Russia, republic of Bashkiria
Distribution: Slackware 12.1
Posts: 294

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by evilDagmar View Post
because Slackware keeps it's package accounting data in there. Losing it won't break any daemons or anything, but it would effectively break the packaging tool for upgrades or package removals.
this is what I'm afraid of..=)
 
Old 03-01-2008, 06:36 AM   #7
evilDagmar
Member
 
Registered: Mar 2005
Location: Right behind you.
Distribution: NBG, then randomed.
Posts: 480

Rep: Reputation: 31
Quote:
Originally Posted by STARHARVEST View Post
this is what I'm afraid of..=)
Well again, /var/tmp is fine to empty--that's not where the package inventory information is stored.
 
Old 03-01-2008, 07:09 AM   #8
STARHARVEST
Member
 
Registered: Nov 2005
Location: Russia, republic of Bashkiria
Distribution: Slackware 12.1
Posts: 294

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by evilDagmar View Post
Well again, /var/tmp is fine to empty--that's not where the package inventory information is stored.
ops! I've got it now, thanks.
 
Old 03-01-2008, 11:45 AM   #9
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 564

Rep: Reputation: Disabled
Per evilDagmar:
Quote:
Someone misinformed you then. Nothing in /tmp or /var is supposed to be required to be preserved between boots. You could clear them both each and every time and everything runtime should still work.
Thanks for the information. As I said above, I read that in a thread somewhere, & I guess one can read almost anything in a thread somewhere, right?
Regards,
Bill
 
Old 03-01-2008, 12:23 PM   #10
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,928

Rep: Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612Reputation: 612
/var/tmp is meant to hold info that should be preserved between boots. This doesn't mean that it should be required, though.
Most of /var is used for logs and lockfiles and shouldn't be completely wiped out -I mean you shouldn't remove the directories and the logfiles should exist, even if they are emptied(truncated) on shutdown.
/tmp can safely be cleaned out, except that there are a few invisible files there which it is convenient to preserve.
 
Old 03-01-2008, 02:30 PM   #11
Woodsman
Senior Member
 
Registered: Oct 2005
Distribution: Slackware 14.1
Posts: 3,482

Rep: Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546Reputation: 546
Quote:
And one more thing - what tmp directories can be cleaned safely?
Perhaps this will help:

Removing Temporary Files and Clutter
 
Old 03-01-2008, 04:46 PM   #12
pbhj
Member
 
Registered: Dec 2002
Location: UK
Distribution: Slackware 12; Ubuntu 7.10
Posts: 358

Rep: Reputation: 32
I did this before and it screwed up KDE. Since then I ran a script (I no longer run Slackware since Jan 2008) to see if the file had been modified in X days and then delete. That caused no problems.

YMMV.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Temporary Files pxumsgdxpcvjm Slackware 6 12-17-2007 01:06 PM
how to use temporary files? nadeemr Linux - Newbie 12 06-15-2007 11:45 AM
Temporary Internet Files?????????? RobTek Linux - Newbie 12 10-25-2004 07:20 PM
crontab & quota files are temporary files? hamish Linux - Software 0 07-10-2004 02:09 PM
Clearing Temporary Files jjorloff1 Red Hat 1 01-25-2004 07:32 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 02:02 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration