[Bug 245704] sysutils/fusefs-smbnetfs script to mount using /etc/fstab

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Fri Apr 17 17:55:06 UTC 2020


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=245704

            Bug ID: 245704
           Summary: sysutils/fusefs-smbnetfs script to mount using
                    /etc/fstab
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: ports-bugs at FreeBSD.org
          Reporter: dave+freebsd at fullard.ca
                CC: mi at ALDAN.algebra.com
                CC: mi at ALDAN.algebra.com
             Flags: maintainer-feedback?(mi at ALDAN.algebra.com)

Created attachment 213507
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=213507&action=edit
mount script

I've written a short mount script for fusefs-smbnetfs to allow it to be used
from /etc/fstab.

I'd like (if possible) to get it added to the sysutils/fusefs-smbnetfs port to
allow others to use.

I know in the traditional sense that smbnetfs is supposed to be run per-user,
but this would allow all users and processes to be able to use SMB shares. It
does require configuration for fstab to be place in /.smb with the
smbnetfs.conf, smbnetfs.auth (not required) and a copy of smb.conf (not
required as defaults will be used). I've put this config in
/usr/local/etc/smbnetfs and created a symlink to /.smb. It's possible to use
the `-o config=/path/to/smbnetfs.conf`, but smbnetfs throws a warning about not
being able to find smb.conf as it will be looking for it in $USER/.smb. Maybe
this is something smbnetfs can be patched to handle.

The attached script is placed into /usr/local/sbin/mount_smbnetfs.

The line to add to /etc/fstab to use the script would then be:

    smbnetfs        /smb            smbnetfs       
rw,late,failok,allow_other,mountprog=/usr/local/sbin/mount_smbnetfs     0      
0

This would then create /smb as a special mount, allowing all users to browse
SMB shares, for example:

    cd /smb/user:pass at host/share

If the smbnetfs.auth file is present and configured, then browsing to
/smb/host/share would work.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-ports-bugs mailing list