Fedora Linux Support Community & Resources Center
Old 8th December 2012, 08:32 PM
oystercatcher Offline
Registered User
Join Date: Jul 2004
Posts: 285
postgres logfile

I have installed postgres on f18 x86_64 with the following packages

rpm -qa | grep postgres

These are the instructions I could find to setup and start postgres

su -
cd /usr/lib64/pgsql
su postgres

$ initdb -D /var/lib/pgsql/data
$ pg_ctl -D /var/lib/pgsql/data -l logfile start

the last command fails with the following message

bash-4.2$ pg_ctl -D /var/lib/pgsql/data -l logfile start
server starting
sh: logfile: Permission denied
Old 8th December 2012, 08:48 PM
roelj Offline
Registered User
Join Date: Jun 2009
Location: Netherlands
Age: 24
Posts: 290
Re: postgres logfile

It looks like the user postgres cannot write a file to the directory it is in.

Do this after "su postgres" to get the directory:
And if you want it to be writable for postgres, you can do:
chown postgres:postgres -R <directory output of the pwd command>
Old 10th December 2012, 03:42 AM
AdamW Offline
Fedora QA Community Monkey
Join Date: Dec 2008
Location: Vancouver, BC
Posts: 4,273
Re: postgres logfile

I'm no postgres expert, but in general, when using distro packages, you wouldn't expect to be running daemons manually like that. I'd expect something more like 'systemctl enable postgres.service' , 'systemctl start postgres.service' or something like that. Did you look for *fedora* documentation?
Adam Williamson | awilliam AT redhat DOT com
Fedora QA Community Monkey
IRC: adamw | Twitter: AdamW_Fedora | identi.ca: adamwfedora
Old 10th December 2012, 11:58 AM
ptuk Offline
Registered User
Join Date: Nov 2005
Posts: 80
Re: postgres logfile

What I do is (as root)

systemctl enable postgresql.service
postgresql-setup initdb
systemctl start postgresql.service
Old 10th December 2012, 04:44 PM
oystercatcher Offline
Registered User
Join Date: Jul 2004
Posts: 285
Re: postgres logfile

thanks ptuk, those instructions work

I found some of the details in the f16 release notes

logfile, postgres

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
pam_unix in logfile jkmartha Using Fedora 1 4th May 2005 09:15 AM

Current GMT-time: 14:06 (Sunday, 29-11-2015)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat