Bug 21385

Summary: postgresql server version 9.6 cannot be run
Product: Mageia Reporter: Denis Bitouzé <dbitouze>
Component: RPM PackagesAssignee: Joseph Wang <joequant>
Status: RESOLVED INVALID QA Contact:
Severity: major    
Priority: High CC: hart3778avery, mageia, pkg-bugs
Version: 6   
Target Milestone: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Source RPM: postgresql9.6-9.6.3-1.mga6.src.rpm CVE:
Status comment:

Description Denis Bitouzé 2017-07-28 16:20:20 CEST
Description of problem:
I'm unable to run postgresql9.6-server

Version-Release number of selected component (if applicable):
postgresql9.6-server-9.6.3-1.mga6

How reproducible:
Every time I attempt to run postgresql

Steps to Reproduce:
1. Install postgresql9.6-server-9.6.3-1.mga6
2. As root, run:

systemctl status postgresql.service

The output is:

● postgresql.service - PostgreSQL database server
   Loaded: loaded (/usr/lib/systemd/system/postgresql.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since ven. 2017-07-28 16:17:39 CEST; 21s ago
  Process: 21643 ExecStartPre=/usr/libexec/postgresql_initdb.sh ${PGDATA} (code=exited, status=1/FAILURE)

juil. 28 16:17:39 localhost.localdomain systemd[1]: Starting PostgreSQL database server...
juil. 28 16:17:39 localhost.localdomain systemd[1]: postgresql.service: Control process exited, code=exited status=1
juil. 28 16:17:39 localhost.localdomain systemd[1]: Failed to start PostgreSQL database server.
juil. 28 16:17:39 localhost.localdomain systemd[1]: postgresql.service: Unit entered failed state.
juil. 28 16:17:39 localhost.localdomain systemd[1]: postgresql.service: Failed with result 'exit-code'.
Rémi Verschelde 2017-07-28 16:23:29 CEST

Priority: Normal => High
Assignee: bugsquad => joequant
CC: (none) => pkg-bugs

Comment 1 Denis Bitouzé 2017-08-26 15:45:39 CEST
If have used:

  service postgresql start

instead of:

  systemctl status postgresql.service

I would have seen the advice:

> See "systemctl status postgresql.service" and "journalctl -xe" for details.

In the output of the last command:

  postgresql_initdb.sh[30933]: /usr/libexec/postgresql_initdb.sh: ligne 16: /var/log/postgres/postgresql: Permission denied

Good catch:

  # ll /var/log/postgres/postgresql
  -rw-r--r-- 1 ntp 486 0 juil. 30 11:24 /var/log/postgres/postgresql

which is rather strange!

Anyway, after:

  # chown postgres:postgres /var/log/postgres/postgresql

the postgresql server version 9.6 started properly.

If I'm the only one with these strange ownerships of /var/log/postgres/postgresql, this bug should be closed. Otherwise, I hope it helps.
Comment 2 Hart Shi 2019-10-14 02:31:59 CEST
Yeah, ntp owner seems pretty strange. ,https://www.zorgverzekeringvergelijken2020.nl/

CC: (none) => hart3778avery

Comment 3 Marc Krämer 2020-02-24 20:45:06 CET
no more problems reported on faulty ownership

CC: (none) => mageia
Resolution: (none) => INVALID
Status: NEW => RESOLVED