PAM authentication plugin crashs with segmentation fault

Hello :slight_smile:

we’re using the pam_auth plugin for authentication of developers on database systems.
After upgrade von 5.7 to 8.0 the plugin is not working anymore and crashes with segfault.

Here are some lines from syslog:

Jan 29 15:20:50 mw-bm-dev kernel: [232421.158041] audit: type=1400 audit(1706538050.815:102): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/pam.d/mysqld" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:50 mw-bm-dev kernel: [232421.161105] audit: type=1400 audit(1706538050.819:103): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/pam.d/other" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:50 mw-bm-dev kernel: [232421.161110] audit: type=1400 audit(1706538050.819:104): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/pam.d/common-auth" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:50 mw-bm-dev kernel: [232421.161345] audit: type=1400 audit(1706538050.819:105): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/pam.d/common-account" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:50 mw-bm-dev kernel: [232421.161350] audit: type=1400 audit(1706538050.819:106): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/pam.d/common-password" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:50 mw-bm-dev kernel: [232421.161373] audit: type=1400 audit(1706538050.819:107): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/pam.d/common-session" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:50 mw-bm-dev kernel: [232421.161786] audit: type=1400 audit(1706538050.819:108): apparmor="ALLOWED" operation="open" profile="/usr/sbin/mysqld" name="/etc/login.defs" pid=2784 comm="connection" requested_mask="r" denied_mask="r" fsuid=110 ouid=0
Jan 29 15:20:53 mw-bm-dev kernel: [232423.718328] mysql[452223]: segfault at 128 ip 00007f940426455a sp 00007fffab1bae70 error 4 in dialog.so[7f9404264000+1000]
Jan 29 15:20:53 mw-bm-dev kernel: [232423.718359] Code: 4f 00 00 00 4c 89 c7 48 89 c6 e8 01 fb ff ff c6 45 ff 00 ba 08 00 00 00 31 ff 49 89 c0 48 8b 05 8c 2a 00 00 4c 89 c6 48 8b 00 <ff> 50 28 c9 c3 00 48 83 ec 08 48 83 c4 08 c3 00 00 00 00 00 00 00

Does anymore has an idea?

Thanks, Denny

Hello dreeh,
Thank you for raising this question.
In your case, i would try to disable Apparmor temporary to see if it’s causing issue, and if issue still persist, I would spin fresh instance and rather than upgrade from 5.7 to 8.0, do fresh install of MySQL 8 server and try to use the same configuration as you have on your dev database.

Regards,
Denis Subbota.
Managed Services, Percona.