Logon data for CIFS mount

I have been using NFS the whole time but the group access to the shares is not really good because unlike Samba “force user” and “force grou” are missing :slight_smile:

Now I am trying to test this solution. It has worked before.

The package “libpam-mount” is installed. The original /etc/security/pam_mount.conf.xml looks:

<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE pam_mount SYSTEM "pam_mount.conf.xml.dtd">
<!--
        See pam_mount.conf(5) for a description.
-->

<pam_mount>

                <!-- debug should come before everything else,
                since this file is still processed in a single pass
                from top-to-bottom -->

<debug enable="0" />

                <!-- Volume definitions -->


                <!-- pam_mount parameters: General tunables -->

<!--
<luserconf name=".pam_mount.conf.xml" />
-->

<!-- Note that commenting out mntoptions will give you the defaults.
     You will need to explicitly initialize it with the empty string
     to reset the defaults to nothing. -->
<mntoptions allow="nosuid,nodev,loop,encryption,fsck,nonempty,allow_root,allow_other" />
<!--
<mntoptions deny="suid,dev" />
<mntoptions allow="*" />
<mntoptions deny="*" />
-->
<mntoptions require="nosuid,nodev" />

<!-- requires ofl from hxtools to be present -->
<logout wait="0" hup="no" term="no" kill="no" />


                <!-- pam_mount parameters: Volume-related -->

<mkmountpoint enable="1" remove="true" />


</pam_mount>

I insert the line

<volume fstype="cifs" server="srv01.gehr.local" options="vers=3.0" path="Test" mountpoint="/data01/Test"> <not><user>root</user></not> <not><user>sddm</user></not> </volume>

above the line

</pam_mount>

Server-Host (UCS-Master) = srv01.gehr.local
Samba-Share = Test
local Mountpoint on Client = /data01/Test

But the directory is not mounted after I restart the client. What’s wrong?

with best
sven