Problem after samba update

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
RowlandP
Level 4
Level 4
Posts: 238
Joined: Tue Jan 26, 2021 7:30 am

Re: Problem after samba update

Post by RowlandP »

This sounds like a SMBv1 problem, do you have these lines in your 20.3 smb.conf

Code: Select all

client min protocol = NT1
server min protocol = NT1
Windows 2k is SMBv1 only and EOL, wouldn't you be better using a Samba AD DC instead ?
SteveR
Level 3
Level 3
Posts: 167
Joined: Fri May 24, 2019 12:02 pm
Location: Morehead City, NC
Contact:

Re: Problem after samba update

Post by SteveR »

In following this thread, a post by altair4 seems to have gotten "lost" from the discussion. The problem may not be with Samba itself, but with gvfsd. See altair4's post of April7th at 5:14PM. He wrote: "It doesn't appear to be a samba issue since the samba client process itself works as it should. You just need to bypass the gvfsd-smb-browse process ... I have no idea how to fix a gvfs bug."
RobertX
Level 4
Level 4
Posts: 261
Joined: Thu Apr 12, 2012 6:09 pm

Re: Problem after samba update

Post by RobertX »

Does this help? https://ubuntu-mate.community/t/how-to- ... ed%20again.

I haven't tried it yet, but considering that Mint MATE and Ubuntu MATE are close cousins, I'd just thought it might help.

Me, I have no cause to worry about it since I don't have Windows 2000, although I have Windows XP as a guest system on my Virtualbox ecosystem. I thought I'd contribute for once on this board.

EDIT: Shoot, it didn't work for me.
RowlandP
Level 4
Level 4
Posts: 238
Joined: Tue Jan 26, 2021 7:30 am

Re: Problem after samba update

Post by RowlandP »

I have already said this, there is nothing wrong with Samba, it works. The problem is with the various tools that work with Samba, gvfs etc. They need to understand that SMBv1 is going away and to use SMBv2 and up, along with Network Discovery.
RobertX
Level 4
Level 4
Posts: 261
Joined: Thu Apr 12, 2012 6:09 pm

Re: Problem after samba update

Post by RobertX »

RowlandP wrote: Sun May 01, 2022 4:08 am I have already said this, there is nothing wrong with Samba, it works. The problem is with the various tools that work with Samba, gvfs etc. They need to understand that SMBv1 is going away and to use SMBv2 and up, along with Network Discovery.
All right, you've made your point.
dcbtahoe
Level 1
Level 1
Posts: 7
Joined: Mon Jan 24, 2022 10:25 pm

Re: Problem after samba update

Post by dcbtahoe »

My problem is I still test old systems that use smb1 ... so I suck it up buttercup ?

this was a post from 8 months ago ...
https://askubuntu.com/questions/1357636 ... se-amd-nt1
GVFS SMB Browse and NT1
...
It's still a bug
https://bugs.launchpad.net/gvfs/+bug/1828107
gvfs can't list shares from smb servers that disabled SMB1
SteveR wrote: Fri Apr 29, 2022 7:57 pm In following this thread, a post by altair4 seems to have gotten "lost" from the discussion. The problem may not be with Samba itself, but with gvfsd. See altair4's post of April7th at 5:14PM. He wrote: "It doesn't appear to be a samba issue since the samba client process itself works as it should. You just need to bypass the gvfsd-smb-browse process ... I have no idea how to fix a gvfs bug."
Hillybilly
Level 1
Level 1
Posts: 23
Joined: Mon May 12, 2014 4:03 am

Re: Problem after samba update

Post by Hillybilly »

07 May 22. After selective install of updates - timeshift -reboot my issue is totally down to networkd-dispatcher update
rene
Level 20
Level 20
Posts: 12212
Joined: Sun Mar 27, 2016 6:58 pm

Re: Problem after samba update

Post by rene »

Hillybilly wrote: Sat May 07, 2022 5:16 am 07 May 22. After selective install of updates - timeshift -reboot my issue is totally down to networkd-dispatcher update
Reviewing the thread we do not seem to in fact know what your issue is but especially seeing as how Mint does not even use systemd-networkd (for which networkd-dispatcher is a service) this would seem quite unlikely.
urdrwho
Level 5
Level 5
Posts: 566
Joined: Mon Mar 13, 2017 11:13 am

Re: Problem after samba update

Post by urdrwho »

Agree! The point has been made but that doesn't mean that shoe is going to be an easy fit. I'm months shy of 70 years old, live with my wife and about 7 different computers. My main one, the one that runs everything from answering machine to my business is still Win7. It is Win because of proprietary software and I don't feel like spending several $thousand to upgrade the software. I want to retire.

So to me, I am not worried all that much about the scary unsafe SMBv1. Heck I boot my stuff without passwords. Imagine that!?!?! Yeah, I know there are many purists that think the devil himself would appear without password protection in my own home.
RobertX wrote: Sun May 01, 2022 2:44 pm
RowlandP wrote: Sun May 01, 2022 4:08 am I have already said this, there is nothing wrong with Samba, it works. The problem is with the various tools that work with Samba, gvfs etc. They need to understand that SMBv1 is going away and to use SMBv2 and up, along with Network Discovery.
All right, you've made your point.
RobertX
Level 4
Level 4
Posts: 261
Joined: Thu Apr 12, 2012 6:09 pm

Re: Problem after samba update

Post by RobertX »

I guess it's a thit for that.

GNU/Linux, especially the other Ubuntu-based distros, is free of charge, but you have to put up with technical problems because of no warranty.

I'm not saying it's terrible, indeed most of GNU/Linux OSes are very good at what they're known for, but the price tag doesn't mean that there are no strings attached.

Now, I hope things will turn out for the best, but just keep your eyes and ears at full vigilance.
dhmsjs
Level 1
Level 1
Posts: 1
Joined: Thu Jun 09, 2022 6:43 pm

Re: Problem after samba update

Post by dhmsjs »

Just confirming that @josebarg's procedure also worked for me to restore file sharing/browsing on my LM20.3 laptop in a mixed network of LM17, LM18, Win10 and Win7 machines and including an old (but still useful!) NAS.

Yes prior to the downgrade, substituting the machine's ip address in place of hostname did work. So yes one might argue that this is not a Samba problem per se. And one might technically be correct. But practically, downgrading the "samba" package from .2 to .1 does restore the expected behavior. So in that sense and in this specific context it is still a "Samba package" problem.

I suspect there was more that changed in the .1 to .2 update than just fixing the network printing issue that generated that update. But I was not smart enough to be able to find a likely culprit after perusing the bug fix discussion.

Also confirming that downgrading via Synaptic does *not* work -- possibly because Synaptic doesn't follow the specific order in josebarg's post?? It fails because dependent packages get marked as locked and then can't be removed/replaced.

For me after downgrading, both client and server min protocols needed to be set to NT1 in smb.conf on the LM20 machine before I could connect to it using its hostname. Prior to that the LM20 machine could browse and connect to other machines, but any attempt to connect to the LM20 machine would fail with either a "connection timed out" or "unable to retrieve share list from server" error.

One somewhat subtle detail in my network that may also affect others is that I force one of my old LM17 machines to be the local master browser -- so it is using older Samba versions and presumably older (pre Win10) protocols. That might be why it was difficult for me to connect using hostname instead of ip address without first setting min client *and* server protocols to NT1 on the LM20 machine.
urdrwho
Level 5
Level 5
Posts: 566
Joined: Mon Mar 13, 2017 11:13 am

Re: Problem after samba update

Post by urdrwho »

Errr! Ugh!

Came over to this computer, saw some upgrades and completed them. The last time I had to go through this Samba issue, downgrade fixed it and I thought I stopped any upgrades for Samba. Not so and the upgrade changed something so I had to go through the entire downgrade again.

If I have to do this again, would the chain below work?

Code: Select all

sudo apt-get remove python3-samba -y && apt-get remove samba-dsdb-modules -y && apt-get remove libsmbclient -y && apt-get remove samba -y && apt-get remove samba-vfs-modules -y && apt-get remove smbclient -y && apt-get remove samba-libs -y && apt-get remove libwbclient0 -y && sudo apt-get remove samba-common-bin -y && apt-get remove samba-common -y


sudo apt-get install libwbclient0=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install samba-libs=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install python3-samba=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install samba-dsdb-modules=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install libsmbclient=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install samba-common=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install samba-common-bin=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install samba=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install samba-vfs-modules=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install smbclient=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y && apt-get install gvfs-backends -y

josebarg wrote: Tue Apr 12, 2022 4:00 pm Here is what I did to restore samba to the older version manually without using TimeShift.

Make a timeshift restore point, just in case something goes wrong.

1. Check Samba Packages cache
Open a console and type this command

Code: Select all

sudo apt-cache showpkg samba
At the very end of the information given as result you will see something like:
2:4.13.17~dfsg-0ubuntu0.21.04.2
2:4.13.17~dfsg-0ubuntu0.21.04.1
2:4.11.6+dfsg-0ubuntu1

If you don't see this exact version "2:4.13.17~dfsg-0ubuntu0.21.04.1", read the entire post carefully, cos you will need to change some command

These are the packages in your system cache available to install manually, the version that causes all this problems is the one ended in ".2"
So we are going to uninstall version named "2:4.13.17~dfsg-0ubuntu0.21.04.2"
And we will replace it with the one before named "2:4.13.17~dfsg-0ubuntu0.21.04.1" depending on when you have been doing updates you could have an older version available instead. We just need to use the most recent one before the named "2:4.13.17~dfsg-0ubuntu0.21.04.2"

2. Remove Samba
Ok first, we need to uninstall all samba packages, so execute the following commands one at the time, make sure to do not skip one, and respect the execution order.

Before start close any package manager like "synaptic" and the "update manager"if you had them open or minimized.

Code: Select all

sudo apt-get remove python3-samba -y
sudo apt-get remove samba-dsdb-modules -y
sudo apt-get remove libsmbclient -y
sudo apt-get remove samba -y
sudo apt-get remove samba-vfs-modules -y
sudo apt-get remove smbclient -y
sudo apt-get remove samba-libs -y
sudo apt-get remove libwbclient0 -y
sudo apt-get remove samba-common-bin -y
sudo apt-get remove samba-common -y
3. Install Old Samba
Ok Now lets install the older version, this command is assuming you have in you cache the version "2:4.13.17~dfsg-0ubuntu0.21.04.1" if you have another version to replace you will need to adjust the commands. For example if your available version was "2:4.11.6+dfsg-0ubuntu1", the first command would be "sudo apt-get install libwbclient0=2:4.11.6+dfsg-0ubuntu1 -y"

The only command we don't need to indicate the version is the last one as you see, cos is not samba but a dependency.
Again, execute the following commands one at the time in this order, make sure to do not skip one and respect the execution order.

Code: Select all

sudo apt-get install libwbclient0=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install samba-libs=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install python3-samba=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install samba-dsdb-modules=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install libsmbclient=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install samba-common=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install samba-common-bin=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install samba=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install samba-vfs-modules=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install smbclient=2:4.13.17~dfsg-0ubuntu0.21.04.1 -y
sudo apt-get install gvfs-backends -y
Ok reboot the computer and see if network problem is fixed, please note after this you may need to reinstall some addon packages like "share" packages for file manager if you need them to use the share folder option in file manager, just use mint software manager to download it again.

Hope this works for you as well.

Remember to uncheck Samba next time you do an Update in Linux Mint to avoid to install the problematic version again, or use right mouse click in "Samba" inside update list to add it to the exclusion list.
Reddog1
Level 7
Level 7
Posts: 1939
Joined: Wed Jun 01, 2011 2:12 pm

Re: Problem after samba update

Post by Reddog1 »

You know that you can lock samba to the version that you are using and the update manager will not install/update your packages?

System>SynapticPackageManager
Search for 'samba' and any samba package that is marked as installed, highlight by a right-click, Open Package in the top bar and then check 'Lock Version'. The package will turn red to indicate that it is 'locked' and cannot be changed/updated until it is unlocked.

Whether you should do this is up to you, the user. With linux, we have choices.

I lock the kernels on my host systems until I prove that a kernel update doesn't break things (proved by updating the kernels in a virtual machine). We have choices.
urdrwho
Level 5
Level 5
Posts: 566
Joined: Mon Mar 13, 2017 11:13 am

Re: Problem after samba update

Post by urdrwho »

I'll go back and check but I thought that I had locked last time???
SteveR
Level 3
Level 3
Posts: 167
Joined: Fri May 24, 2019 12:02 pm
Location: Morehead City, NC
Contact:

Re: Problem after samba update

Post by SteveR »

Fixed!! :D
A recent update to Mint 20.3 (August ??, 2022) resolved the "Unable to mount location Failed to retrieve share list from server: No such file or directory" issue. Samba works as expected.
Have not yet updated to Mint 21 yet.
dcbtahoe
Level 1
Level 1
Posts: 7
Joined: Mon Jan 24, 2022 10:25 pm

Re: Problem after samba update

Post by dcbtahoe »

I know this is old but,,,, I went back to re-look at this problem and went to the samba setup instructions for a AD-DC and notice the resolver config was for a fixed resolv config ... After doing that and then rejoining my W2K domain...
The share searching and access was golden ... Thanks to everyone... now looking at install or upgrade? Mint21 !!!

https://wiki.samba.org/index.php/Settin ... Controller
https://wiki.samba.org/index.php/Settin ... S_Resolver
https://wiki.samba.org/index.php/Settin ... ain_Member

https://wiki.samba.org/index.php/Joinin ... _Directory

This is really helpful:
https://wiki.samba.org/index.php/Distri ... stallation
....
Perform Step 4: Disabling the DNS Resolver

https://serverfault.com/questions/44240 ... g-in-linux
Does anyone have real world scenarios where they've used the immutable flag in Linux?

chattr +i file.txt

Oh yes ! for a fixed /etc/resolv.conf on mint ...

https://askubuntu.com/questions/732748/ ... esolv-conf
https://tuxxie-linux.blogspot.com/2013/ ... vconf.html




Since nothing had worked for me I decided to try that ... and
RowlandP
Level 4
Level 4
Posts: 238
Joined: Tue Jan 26, 2021 7:30 am

Re: Problem after samba update

Post by RowlandP »

dcbtahoe wrote: Tue Oct 18, 2022 1:04 pm
This is really helpful:
https://wiki.samba.org/index.php/Distri ... stallation
....
Perform Step 4: Disabling the DNS Resolver

https://serverfault.com/questions/44240 ... g-in-linux
Does anyone have real world scenarios where they've used the immutable flag in Linux?

chattr +i file.txt
Oh drat, who added that, probably whoever added the rest of the extraneous information to a page that is supposed to just list the packages for each distro.

A Samba DC is supposed to have a fixed IP and NOTHING is supposed to change any files (/etc/hosts, /etc/resolv.conf etc) and if something is, then you need to find out what is doing this and stop that from doing it.
Off to rewrite the wikipage :(
Locked

Return to “Networking”