Bug reference: 5430
Logged by: Jamie Strachan
Email address: frost...@yahoo.com
PostgreSQL version: 8.4.3-2PGDG.el4
Operating system: CentOS 4
Description: initdb fails due to permissions of /usr/share/pgsql
Details:
Hello,
Downloaded the following RPM:
http://yum.pgsqlrpms.org/8.4/redhat/rhel-4-i386/postgresql-server-8.4.3-2PGD
G.el4.i386.rpm
for my CentOS 4 install.
service postgresql initdb fails with no error message.
So, I su'd to postgres, and ran
initdb --pgdata=/var/lib/pgsql/data --auth=ident
which is what service postgresql initdb does.
This command failed, with the error message:
could not open directory "/usr/share/pgsql/timezonesets"
I did a
chown -R postgres:postgres /usr/share/pgsql
and then it worked fine.
Using rpm2cpio {file} | cpio -tv
I see:
drwxr-xr-x 6 root root 0 Mar 17 16:21 ./usr/share/pgsql
which is fine, however there is no specific entry for
/usr/share/timezone.
The post-install script doesn't seem to fix it, either.
--
Sent via pgsql-bugs mailing list (pgsql...@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
---------------------------------------------------------------------------
--
Bruce Momjian <br...@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com
On Mon, 2010-04-19 at 14:22 +0000, Jamie Strachan wrote:
>
> for my CentOS 4 install.
>
> service postgresql initdb fails with no error message.
>
> So, I su'd to postgres, and ran
>
> initdb --pgdata=/var/lib/pgsql/data --auth=ident
> which is what service postgresql initdb does.
> This command failed, with the error message:
>
> could not open directory "/usr/share/pgsql/timezonesets"
Cannot reproduce it on my 8.4+CentOS 4 box:
-bash-3.00$ initdb --pgdata=/var/lib/pgsql/data --auth=ident
...
Success. You can now start the database server using:
...
timezonesets directory has already *enough* permissions for postgres
user to read it:
drwxr-xr-x 2 root root 4096 2010-03-19 09:45 timezonesets
Are you sure that you did not chmod somewhere between installing package
and initdb'ing?
Regards,
--
Devrim GÜNDÜZ
PostgreSQL Danışmanı/Consultant, Red Hat Certified Engineer
PostgreSQL RPM Repository: http://yum.pgrpms.org
Community: devrim~PostgreSQL.org, devrim.gunduz~linux.org.tr
http://www.gunduz.org Twitter: http://twitter.com/devrimgunduz
Still, this should have never ever happened. Lacey, AFAICS there is
nothing that could cause this issue in your spec file.
> # more /etc/redhat-release
> Red Hat Enterprise Linux ES release 4 (Nahant Update 3)
Mine is Update 8, BTW. I wonder whether there is an bug related to rpm
itself in here.
Yeah, I will do it in next set -- I'm just thinking whether it is worth
to push another build for now or not ;)
I'll let you know.
Regards,
Hello Everyone,
Yes, likewise, I cannot reproduce this on CentOS 4.8.
The permissions for the directory, from a clean RPM install, are 755 for
me.
However, the fixes listed and discussed, make good sense to me, so I
will be sure to include that in future rpm releases.
Jamie, Devrim, thank you both for your input. =)
Sincerely,
Lacey
--
Lacey Powers
The PostgreSQL Company - Command Prompt, Inc. 1.503.667.4564 ext 104
PostgreSQL Replication, Consulting, Custom Development, 24x7 support