Re: Deprecating smbfs(5) and removing it before FreeBSD 14

From: Tomoaki AOKI <junchoon_at_dec.sakura.ne.jp>
Date: Fri, 29 Oct 2021 07:47:02 +0900
On Thu, 28 Oct 2021 17:37:33 +0200
Miroslav Lachman <000.fbsd_at_quip.cz> wrote:

> On 28/10/2021 16:44, Ed Maste wrote:
> > The smbfs(5) filesystem supports only the obsolete SMBv1 protocol, and
> > I propose removing it for FreeBSD 14. I know the CHERI folks have been
> > using it but they plan to migrate away from it. It was broken for
> > months before they fixed it, so I suspect nobody is using it on
> > contemporary releases.
> > 
> > I have review D32707 (https://reviews.freebsd.org/D32707) open to add
> > this deprecation notice to the man page:
> >       The smbfs filesystem driver supports only the obsolete SMBv1 protocol.
> >       smbfs and userspace counterparts smbutil(1) and mount_smbfs(8) are not
> >       present in FreeBSD 14 and above.  Users are advised to evaluate the
> >       sysutils/fusefs-smbnetfs port instead.
> > 
> > A similar notice would be added to the smbutil and mount_smbfs man
> > pages, and manu_at_ suggested having the userland utilities emit a
> > warning when they are used.
> > 
> > I am interested in comments, objections, or reports that anyone is in
> > fact using smbfs.
> 
> I am working for one company where smbfs is heavily used to connect 
> Windows / MacOS / Linux / FreeBSD (12.2) machines and we are really sad 
> that FreeBSD's mount_smbfs does not support SMBv2 / SMBv3 protocols (so 
> we are using SMBv1 with all the risk). I tried fusefs alternatives from 
> the ports tree in the past but it never worked as is needed. From our 
> point of view smbnetfs cannot replace mount_smbfs.
> I cannot found any good examples of how to configure it to mount about 
> 20 shares from /etc/fstab on boot as user root from different hosts with 
> different login, passwords and mount options to defined mount points.
> Everything seems to be very differently designed to work for non-root 
> user with configuration in users home, not system wide and mounting in 
> some strange hierarchy. (and bad performance was cited by many on other 
> platforms too)

I, as an end-user who need to access local NAS, tried it a few yearsago
(when it once broken by struct sockbuf issue that I finally
sent patch) and had concluded smbnetfs is unusable for me.
Additionally, it was quite unstable ATM. Sudden forcible unmount and
failing remount.

If it worked as expected, I wouldn't have tried digging into and sent
Bug 182963.

BTW, current in-tree code is broken for me and mandated patch proposed
on Bug 90815. There are 3 patches uploaded and I use second one for
years. Third one worked, too when I tried, but not continually using.
The first one would no longer applicable.


> It was discussed in the past in some other FreeBSD mailinglist that it 
> is not so easy to implement SMBv2 in to mount_smbfs. But is there any 
> possibility to make it as some sponsored work? What about FreeBSD 
> Foundation? There were some paid projects in the past. Or some other 
> bounty program. Is there anybody who have the skill to implement it if 
> there is good amount of $?

+1 for FreeBSD Foundation project.
But possibly we need to delete current smbfs code from base and switch
to ports (sysutils/*?) if it require some code having incompatible
license for base.

Anyway, please don't remove it unless usable alternative appears.


> If I am "well informed" FreeBSD is the only widely used OS not 
> supporting SMBv2. (MacOS, Linux, Solaris have it supported)
> I will be really glad "if somebody can fix it" in the base.
> 
> (or at least document how to use smbnetfs the way mount_smbfs is used)
> 
> Kind regards
> Miroslav Lachman
> 


-- 
Tomoaki AOKI    <junchoon_at_dec.sakura.ne.jp>
Received on Thu Oct 28 2021 - 22:47:02 UTC

Original text of this message