I followed the steps exactly.
apt install libpam-mount keyutils -y
[/etc/security/pam_mount.conf.xml]
<?xml version="1.0" encoding="utf-8" ?>
<pam_mount>
<debug enable="0" />
<mntoptions allow="nosuid,nodev,loop,encryption,fsck,nonempty,allow_root,allow_other" />
<mntoptions require="nosuid,nodev" />
<logout wait="0" hup="no" term="no" kill="no" />
<mkmountpoint enable="1" remove="true" />
<volume fstype="cifs" server="srv01.gehr.local" options="vers=3.0" path="Test" mountpoint="/data01/Test" />
</pam_mount>
[`/etc/pam.d/common-auth]
auth required pam_group.so use_first_pass
auth [success=2 default=ignore] pam_unix.so nullok_secure try_first_pass
auth [success=1 default=ignore] pam_sss.so use_first_pass
auth requisite pam_deny.so
auth required pam_permit.so
auth optional pam_mount.so
auth optional pam_cap.so
[/etc/pam.d/common-password]
password requisite pam_pwquality.so retry=3
password [success=2 default=ignore] pam_unix.so obscure use_authtok try_first_pass sha512
password sufficient pam_sss.so use_authtok
password requisite pam_deny.so
password required pam_permit.so
password optional pam_mount.so disable_interactive
password optional pam_gnome_keyring.so
[/etc/pam.d/common-session]
session [default=1] pam_permit.so
session requisite pam_deny.so
session required pam_permit.so
session optional pam_umask.so
session required pam_mkhomedir.so umask=0022 skel=/etc/skel
session required pam_unix.so
session optional pam_sss.so
session optional pam_mount.so
session optional pam_systemd.so
then restart the client but the release “Test” is not mounted in /data01/Test