Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(18.09) postgresql: Enable systemd integration for 9.6+ #51137

Closed
wants to merge 2 commits into from

Conversation

domenkozar
Copy link
Member

@domenkozar domenkozar commented Nov 27, 2018

I'd really like to backport this one to 18.09 as it improves reliability.

I ran PostgreSQL nixos tests and will run this from today on in production (on top of 18.09). So give it a day or so.

EDIT: sorry for mass spam :(

This allows, finally, proper detection when postgresql is ready to
accept connections. Until now, it was possible that services depending
on postgresql would fail in a race condition trying to connect
to postgresql.

(cherry picked from commit d04fedd)
Signed-off-by: Domen Kožar <domen@dev.si>
@GrahamcOfBorg
Copy link

No attempt on x86_64-linux (full log)

The following builds were skipped because they don't evaluate on x86_64-linux: tests.postgresql.postgresql_9_6, tests.postgresql.postgresql_10, tests.postgresql.postgresql_11, tests.postgresql.postgresql_9_5

Partial log (click to expand)


Cannot nix-instantiate `tests.postgresql.postgresql_10' because:
error: attribute 'postgresql_10' in selection path 'tests.postgresql.postgresql_10' not found

Cannot nix-instantiate `tests.postgresql.postgresql_11' because:
error: attribute 'postgresql_11' in selection path 'tests.postgresql.postgresql_11' not found

Cannot nix-instantiate `tests.postgresql.postgresql_9_5' because:
error: attribute 'postgresql_9_5' in selection path 'tests.postgresql.postgresql_9_5' not found

@Mic92
Copy link
Member

Mic92 commented Nov 27, 2018

I need to write a script that output ofborg test commands!

@GrahamcOfBorg
Copy link

Success on aarch64-linux (full log)

Attempted: postgresql

Partial log (click to expand)

checking for references to /build in /nix/store/zjblfjq4ahny6z4f381yj47wj21m66is-postgresql-9.6.11-lib...
shrinking RPATHs of ELF executables and libraries in /nix/store/m957aaykjwynk1fzy1l61qnijx2z706d-postgresql-9.6.11-doc
strip is /nix/store/y4ymnvgxygpq05h03kyzbj572zmh6zla-binutils-2.30/bin/strip
patching script interpreter paths in /nix/store/m957aaykjwynk1fzy1l61qnijx2z706d-postgresql-9.6.11-doc
checking for references to /build in /nix/store/m957aaykjwynk1fzy1l61qnijx2z706d-postgresql-9.6.11-doc...
shrinking RPATHs of ELF executables and libraries in /nix/store/icljqdhh6z4d4icx7mzlw0zq7r7jhm9p-postgresql-9.6.11-man
gzipping man pages under /nix/store/icljqdhh6z4d4icx7mzlw0zq7r7jhm9p-postgresql-9.6.11-man/share/man/
strip is /nix/store/y4ymnvgxygpq05h03kyzbj572zmh6zla-binutils-2.30/bin/strip
patching script interpreter paths in /nix/store/icljqdhh6z4d4icx7mzlw0zq7r7jhm9p-postgresql-9.6.11-man
checking for references to /build in /nix/store/icljqdhh6z4d4icx7mzlw0zq7r7jhm9p-postgresql-9.6.11-man...

@GrahamcOfBorg
Copy link

Success on x86_64-linux (full log)

Attempted: postgresql

Partial log (click to expand)

checking for references to /build in /nix/store/40ldqq989dhybg5gq00l4walv42ny9qf-postgresql-9.6.11-lib...
shrinking RPATHs of ELF executables and libraries in /nix/store/wqnigx6pya6hfgvramxz0vxj7ynckz3c-postgresql-9.6.11-doc
strip is /nix/store/h0lbngpv6ln56hjj59i6l77vxq25flbz-binutils-2.30/bin/strip
patching script interpreter paths in /nix/store/wqnigx6pya6hfgvramxz0vxj7ynckz3c-postgresql-9.6.11-doc
checking for references to /build in /nix/store/wqnigx6pya6hfgvramxz0vxj7ynckz3c-postgresql-9.6.11-doc...
shrinking RPATHs of ELF executables and libraries in /nix/store/p1via4mv23zqhhjhhxj1g5lzzpknfvl4-postgresql-9.6.11-man
gzipping man pages under /nix/store/p1via4mv23zqhhjhhxj1g5lzzpknfvl4-postgresql-9.6.11-man/share/man/
strip is /nix/store/h0lbngpv6ln56hjj59i6l77vxq25flbz-binutils-2.30/bin/strip
patching script interpreter paths in /nix/store/p1via4mv23zqhhjhhxj1g5lzzpknfvl4-postgresql-9.6.11-man
checking for references to /build in /nix/store/p1via4mv23zqhhjhhxj1g5lzzpknfvl4-postgresql-9.6.11-man...

@GrahamcOfBorg
Copy link

Success on x86_64-darwin (full log)

Attempted: postgresql

Partial log (click to expand)

/nix/store/hy2kqnk2lkx64cq9ginbrb74s0ccff9k-postgresql-9.6.11/lib/pgxs/config/install-sh: interpreter directive changed from "/bin/sh" to "/nix/store/cblfnvb5rmhd2z231mqasn0brzh1hhv4-bash-4.4-p23/bin/sh"
/nix/store/hy2kqnk2lkx64cq9ginbrb74s0ccff9k-postgresql-9.6.11/lib/pgxs/config/missing: interpreter directive changed from " /bin/sh" to "/nix/store/cblfnvb5rmhd2z231mqasn0brzh1hhv4-bash-4.4-p23/bin/sh"
strip is /nix/store/df6k4mgdjxciy0f637lryp7c9ln7n1m3-cctools-binutils-darwin/bin/strip
stripping (with command strip and flags -S) in /nix/store/c5w7rlv64ra2x5syrs5b1yq5kdyf9wbq-postgresql-9.6.11-lib/lib
patching script interpreter paths in /nix/store/c5w7rlv64ra2x5syrs5b1yq5kdyf9wbq-postgresql-9.6.11-lib
strip is /nix/store/df6k4mgdjxciy0f637lryp7c9ln7n1m3-cctools-binutils-darwin/bin/strip
patching script interpreter paths in /nix/store/xzh6dz7fxvzj16a2z41j70i52qjv2jxh-postgresql-9.6.11-doc
gzipping man pages under /nix/store/5xjx6fd2abs7xl8ghda4xksl1c2ph3bq-postgresql-9.6.11-man/share/man/
strip is /nix/store/df6k4mgdjxciy0f637lryp7c9ln7n1m3-cctools-binutils-darwin/bin/strip
patching script interpreter paths in /nix/store/5xjx6fd2abs7xl8ghda4xksl1c2ph3bq-postgresql-9.6.11-man

@domenkozar
Copy link
Member Author

@Mic92 any objections merging?

@thoughtpolice
Copy link
Member

thoughtpolice commented Nov 28, 2018

See also: 1e83cf3 from #38698

@domenkozar domenkozar closed this Nov 28, 2018
@domenkozar
Copy link
Member Author

Two people came to same patch, it's tested in production. Merged to 18.09 in 4169ce0

@domenkozar domenkozar deleted the postgresql-systemd branch November 28, 2018 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants