Menu

#37 FreeBSD 10.3-STABLE - fstab formatting

v1.0 (example)
open
nobody
None
5
2017-12-29
2017-06-07
Mathias H
No

The typical format for Linux boxes is "smbnetfs mountpoint fuse options 0 0"
FreeBSD requires the additional option of mountprog=/path/to/bin/smbnetfs
FreeBSD will attempt to mount and smbnetfs will start, however because there is no source and only a mountpoint in the command structure, this causes unusual errors when the mount operation is performed due to too many parameters being issued via the mount command.
Starting "smbnetfs /mnt/" outside of fstab yields a successful connect to my file server and everything works as it should.

Discussion

  • Mathias H

    Mathias H - 2017-06-07

    I forgot to mention, the usual Linux formatting for Linux boxes in fstab does not work in FreeBSD and throws the errors mentioned.

    https://sourceforge.net/p/smbnetfs/bugs/28/ Addresses this very issue and it was set to invalid.

    I can confirm application of the patch resolves this issue.

     

    Last edit: Mathias H 2017-06-07
  • Mikhail T.

    Mikhail T. - 2017-12-29

    I was having the same problem and found this ticket with Google. The work-around I found is to put one of the options you'd like to pass to smbnetfs into the first column of the fstab-entry. For example, here is, what I have:

    -obig_writes /smb fusefs rw,failok,uid=101,late,mountprog=/opt/bin/smbnetfs
    

    (/opt is what I have for $LOCALBASE -- you, likely, have /usr/local).

    This works because the first field is passed by mount_fusefs to the specified program verbatim -- after the options. So the above entry is turned into the following command:

    /opt/bin/smbnetfs -o rw -o uid=101 -obig_writes /smb 
    

    This is a work-around, not a proper fix -- although I do not like the patch proposed in #28 either. I'd say, the program should, upon encountering two arguments (after the options) instead of one, simply ignore the first one -- without even parsing it ("none" or not).

     

    Last edit: Mikhail T. 2018-01-22

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.