Results 1 to 10 of 13
I accidentally did "rm -rf /var/logs/*" well I wonder now.
Am I screwed and will i never see a log again?
Or, well how to fix? Since I kinda want ...
- 01-21-2008 #1
- 01-21-2008 #2
AFAIK, Its not possible to recover logs now.
It is amazing what you can accomplish if you do not care who gets the credit.
New Users: Read This First
- 01-21-2008 #3
- 01-21-2008 #4
You could try recreating the log files e.g.
You will have to find out which logs postfix and dovecot create and then recreate those log files using touch. Another log to recreate would be /var/log/messages because this is the file used by dmesg.Code:cd /var/log touch mail mail.err mail.info mail.warn
- 01-21-2008 #5forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 17,784
Yeah, I think daark.child's recommendation might work, at least for some files. I was thinking that most of the log files would rebuild themselves if deleted.
Have you tried rebooting to see if any would recreate themselves?oz
→ new users: read this first
→ no private messages requesting computer support - post them on the forums!
- 01-21-2008 #6
AFAIK, log files recreate itself. I could be wrong though.
It is amazing what you can accomplish if you do not care who gets the credit.
New Users: Read This First
- 01-21-2008 #7
- 01-21-2008 #8Yes, you can use it for that, but its useful for creating empty files as well. Anyway, I'm glad you managed to resolve the problem. I wasn't sure if all of the logs would be recreated after rebooting.I thought you could use it to change the time created in the file.
- 01-22-2008 #9
Well I thought, no problem they will make them selfs again.
But that just didnt happen.. :o
So, I kinda paniced Since a Web.MailServer without logs is kinda a pain. (Esspecialy when you never had setup a Mail server)
Anyhow, how comes that touch can make files? As the function of the tool is to change time?
Cheers,
Robin
- 01-22-2008 #10
On Linux systems, the manual for touch does not state the file creation capabilities, but I think the info page does. On BSD systems, the manual clearly states that touch modifies file access times as well as create empty files.


Reply With Quote
