FS#48333 - [postgresql] cannot start, /run/postgresql missing

Attached to Project: Arch Linux
Opened by Marc Cousin (cousinm) - Thursday, 25 February 2016, 07:45 GMT
Last edited by Doug Newgard (Scimmia) - Wednesday, 02 March 2016, 14:25 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Dan McGee (toofishes)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

PostgreSQL doesn't start anymore (/run/postgresql not created)

Additional info:
* 9.5.1-1
* /usr/lib/tmpfiles.d/postgresql.conf isn't in the package anymore


Steps to reproduce:

Install postgresql. It doesn't start.

systemd[1]: Starting PostgreSQL database server...
postgres[4393]: FATAL: could not create lock file "/run/postgresql/.s.PGSQL.5432.lock": No such file or directory
systemd[1]: postgresql.service: Control process exited, code=exited status=1
systemd[1]: Failed to start PostgreSQL database server.
systemd[1]: postgresql.service: Unit entered failed state.
systemd[1]: postgresql.service: Failed with result 'exit-code'.

Of course, creating the directory manually works.

pacman -Ql postgresql | grep tmp returns nothing

In 9.5.0-1, the /usr/lib/tmpfiles.d/postgresql.conf was still present.
This task depends upon

Closed by  Doug Newgard (Scimmia)
Wednesday, 02 March 2016, 14:25 GMT
Reason for closing:  Not a bug
Comment by Marc Cousin (cousinm) - Sunday, 28 February 2016, 10:08 GMT
Weird, I have another machine where the /run/postgresql is created despite no tmpfiles.d entry to create it…
Comment by Dan McGee (toofishes) - Wednesday, 02 March 2016, 03:04 GMT
It is created by the 'RuntimeDirectory' directives in the unit file. Did you perform a 'systemctl daemon-reload' to ensure you got the updated version?
Comment by Marc Cousin (cousinm) - Wednesday, 02 March 2016, 06:23 GMT
OK, I've just made a fool of myself. I had an old edited postgresql.service lying around. Sorry about that. Didn't know about the RuntimeDirectory directive :)

Regards
Comment by Pavlos Touboulidis (pav) - Wednesday, 02 March 2016, 06:28 GMT
I had the same problem, an edited postgresql.service in /etc/systemd/system, where I had changed PGROOT and PIDFile paths.

Loading...