LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 12-16-2004, 09:57 AM   #1
mikeyt_333
Member
 
Registered: Jun 2001
Location: Up in the clouds
Distribution: Fedora et al.
Posts: 353

Rep: Reputation: 30
Log file permissions


I'm installing postgres, and I've set it up to run as user nobody. I chose this because most of my other services run as nobody. How can I grant proper access to the log files to allow writing to the log files by user nobody, but not modification of the log files. I looked at the /var/log structure, and everything is owned by root exclusively, yet everything still logs just fine. I get a permission denied error when I try to start postgres using /var/log as a logging location.

Thanks!
Mike.
 
Old 12-16-2004, 10:45 AM   #2
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,994

Rep: Reputation: 76
Re: Log file permissions

Quote:
Originally posted by mikeyt_333
I looked at the /var/log structure, and everything is owned by root exclusively, yet everything still logs just fine.
This is because it's root that's doing the logging, probably via the syslog daemon.

The most secure way of doing logging is to set up postgres to log to a syslog facility, then set up syslog to log to an appropriate file.
 
Old 12-16-2004, 11:15 AM   #3
mikeyt_333
Member
 
Registered: Jun 2001
Location: Up in the clouds
Distribution: Fedora et al.
Posts: 353

Original Poster
Rep: Reputation: 30
dur, I should have thought of that. Thanks!

Mike.
 
  


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
[SOLVED] Apache log directory permissions gypsy_rabbi Linux - Security 2 10-09-2004 06:31 PM
Log permissions AMMullan Linux - Security 3 08-12-2004 04:10 AM
How to control log file size in /var/log? yan Linux - General 2 10-13-2003 05:00 PM
what log file generator that support squid log? heero82 Linux - Software 2 07-11-2003 08:52 PM
iptables, changing log file from /var/log/messages acid2000 Linux - Networking 3 03-11-2003 08:38 PM

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

All times are GMT -5. The time now is 04:44 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