#1010928 postgresql-13: foo bar

#1010928#5
Date:
2022-05-13 10:35:47 UTC
From:
To:
Dear Maintainer,

postgresql@13-main service wasn't restarted after an automatic upgrade which
was performed by unattended-upgrades today. Investigating i found #996109 and
checked /etc/postgresql/13/main/start.conf:

  # cat /etc/postgresql/13/main/start.conf
  # Automatic startup configuration
  #   auto: automatically start the cluster
  #   manual: manual startup with pg_ctlcluster/postgresql@.service only
  #   disabled: refuse to start cluster
  # See pg_createcluster(1) for details. When running from systemd,
  # invoke 'systemctl daemon-reload' after editing this file.

  auto

Investigating further i found that /var/lib/dpkg/info/postgresql-13.prerm does
'stop_version $VERSION' and /var/lib/dpkg/info/postgresql-13.postinst does
'configure_version $VERSION "$2"' which in turn does 'invoke-rc.d postgresql
start $VERSION' at the end which also has the comment 'systemd: argument
ignored, starts all versions'. The latter appears to be a noop though when
postgresql.service is still running (it was not stopped by the maintainer
scripts):

  # systemctl status postgresql.service postgresql@13-main.service |grep -E '^\s*(���|Loaded|Active)' --color=no
  ��� postgresql.service - PostgreSQL RDBMS
       Loaded: loaded (/lib/systemd/system/postgresql.service; enabled; vendor preset: enabled)
       Active: active (exited) since Tue 2022-04-19 08:46:03 CEST; 3 weeks 3 days ago
  ��� postgresql@13-main.service - PostgreSQL Cluster 13-main
       Loaded: loaded (/lib/systemd/system/postgresql@.service; enabled; vendor preset: enabled)
       Active: active (running) since Fri 2022-05-13 09:44:51 CEST; 1h 28min ago

Regards

#1010928#10
Date:
2022-05-13 10:48:35 UTC
From:
To:
Sorry for the subject of the bug report, it should actually read as
follows:

postgresql-13: postgresql@13-main.service not restarted after an upgrade