Bug#1063772: postfix-mysql upgrade add map in dynamicmaps.cf after postfix restart

2024-04-01 Thread Scott Kitterman
The next postfix upload to unstable should address this by using a trigger to 
restart postfix any time one of the map type packages is configured.

Scott K



Bug#1063772: postfix-mysql upgrade add map in dynamicmaps.cf after postfix restart

2024-02-13 Thread Vincent Caron
Hello,

I have exactly the same problem with Debian 11 (for at least the last 3
Postfix upgrades). I am using Postfix with MySQL and PCRE maps.



Bug#1063772: postfix-mysql upgrade add map in dynamicmaps.cf after postfix restart

2024-02-12 Thread Tim Clerc
Package: postfix-mysql
Version: 3.7.10-0+deb12u1
Severity: normal

Dear Maintainer,

Today some of our servers upgraded there postfix and postfix-mysql
packages. After upgrade we see these messages in postfix logs and of
course we can't send mail anymore:

postfix/proxymap[2428105]: warning:
mysql:/etc/postfix/mysql-virtual-alias-maps.cf is unavailable.
unsupported dictionary type: mysql
postfix/trivial-rewrite[2428104]: warning: virtual_alias_domains:
proxy:mysql:/etc/postfix/mysql-virtual-alias-maps.cf: table lookup
problem
postfix/trivial-rewrite[2428104]: warning: virtual_alias_domains lookup
failure

In /etc/postfix/dynamicmaps.cf postfix-mysql map appear so we restart
postfix and everything is back again.

In apt logs we found that postfix is configured before postfix-mysql
finish his configuration:

Préparation du dépaquetage de
.../postfix-sqlite_3.7.10-0+deb12u1_amd64.deb ...
Removing sqlite map entry from /etc/postfix/dynamicmaps.cf
Dépaquetage de postfix-sqlite (3.7.10-0+deb12u1) sur (3.7.9-0+deb12u1)
...
Préparation du dépaquetage de
.../postfix-pcre_3.7.10-0+deb12u1_amd64.deb ...
Removing pcre map entry from /etc/postfix/dynamicmaps.cf
Dépaquetage de postfix-pcre (3.7.10-0+deb12u1) sur (3.7.9-0+deb12u1) ...
Préparation du dépaquetage de
.../postfix-mysql_3.7.10-0+deb12u1_amd64.deb ...
Removing mysql map entry from /etc/postfix/dynamicmaps.cf
Dépaquetage de postfix-mysql (3.7.10-0+deb12u1) sur (3.7.9-0+deb12u1)
...
Préparation du dépaquetage de .../postfix_3.7.10-0+deb12u1_amd64.deb ...
/etc/postfix/main.cf.proto modified, not updating.
Dépaquetage de postfix (3.7.10-0+deb12u1) sur (3.7.9-0+deb12u1) ...
Préparation du dépaquetage de .../postfix-doc_3.7.10-0+deb12u1_all.deb
...
Dépaquetage de postfix-doc (3.7.10-0+deb12u1) sur (3.7.9-0+deb12u1) ...
Paramétrage de postfix (3.7.10-0+deb12u1) ...

Postfix (main.cf) configuration was not changed.  If you need to make
changes, 
edit /etc/postfix/main.cf (and others) as needed.  To view Postfix 
configuration values, see postconf(1).

After modifying main.cf, be sure to run 'systemctl reload postfix'.

Paramétrage de postfix-doc (3.7.10-0+deb12u1) ...
Paramétrage de postfix-pcre (3.7.10-0+deb12u1) ...
Adding pcre map entry to /etc/postfix/dynamicmaps.cf
Paramétrage de postfix-sqlite (3.7.10-0+deb12u1) ...
Adding sqlite map entry to /etc/postfix/dynamicmaps.cf
Paramétrage de postfix-mysql (3.7.10-0+deb12u1) ...
Adding mysql map entry to /etc/postfix/dynamicmaps.cf
Traitement des actions différées (« triggers ») pour man-db
(2.11.2-2) ...


So, in correlation with other logs we found that postfix is restarted
before postfix-mysql add mysql map in dynamicmaps.cf.

We have observed this scenario with postfix-pgsql, postfix-sqlite and
postfix-pcre packages.

Not sure but these packages have Breaks control field in Debian 10 and
Debian 11. This control field doesn't appear in Debian 12. For example:
Debian 12: 
https://tracker.debian.org/media/packages/p/postfix/control-3.7.10-0deb12u1
Debian 11:
https://tracker.debian.org/media/packages/p/postfix/control-3.5.24-0deb11u1

-- System Information:
Debian Release: 12.5
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable-security'), (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 6.2.16-19-pve (SMP w/4 CPU threads; PREEMPT)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/bash
Init: systemd (via /run/systemd/system)

Versions of packages postfix-mysql depends on:
ii  libc62.36-9+deb12u4
ii  libmariadb3  1:10.11.6-0+deb12u1
ii  postfix  3.7.10-0+deb12u1

postfix-mysql recommends no packages.

postfix-mysql suggests no packages.

-- no debconf information