Bind-mount a CIFS filesystem

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











up vote
0
down vote

favorite












I've been trying to set up my samba shares to mount in my home directory (//xxx.xxx.xxx.xxx/homes/mika/music to /home/mika/Musik and so on), but the bind option which I want to save local copies on the server and on my laptop won't let me do it.



I tried with fstab:



//xxx.xxx.xxx.xxx/homes/mika/music /home/mika/Musik cifs user=mika,password=password,rw,x-gvfs-hide,bind 0 0


Which resulted in the ~/Musik folder being owned by root (uid,gid and user options don't change it). I am using the user and password option for debugging purposes. I tried mounting it with a systemd unit, but:



 home-mika-Musik.mount - Music share
Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
Active: active (mounted) since Sat 2017-10-14 18:20:00 CEST; 3s ago
Where: /home/mika/Musik
What: /dev/sda2
Process: 4677 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
Process: 4730 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
Process: 4732 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,bind,x-gvfs-hide (code=exited, status=0/SUCCESS)
Tasks: 0 (limit: 4915)
CGroup: /system.slice/home-mika-Musik.mount


Without bind:



home-mika-Musik.mount - Music share
Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
Active: active (mounted) since Sat 2017-10-14 18:21:11 CEST; 2s ago
Where: /home/mika/Musik
What: //192.168.178.30/homes/mika/music
Process: 4778 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
Process: 4780 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,x-gvfs-hide (code=exited, status=0/SUCCESS)
Tasks: 0 (limit: 4915)
CGroup: /system.slice/home-mika-Musik.mount


The bind option changes the "What=" output of systemctl status home-mika-Musik.mount.



Any idea or am I too stupid to google and I don't know that cifs doesn't support binding?







share|improve this question


























    up vote
    0
    down vote

    favorite












    I've been trying to set up my samba shares to mount in my home directory (//xxx.xxx.xxx.xxx/homes/mika/music to /home/mika/Musik and so on), but the bind option which I want to save local copies on the server and on my laptop won't let me do it.



    I tried with fstab:



    //xxx.xxx.xxx.xxx/homes/mika/music /home/mika/Musik cifs user=mika,password=password,rw,x-gvfs-hide,bind 0 0


    Which resulted in the ~/Musik folder being owned by root (uid,gid and user options don't change it). I am using the user and password option for debugging purposes. I tried mounting it with a systemd unit, but:



     home-mika-Musik.mount - Music share
    Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
    Active: active (mounted) since Sat 2017-10-14 18:20:00 CEST; 3s ago
    Where: /home/mika/Musik
    What: /dev/sda2
    Process: 4677 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
    Process: 4730 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
    Process: 4732 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,bind,x-gvfs-hide (code=exited, status=0/SUCCESS)
    Tasks: 0 (limit: 4915)
    CGroup: /system.slice/home-mika-Musik.mount


    Without bind:



    home-mika-Musik.mount - Music share
    Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
    Active: active (mounted) since Sat 2017-10-14 18:21:11 CEST; 2s ago
    Where: /home/mika/Musik
    What: //192.168.178.30/homes/mika/music
    Process: 4778 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
    Process: 4780 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,x-gvfs-hide (code=exited, status=0/SUCCESS)
    Tasks: 0 (limit: 4915)
    CGroup: /system.slice/home-mika-Musik.mount


    The bind option changes the "What=" output of systemctl status home-mika-Musik.mount.



    Any idea or am I too stupid to google and I don't know that cifs doesn't support binding?







    share|improve this question
























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      I've been trying to set up my samba shares to mount in my home directory (//xxx.xxx.xxx.xxx/homes/mika/music to /home/mika/Musik and so on), but the bind option which I want to save local copies on the server and on my laptop won't let me do it.



      I tried with fstab:



      //xxx.xxx.xxx.xxx/homes/mika/music /home/mika/Musik cifs user=mika,password=password,rw,x-gvfs-hide,bind 0 0


      Which resulted in the ~/Musik folder being owned by root (uid,gid and user options don't change it). I am using the user and password option for debugging purposes. I tried mounting it with a systemd unit, but:



       home-mika-Musik.mount - Music share
      Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
      Active: active (mounted) since Sat 2017-10-14 18:20:00 CEST; 3s ago
      Where: /home/mika/Musik
      What: /dev/sda2
      Process: 4677 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
      Process: 4730 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
      Process: 4732 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,bind,x-gvfs-hide (code=exited, status=0/SUCCESS)
      Tasks: 0 (limit: 4915)
      CGroup: /system.slice/home-mika-Musik.mount


      Without bind:



      home-mika-Musik.mount - Music share
      Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
      Active: active (mounted) since Sat 2017-10-14 18:21:11 CEST; 2s ago
      Where: /home/mika/Musik
      What: //192.168.178.30/homes/mika/music
      Process: 4778 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
      Process: 4780 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,x-gvfs-hide (code=exited, status=0/SUCCESS)
      Tasks: 0 (limit: 4915)
      CGroup: /system.slice/home-mika-Musik.mount


      The bind option changes the "What=" output of systemctl status home-mika-Musik.mount.



      Any idea or am I too stupid to google and I don't know that cifs doesn't support binding?







      share|improve this question














      I've been trying to set up my samba shares to mount in my home directory (//xxx.xxx.xxx.xxx/homes/mika/music to /home/mika/Musik and so on), but the bind option which I want to save local copies on the server and on my laptop won't let me do it.



      I tried with fstab:



      //xxx.xxx.xxx.xxx/homes/mika/music /home/mika/Musik cifs user=mika,password=password,rw,x-gvfs-hide,bind 0 0


      Which resulted in the ~/Musik folder being owned by root (uid,gid and user options don't change it). I am using the user and password option for debugging purposes. I tried mounting it with a systemd unit, but:



       home-mika-Musik.mount - Music share
      Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
      Active: active (mounted) since Sat 2017-10-14 18:20:00 CEST; 3s ago
      Where: /home/mika/Musik
      What: /dev/sda2
      Process: 4677 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
      Process: 4730 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
      Process: 4732 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,bind,x-gvfs-hide (code=exited, status=0/SUCCESS)
      Tasks: 0 (limit: 4915)
      CGroup: /system.slice/home-mika-Musik.mount


      Without bind:



      home-mika-Musik.mount - Music share
      Loaded: loaded (/proc/self/mountinfo; enabled; vendor preset: disabled)
      Active: active (mounted) since Sat 2017-10-14 18:21:11 CEST; 2s ago
      Where: /home/mika/Musik
      What: //192.168.178.30/homes/mika/music
      Process: 4778 ExecUnmount=/usr/bin/umount /home/mika/Musik -c (code=exited, status=0/SUCCESS)
      Process: 4780 ExecMount=/usr/bin/mount //192.168.178.30/homes/mika/music /home/mika/Musik -t cifs -o username=mika,password=password,x-gvfs-hide (code=exited, status=0/SUCCESS)
      Tasks: 0 (limit: 4915)
      CGroup: /system.slice/home-mika-Musik.mount


      The bind option changes the "What=" output of systemctl status home-mika-Musik.mount.



      Any idea or am I too stupid to google and I don't know that cifs doesn't support binding?









      share|improve this question













      share|improve this question




      share|improve this question








      edited Oct 14 '17 at 16:46









      Hunter.S.Thompson

      4,56431334




      4,56431334










      asked Oct 14 '17 at 16:42









      Mika Beckerich

      114




      114

























          active

          oldest

          votes











          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%2f398133%2fbind-mount-a-cifs-filesystem%23new-answer', 'question_page');

          );

          Post as a guest



































          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f398133%2fbind-mount-a-cifs-filesystem%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