cifs pam mount disable nounix option

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
2
down vote

favorite












Trying to set up roaming profile for user by mounting remote samba share using pam_mount. However, nounix option is being automatically added on the mounted folder due to which symlinks cannot be created on the shared folder nor can the csync program be used for syncing.



Relevant files and outputs:




$ cat /etc/security/pam_mount.conf.xml




<?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="1" />

<!-- 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" />

<logout wait="0" hup="0" term="0" kill="0" />


<!-- pam_mount parameters: Volume-related -->
<!-- LINE BELOW WAS ADDED! -->
<volume fstype="cifs" server="server.lan" path="%(DOMAIN_USER)" mountpoint="/home/roaming/%(DOMAIN_NAME)/%(DOMAIN_USER)" options="vers=2.1,uid=%(USER)" />

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


</pam_mount>



$ mount




sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=1935432k,nr_inodes=483858,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=391560k,mode=755)
/dev/sda1 on / type ext4 (rw,noatime,errors=remount-ro,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=25,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=3286)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
tmpfs on /run/user/1274545246 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1274545246,gid=1274544641)
//server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=2.1,sec=ntlmssp,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,file_mode=0755,dir_mode=0755,nounix,serverino,mapposix,rsize=1048576,wsize=1048576,echo_interval=60,actimeo=1)
gvfsd-fuse on /run/user/1274545246/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1274545246,group_id=1274544641)
tmpfs on /run/user/1001 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1001,gid=1001)
gvfsd-fuse on /run/user/1001/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1001,group_id=1001)


mount.cifs(8) has the following info:



 nounix
Disable the CIFS Unix Extensions for this mount. This can be useful in order to turn off multiple settings at once. This includes POSIX acls, POSIX locks,
POSIX paths, symlink support and retrieving uids/gids/mode from the server. This can also be useful to work around a bug in a server that supports Unix
Extensions.

See section INODE NUMBERS for more information.


I tried adding unix to the list of mount options but that fails with:




mount error(22): Invalid argument
Nov 3 17:24:35 system lightdm: (mount.c:76): Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)




Why is the nounix option being automatically added how can it be disabled?



Alternatively can I know which are the exact options disabled by nounix so that they can be enabled?



OS is Ubuntu 16.04



$ uname -srm
Linux 4.10.0-38-lowlatency x86_64


With the folder already mounted by pam_mount, if I unmount and then remount it gets the same mount output.



However, if I disable folder mount in pam_mount, logout, login and try to mount it manually via the command line, then in some cases I do not get nounix in the mount options? (quite confusing; need to pinpoint where it works and where it doesn't)







share|improve this question


























    up vote
    2
    down vote

    favorite












    Trying to set up roaming profile for user by mounting remote samba share using pam_mount. However, nounix option is being automatically added on the mounted folder due to which symlinks cannot be created on the shared folder nor can the csync program be used for syncing.



    Relevant files and outputs:




    $ cat /etc/security/pam_mount.conf.xml




    <?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="1" />

    <!-- 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" />

    <logout wait="0" hup="0" term="0" kill="0" />


    <!-- pam_mount parameters: Volume-related -->
    <!-- LINE BELOW WAS ADDED! -->
    <volume fstype="cifs" server="server.lan" path="%(DOMAIN_USER)" mountpoint="/home/roaming/%(DOMAIN_NAME)/%(DOMAIN_USER)" options="vers=2.1,uid=%(USER)" />

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


    </pam_mount>



    $ mount




    sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
    proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
    udev on /dev type devtmpfs (rw,nosuid,relatime,size=1935432k,nr_inodes=483858,mode=755)
    devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
    tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=391560k,mode=755)
    /dev/sda1 on / type ext4 (rw,noatime,errors=remount-ro,data=ordered)
    securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
    tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
    tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
    tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
    cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
    pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
    cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
    cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
    cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
    cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
    cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
    cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
    cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
    cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
    cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
    cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
    systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=25,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=3286)
    debugfs on /sys/kernel/debug type debugfs (rw,relatime)
    mqueue on /dev/mqueue type mqueue (rw,relatime)
    hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
    fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
    sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
    tmpfs on /run/user/1274545246 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1274545246,gid=1274544641)
    //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=2.1,sec=ntlmssp,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,file_mode=0755,dir_mode=0755,nounix,serverino,mapposix,rsize=1048576,wsize=1048576,echo_interval=60,actimeo=1)
    gvfsd-fuse on /run/user/1274545246/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1274545246,group_id=1274544641)
    tmpfs on /run/user/1001 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1001,gid=1001)
    gvfsd-fuse on /run/user/1001/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1001,group_id=1001)


    mount.cifs(8) has the following info:



     nounix
    Disable the CIFS Unix Extensions for this mount. This can be useful in order to turn off multiple settings at once. This includes POSIX acls, POSIX locks,
    POSIX paths, symlink support and retrieving uids/gids/mode from the server. This can also be useful to work around a bug in a server that supports Unix
    Extensions.

    See section INODE NUMBERS for more information.


    I tried adding unix to the list of mount options but that fails with:




    mount error(22): Invalid argument
    Nov 3 17:24:35 system lightdm: (mount.c:76): Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)




    Why is the nounix option being automatically added how can it be disabled?



    Alternatively can I know which are the exact options disabled by nounix so that they can be enabled?



    OS is Ubuntu 16.04



    $ uname -srm
    Linux 4.10.0-38-lowlatency x86_64


    With the folder already mounted by pam_mount, if I unmount and then remount it gets the same mount output.



    However, if I disable folder mount in pam_mount, logout, login and try to mount it manually via the command line, then in some cases I do not get nounix in the mount options? (quite confusing; need to pinpoint where it works and where it doesn't)







    share|improve this question
























      up vote
      2
      down vote

      favorite









      up vote
      2
      down vote

      favorite











      Trying to set up roaming profile for user by mounting remote samba share using pam_mount. However, nounix option is being automatically added on the mounted folder due to which symlinks cannot be created on the shared folder nor can the csync program be used for syncing.



      Relevant files and outputs:




      $ cat /etc/security/pam_mount.conf.xml




      <?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="1" />

      <!-- 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" />

      <logout wait="0" hup="0" term="0" kill="0" />


      <!-- pam_mount parameters: Volume-related -->
      <!-- LINE BELOW WAS ADDED! -->
      <volume fstype="cifs" server="server.lan" path="%(DOMAIN_USER)" mountpoint="/home/roaming/%(DOMAIN_NAME)/%(DOMAIN_USER)" options="vers=2.1,uid=%(USER)" />

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


      </pam_mount>



      $ mount




      sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
      proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
      udev on /dev type devtmpfs (rw,nosuid,relatime,size=1935432k,nr_inodes=483858,mode=755)
      devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
      tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=391560k,mode=755)
      /dev/sda1 on / type ext4 (rw,noatime,errors=remount-ro,data=ordered)
      securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
      tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
      tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
      tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
      cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
      pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
      cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
      cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
      cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
      cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
      cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
      cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
      cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
      cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
      cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
      cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
      systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=25,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=3286)
      debugfs on /sys/kernel/debug type debugfs (rw,relatime)
      mqueue on /dev/mqueue type mqueue (rw,relatime)
      hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
      fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
      sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
      tmpfs on /run/user/1274545246 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1274545246,gid=1274544641)
      //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=2.1,sec=ntlmssp,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,file_mode=0755,dir_mode=0755,nounix,serverino,mapposix,rsize=1048576,wsize=1048576,echo_interval=60,actimeo=1)
      gvfsd-fuse on /run/user/1274545246/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1274545246,group_id=1274544641)
      tmpfs on /run/user/1001 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1001,gid=1001)
      gvfsd-fuse on /run/user/1001/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1001,group_id=1001)


      mount.cifs(8) has the following info:



       nounix
      Disable the CIFS Unix Extensions for this mount. This can be useful in order to turn off multiple settings at once. This includes POSIX acls, POSIX locks,
      POSIX paths, symlink support and retrieving uids/gids/mode from the server. This can also be useful to work around a bug in a server that supports Unix
      Extensions.

      See section INODE NUMBERS for more information.


      I tried adding unix to the list of mount options but that fails with:




      mount error(22): Invalid argument
      Nov 3 17:24:35 system lightdm: (mount.c:76): Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)




      Why is the nounix option being automatically added how can it be disabled?



      Alternatively can I know which are the exact options disabled by nounix so that they can be enabled?



      OS is Ubuntu 16.04



      $ uname -srm
      Linux 4.10.0-38-lowlatency x86_64


      With the folder already mounted by pam_mount, if I unmount and then remount it gets the same mount output.



      However, if I disable folder mount in pam_mount, logout, login and try to mount it manually via the command line, then in some cases I do not get nounix in the mount options? (quite confusing; need to pinpoint where it works and where it doesn't)







      share|improve this question














      Trying to set up roaming profile for user by mounting remote samba share using pam_mount. However, nounix option is being automatically added on the mounted folder due to which symlinks cannot be created on the shared folder nor can the csync program be used for syncing.



      Relevant files and outputs:




      $ cat /etc/security/pam_mount.conf.xml




      <?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="1" />

      <!-- 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" />

      <logout wait="0" hup="0" term="0" kill="0" />


      <!-- pam_mount parameters: Volume-related -->
      <!-- LINE BELOW WAS ADDED! -->
      <volume fstype="cifs" server="server.lan" path="%(DOMAIN_USER)" mountpoint="/home/roaming/%(DOMAIN_NAME)/%(DOMAIN_USER)" options="vers=2.1,uid=%(USER)" />

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


      </pam_mount>



      $ mount




      sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
      proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
      udev on /dev type devtmpfs (rw,nosuid,relatime,size=1935432k,nr_inodes=483858,mode=755)
      devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
      tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=391560k,mode=755)
      /dev/sda1 on / type ext4 (rw,noatime,errors=remount-ro,data=ordered)
      securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
      tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
      tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
      tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
      cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
      pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
      cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
      cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
      cgroup on /sys/fs/cgroup/pids type cgroup (rw,nosuid,nodev,noexec,relatime,pids)
      cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
      cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
      cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
      cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
      cgroup on /sys/fs/cgroup/hugetlb type cgroup (rw,nosuid,nodev,noexec,relatime,hugetlb)
      cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
      cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
      systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=25,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=3286)
      debugfs on /sys/kernel/debug type debugfs (rw,relatime)
      mqueue on /dev/mqueue type mqueue (rw,relatime)
      hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
      fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
      sunrpc on /run/rpc_pipefs type rpc_pipefs (rw,relatime)
      tmpfs on /run/user/1274545246 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1274545246,gid=1274544641)
      //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=2.1,sec=ntlmssp,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,file_mode=0755,dir_mode=0755,nounix,serverino,mapposix,rsize=1048576,wsize=1048576,echo_interval=60,actimeo=1)
      gvfsd-fuse on /run/user/1274545246/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1274545246,group_id=1274544641)
      tmpfs on /run/user/1001 type tmpfs (rw,nosuid,nodev,relatime,size=391560k,mode=700,uid=1001,gid=1001)
      gvfsd-fuse on /run/user/1001/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1001,group_id=1001)


      mount.cifs(8) has the following info:



       nounix
      Disable the CIFS Unix Extensions for this mount. This can be useful in order to turn off multiple settings at once. This includes POSIX acls, POSIX locks,
      POSIX paths, symlink support and retrieving uids/gids/mode from the server. This can also be useful to work around a bug in a server that supports Unix
      Extensions.

      See section INODE NUMBERS for more information.


      I tried adding unix to the list of mount options but that fails with:




      mount error(22): Invalid argument
      Nov 3 17:24:35 system lightdm: (mount.c:76): Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)




      Why is the nounix option being automatically added how can it be disabled?



      Alternatively can I know which are the exact options disabled by nounix so that they can be enabled?



      OS is Ubuntu 16.04



      $ uname -srm
      Linux 4.10.0-38-lowlatency x86_64


      With the folder already mounted by pam_mount, if I unmount and then remount it gets the same mount output.



      However, if I disable folder mount in pam_mount, logout, login and try to mount it manually via the command line, then in some cases I do not get nounix in the mount options? (quite confusing; need to pinpoint where it works and where it doesn't)









      share|improve this question













      share|improve this question




      share|improve this question








      edited Aug 7 at 22:19









      Jeff Schaller

      32k849109




      32k849109










      asked Nov 5 '17 at 13:27









      Aaditya Bagga

      190119




      190119




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          1
          down vote



          accepted










          After much hit and try, this seems to be an effect of the vers option. If vers=2.1 is removed, unix extensions seem to get enabled:



          //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=1.0,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,unix,posixpaths,serverino,mapposix,acl,rsize=1048576,wsize=65536,echo_interval=60,actimeo=1)


          The reason I had added vers=2.1 is because the samba share has a disk space quota, but with 1.0 the free space of whole disk is shown rather than that of the quota.



          So the question now is: how to enable unix extensions for ver 2.1 of samba?






          share|improve this answer






















          • Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
            – Aaditya Bagga
            Nov 8 '17 at 13:24











          • related discussion: unix.stackexchange.com/questions/403509/…
            – Aaditya Bagga
            Nov 11 '17 at 18:55










          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f402654%2fcifs-pam-mount-disable-nounix-option%23new-answer', 'question_page');

          );

          Post as a guest






























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          1
          down vote



          accepted










          After much hit and try, this seems to be an effect of the vers option. If vers=2.1 is removed, unix extensions seem to get enabled:



          //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=1.0,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,unix,posixpaths,serverino,mapposix,acl,rsize=1048576,wsize=65536,echo_interval=60,actimeo=1)


          The reason I had added vers=2.1 is because the samba share has a disk space quota, but with 1.0 the free space of whole disk is shown rather than that of the quota.



          So the question now is: how to enable unix extensions for ver 2.1 of samba?






          share|improve this answer






















          • Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
            – Aaditya Bagga
            Nov 8 '17 at 13:24











          • related discussion: unix.stackexchange.com/questions/403509/…
            – Aaditya Bagga
            Nov 11 '17 at 18:55














          up vote
          1
          down vote



          accepted










          After much hit and try, this seems to be an effect of the vers option. If vers=2.1 is removed, unix extensions seem to get enabled:



          //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=1.0,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,unix,posixpaths,serverino,mapposix,acl,rsize=1048576,wsize=65536,echo_interval=60,actimeo=1)


          The reason I had added vers=2.1 is because the samba share has a disk space quota, but with 1.0 the free space of whole disk is shown rather than that of the quota.



          So the question now is: how to enable unix extensions for ver 2.1 of samba?






          share|improve this answer






















          • Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
            – Aaditya Bagga
            Nov 8 '17 at 13:24











          • related discussion: unix.stackexchange.com/questions/403509/…
            – Aaditya Bagga
            Nov 11 '17 at 18:55












          up vote
          1
          down vote



          accepted







          up vote
          1
          down vote



          accepted






          After much hit and try, this seems to be an effect of the vers option. If vers=2.1 is removed, unix extensions seem to get enabled:



          //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=1.0,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,unix,posixpaths,serverino,mapposix,acl,rsize=1048576,wsize=65536,echo_interval=60,actimeo=1)


          The reason I had added vers=2.1 is because the samba share has a disk space quota, but with 1.0 the free space of whole disk is shown rather than that of the quota.



          So the question now is: how to enable unix extensions for ver 2.1 of samba?






          share|improve this answer














          After much hit and try, this seems to be an effect of the vers option. If vers=2.1 is removed, unix extensions seem to get enabled:



          //server.lan/aaditya on /home/roaming/SERVER/aaditya type cifs (rw,relatime,vers=1.0,cache=strict,username=aaditya,domain=SERVER,uid=1274545246,forceuid,gid=1274544641,forcegid,addr=192.168.1.191,unix,posixpaths,serverino,mapposix,acl,rsize=1048576,wsize=65536,echo_interval=60,actimeo=1)


          The reason I had added vers=2.1 is because the samba share has a disk space quota, but with 1.0 the free space of whole disk is shown rather than that of the quota.



          So the question now is: how to enable unix extensions for ver 2.1 of samba?







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 7 '17 at 13:44

























          answered Nov 7 '17 at 11:39









          Aaditya Bagga

          190119




          190119











          • Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
            – Aaditya Bagga
            Nov 8 '17 at 13:24











          • related discussion: unix.stackexchange.com/questions/403509/…
            – Aaditya Bagga
            Nov 11 '17 at 18:55
















          • Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
            – Aaditya Bagga
            Nov 8 '17 at 13:24











          • related discussion: unix.stackexchange.com/questions/403509/…
            – Aaditya Bagga
            Nov 11 '17 at 18:55















          Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
          – Aaditya Bagga
          Nov 8 '17 at 13:24





          Looking at wiki.samba.org/index.php/SMB3-Linux tried to use cifsacl option, but it fails with mount error (-95) operation not supported (possibly due to the extension not being completely implemented yet), so had to revert back to using SMB version 1.0.
          – Aaditya Bagga
          Nov 8 '17 at 13:24













          related discussion: unix.stackexchange.com/questions/403509/…
          – Aaditya Bagga
          Nov 11 '17 at 18:55




          related discussion: unix.stackexchange.com/questions/403509/…
          – Aaditya Bagga
          Nov 11 '17 at 18:55

















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f402654%2fcifs-pam-mount-disable-nounix-option%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          How to check contact read email or not when send email to Individual?

          Bahrain

          Postfix configuration issue with fips on centos 7; mailgun relay