SYSTEM INFORMATION | |
---|---|
OS type and version | Debian 13 (Trixie) |
Webmin version | 2.402 |
Virtualmin version | 7.30.8 |
Webserver version | Apache 2.4.65 |
Related packages | saslauthd |
Morning,
I updated some VPSes to Trixie yesterday. By and large, all working fine, though SMTP authentication fails due to the “saslauthd
” service not starting.
When doing “systemctl status saslauthd
” it looks like systemd is waiting for a PID file to exist, but is not being produced by the service any more:
Aug 17 09:42:03 host.example.com systemd[1]: Starting saslauthd.service - SASL Authentication Daemon...
Aug 17 09:42:03 host.example.com (aslauthd)[2690758]: saslauthd.service: Referenced but unset environment variable evaluates to an empty string: MECH_OPTIONS
Aug 17 09:42:03 host.example.com saslauthd[2690763]: : master pid is: 2690763
Aug 17 09:42:03 host.example.com systemd[1]: saslauthd.service: Can't open PID file '/run/saslauthd/saslauthd.pid' (yet?) after start: No such file or directory
Aug 17 09:42:03 host.example.com saslauthd[2690763]: : listening on socket: /var/spool/postfix/var/run/saslauthd/mux
SystemD will just wait for this to never happen, eventually timing out the service and terminating it. As a workaround you can echo the process ID shown from the master pid line:
echo 2690763 > /run/saslauthd/saslauthd.pid
Once doing that the SASL service instantly works as normal, with SMTP authentication working:
Aug 17 09:42:30 host.example.com systemd[1]: Started saslauthd.service - SASL Authentication Daemon.
Obviously this would need to be done again any time the SASL service is started, including after a system reboot.
When searching for the service’s PID elsewhere I found it at path “/var/spool/postfix/var/run/saslauthd/saslauthd.pid
”. Linking “/run/saslauthd/saslauthd.pid
” to this doesn’t work as the link file is removed when the service starts, therefore it seems necessary to modify the systemd service file to point the PID file elsewhere.
To resolve this long term:
sed -e 's/PIDFile=\/var\/run\/saslauthd\/saslauthd\.pid/PIDFile=\/var\/spool\/postfix\/var\/run\/saslauthd\/saslauthd.pid/' -i /usr/lib/systemd/system/saslauthd.service
systemctl daemon-reload
systemctl restart saslauthd
Almost certainly not a Virtualmin specific issue, may just be useful to know.