LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-16-2010, 02:35 PM   #1
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Rep: Reputation: 15
/var/log directory problems


Hello. I have a server running CentOS 5.2 Recently Apache was unable to start because it could not find the error_log file in the /var/log dir.
After investigating I've found that the log directory does not appear to be a directory anymore. It lists at the bottom of the lists of directories in /var as
?log
When I try to chmod/chown it, it wont let me. The size is 32823K. It's MTime date is Jan 25, 1971.

What the heck is the deal with that? I really would like to restore it to it's original state, but don't see any other way other than a complete reinstall of Linux.

It's current permissions are
set user ID on execution
set group ID on execution
sticky bit
read by owner
write by others
execute/search by others

It's owned by Unknown user Unknown Group.
 
Old 03-16-2010, 02:56 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
Just delete it, if you can, and create a new one. a full fsck of that partition would be a wise move too.
 
Old 03-16-2010, 03:00 PM   #3
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
Thanks for the quick response. Can not delete file. Operation not permitted. I am logged in as root.
Can't run fsck on a mounted file system or it could result in damage.
 
Old 03-16-2010, 03:42 PM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
well reboot the system and do it then using a live CD if /var is also on /.
 
Old 03-16-2010, 04:04 PM   #5
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
No go. Wont boot into single user mode from grub. wont boot into single user mode from CD. linux rescue does not let me fsck /dev/sda5 either. I give up. Time to install windows I guess.
 
Old 03-16-2010, 05:37 PM   #6
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
You give up fast. If you change your mind then you need to expand on "linux rescue does not let me fsck /dev/sda5 either" in order to receive useful answers.
 
Old 03-16-2010, 05:47 PM   #7
areamike
LQ Newbie
 
Registered: Nov 2004
Location: CornFields of Indiana
Distribution: RedHat/CentOS
Posts: 24

Original Poster
Rep: Reputation: 15
I didn't give up fast. I had been working on this server for days prior to posting here.

Thanks for the responses. Issue resolved.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Logging to secure directory instead of /var/log... b10m3ch4 Linux - Server 2 12-16-2009 11:04 PM
Can Samhain log my entries in /var/log/secure and /var/log/mesage to a central server abefroman Linux - Software 2 04-13-2008 04:13 PM
How to create Log messages in /var/log directory ratul_11 Linux - Server 4 03-12-2008 01:23 AM
My /var/log/ directory contents dissapeared! guarriman Linux - Security 3 01-05-2008 01:01 PM
deleted my /var/log directory TuxLives Linux - Distributions 2 05-07-2007 09:02 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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

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