hivetech
Posts: 3
Joined: Sun Jun 04, 2017 12:59 am
Location: CH

SMB shares failed to connect

Sun Jun 04, 2017 1:14 am

Hi folks

I disabled SMB1 on all my storage systems (mostly Synology) after WannaCry, it didn't affect me directly but you never know.
After I did that, Solus was not willing to connect anymore, because it tries to connect via SMB1 but doesn't try a higher version.
It gives the error "Failed to retrieve share list from server: Connection timed out."
Solution is to enforce at least SMB2 via "/etc/samba/smb.conf" with the following two lines inside the "global" section:
client min protocol = SMB2
client max protocol = SMB3


After adding the lines via your desired editor, restart samba;

Code: Select all

sudo systemctl restart smb.service
and verify via

Code: Select all

samba-tool testparm
if the lines are added and no errors show up.

Finally connections will work again!

@solus devs: probably consider to ship this as default because SMB1 is really dead now, just sayin'

sunnyflunk
Development Team
Posts: 2743
Joined: Sun Mar 13, 2016 11:35 pm

Re: SMB shares failed to connect

Tue Jun 06, 2017 8:09 am

hivetech wrote:
Sun Jun 04, 2017 1:14 am
Hi folks

I disabled SMB1 on all my storage systems (mostly Synology) after WannaCry, it didn't affect me directly but you never know.
After I did that, Solus was not willing to connect anymore, because it tries to connect via SMB1 but doesn't try a higher version.
It gives the error "Failed to retrieve share list from server: Connection timed out."
Solution is to enforce at least SMB2 via "/etc/samba/smb.conf" with the following two lines inside the "global" section:
client min protocol = SMB2
client max protocol = SMB3


After adding the lines via your desired editor, restart samba;

Code: Select all

sudo systemctl restart smb.service
and verify via

Code: Select all

samba-tool testparm
if the lines are added and no errors show up.

Finally connections will work again!

@solus devs: probably consider to ship this as default because SMB1 is really dead now, just sayin'
This would be a good one to put on https://dev.solus-project.com/ to get it integrated into the package

hivetech
Posts: 3
Joined: Sun Jun 04, 2017 12:59 am
Location: CH

Re: SMB shares failed to connect

Fri Nov 17, 2017 11:57 pm

Sorry for the long off-time
Is this already done yet, or should I jump into the gap?
If yes, then I definitely need a starter guide for how to change that :P

EDIT: I just tested again on a newly installed system without the changes and it seems that they are no longer needed!

ermo
Posts: 2
Joined: Mon Nov 20, 2017 2:49 pm

Re: SMB shares failed to connect

Mon Nov 20, 2017 3:07 pm

hivetech wrote:
Fri Nov 17, 2017 11:57 pm
Sorry for the long off-time
Is this already done yet, or should I jump into the gap?
If yes, then I definitely need a starter guide for how to change that :P

EDIT: I just tested again on a newly installed system without the changes and it seems that they are no longer needed!
I'm looking into the samba stuff and your report has been noted. No need to do anything else.

I'll include a link to the relevant commit(s) once we get this sorted once and for all. :ugeek:

Pyrrhic
Posts: 12
Joined: Mon Jan 09, 2017 1:45 pm

Re: SMB shares failed to connect

Thu Dec 14, 2017 9:31 pm

! Thank you! My god, finally I can samba again! That really had been driving me crazy for the best part of a year now. GENIUS!

ermo
Posts: 2
Joined: Mon Nov 20, 2017 2:49 pm

Re: SMB shares failed to connect

Mon Jan 22, 2018 11:51 pm

The samba work I've done, which includes a default but user-overrideable configuration, landed in stable a little over a week ago.

Please let us know if you experience any issues. Thanks. :)

Return to “Tutorials”