Windows 10 and Samba File Share (need latest Update) [SOLVED]

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Post Reply
samratsu
Level 1
Level 1
Posts: 10
Joined: Mon Apr 20, 2020 6:20 pm

Windows 10 and Samba File Share (need latest Update) [SOLVED]

Post by samratsu »

Hi,
I have been following the Tutorial viewtopic.php?f=42&t=199907 . Have a few questions to the latest on this topic. I have Windows Home Network with Windows 10 PCs and Laptops. All OSs up-to-date. I have a need to get an old PC up and running with an OS lighter than Windows and yet feels like Windows (for the family). Had been checking out Zorin, Ubuntu, Mint, Debian and presently evaluating Mint Tricia (Mate) as the choice to come out of Windows.
I have tried the steps in the Tutorial. Here's my situation:
  • PC1-nosmb1: Windows 10, SMB1 disabled
  • PC2-smb1: Windows 10, SMB1 active by default (not the one that deactivates automatically)
  • PC3-TMate64: Virtual Machine running Mate on Virtualbox with Bridge connection to PC1-nosmb1 Ethernet. Mate comes up as a separate box in the Network, can track using my Router, received its unique IP from DHCP.
Now,
  1. I can access Windows Share from PC3-TMate64 box. I have modified smb.conf to include Windows Workgroup Name, lanman, ntlm authentication. Have also put max, min client protocol but that doesn't seem to be making any difference. Have implemented WSDD in PC3-TMate64
  • [1.1] PC1-nosmb1 never comes up ever in the Caja Explorer Network view or Nemo. But if I put smb://PC1-nosmb1.local, I can view the shares, access the shares, open files.This doesn't seem to happen at first attempt. I have to run

    Code: Select all

    pidof gvfsd-smb-browse
    Kill $pid
    Then attempt again with smb://PC1-nosmb1. This works till I reboot the Mate64. After reboot, perform the same ritual.
  • [1.2]PC2-smb1 comes up in Network view of the File explorers unlike PC1-nosmb1. Still to access the shares, I must perform the ritual (mentioned above) at first, then access the shares using smb://PC2-smb1
  • [1.3]Windows Workgroup seems to be coming up, not consistently, in the Network view of Caja, Nemo (more consistently). If I rest the PC3-TMate64 a few mins after reboot, chances of seeing Windows Workgroup in the Network view increases. But that's all, I can't get into the Windows PCs without using smb://
  • [1.4]Have also installed Gigolo. It fails to go into the shares and mount, although it can list the shares if I use mDNS. For Domain field, I put Workgroup name, User as the Admin-user of PC3-TMate64. There is a following password prompt where I key in the PC3-TMate64 admin pwd. The error thrown up is "Failed to mount Window share:Connection refused". If I had shares mapped by doing the steps in sub-points 1 and 2 above, those shares come up in the view list of Gigolo.
Reverse Direction: Windows to Linux Lookup
[1] PC1-nosmb1 can see PC3-TMate64 by smb://PC3-TMate64.local . But PC3-TMate64 fails to come up in Network section of File explorer. Able to access Share.
[2] PC2-smb1 can see PC3-TMate64 listed under Network section of File Explorer. Able to access Share. smb:// works too.

So, with WSDD (WSD) on Linux, still I can't see PC3-TMate64 from PC1-nosmb1, listed in Network section of Windows File Explorer...to do that I must enable SMB1.0/CIFS client.I remember PC3-TMate64 coming up briefly and laboriously in Windows File Explorer Network section when I had WSD set up first time. Was not able to access the Linux Share. Then enabled SMB1.0/CIFS client, immediately PC3-TMate64came up in the Network Section and was able to access. Now after removing SMB1.0, PC3-TMate64 fails to come up even once in the File Explorer Network section.

I do not wish to continue using SMB1.0 in Windows. I believe altair4 mentioned at the beginning of the tutorial that without SMB1.0 enabled in Windows, there is no way the Linux box will come up listed under Network in File Explorer of Windows.

Do you see any problem with what the setup mentioned above? Has there been any major progress to do things any differently and subsequently easier, especially the browsing of PCs under Network and accessing Shares, from Linux and Windows?

Thank you for all the help!

Trying to attach to dump text file
dump.zip
testparm, netusers share, avahi-daemon
(1.52 KiB) Downloaded 3 times
Last edited by samratsu on Thu Apr 23, 2020 2:07 am, edited 1 time in total.

samratsu
Level 1
Level 1
Posts: 10
Joined: Mon Apr 20, 2020 6:20 pm

Re: Windows 10 and Samba File Share (need latest Update)

Post by samratsu »

Updt: Made some modifications after an interesting find.
Following
1. viewtopic.php?f=157&t=308761&p=1745108& ... D#p1745108
2. https://github.com/christgau/wsdd/issues/18
3. https://github.com/christgau/wsdd

Modified wsdd.service. Added for IPv4 and IPv6 specific Ethernet interface, with long output:

Code: Select all

ExecStart=/usr/bin/wsdd -i enp0s3 -4 -vv
Changed Sleep to 5. No errors for IPv4 or IPv6. Then removed Network Interface specification. Still no errors.

Then, decided to disable uFW. Immediately Windows Network Neighborhood started reporting the Linux box ! Now something interesting happened. Back in Caja Network space, all Windows PCs started appearing including the Workgroup. I was able to double click inside into Workgroup and see the listing of all PCs in the Network. So, updated using GuFW, created rules:
Rules.PNG
(Plz ignore the spelling)
I intend to update the rules and change the IP range for within the local network only. All the Windows PCs have Kaspersky Internet Security running with Firewall enabled at Network, App and Port levels. So it was a headache trying to understand if and which FW was creating problem.

So, now I will safely remove SMB1.0 from Windows PCs and still be able to access Linux PCs.
The problems mentioned above in my first post continues to remain though, except WSDD. Double clicking on Windows PCs after discovering them in Network section of Caja and Nemo, continues to give:
WindowsPC-ShareAccessError.PNG

altair4
Level 20
Level 20
Posts: 10078
Joined: Tue Feb 03, 2009 10:27 am

Re: Windows 10 and Samba File Share (need latest Update)

Post by altair4 »

Has there been any major progress to do things any differently and subsequently easier, especially the browsing of PCs under Network and accessing Shares, from Linux and Windows?
No. You've pretty much covered it.

We are still dealing with this bug: https://bugs.launchpad.net/gvfs/+bug/1828107 which resulted when they "fixed" another bug: https://bugs.launchpad.net/ubuntu/+sour ... ug/1778322

Host "discovery" then "connection" through the file manager to any samba server that has disabled SMB1 is not possible. gvfsd-smb-browse was modified to drop down to SMB1 to get a list of servers by their NetBIOS names then gets "stuck" at that level so it cannot access any shares for any machine that disabled SMB1. This means Win10 but it will also include Ubuntu 20.04 and anything derived or forked from it like Mint.

The Linux client can still make the connection but it has to be done explicitly smb://win10-host-name.local/share-name for example. This bypasses the gvfsd-smb-browse mess which is why it works. You can always make a bookmark to that location in your file manager or use a CIFS mount. And Win10 can do the same \\linux-host-name.local

If I may get philosophical for a moment: What needs to happen is:

On the Linux client end: There needs to be a WS-Discovery client developed for Linux and MacOS.

On the Linux server end: WS-Discovery needs to be an install-able package in Ubuntu: https://bugs.launchpad.net/ubuntu/+sour ... ug/1831441

On the Win10 client end: Windows needs to be able to "discover" the Samba servers "multicast DNS registration" ( Avahi ) announcement in Explorer the way MacOS and another Linux machine does in their file managers.

On the Win10 server end: Windows needs to do what samba does and use the same type of "multicast DNS registration" to announce its presence to the rest of the network so that Linux and MacOS can "see" it.

WS-Discovery and Avahi ( mDNS ) are both multicast protocols. Windows can use it when aksed explicitly but there may be technical reasons why Windows cannot use both at the same time for discovery. It uses it to discover printers so I don't know why it can't use it to discover a samba / smbx server.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.

samratsu
Level 1
Level 1
Posts: 10
Joined: Mon Apr 20, 2020 6:20 pm

Re: Windows 10 and Samba File Share (need latest Update)

Post by samratsu »

Sorry for the late response, have been working on the Mate64 to get most of the desired software up and running. Struggling a bit with MS Office and other MS programs routinely used by family (were good on Bionic).

I have removed all the rules from uFW and put in just one rule to allow all "incoming" from LAN (outgoing is ON by default). Hope this doesn't compromise the security (as long as LAN is secure).
Rules-2.PNG
Rules-2.PNG (25.82 KiB) Viewed 388 times
I am sure you have heard these before...Thank you for all the help and tutorials @altair4!
One gripe I had and continue to have about Linux as an alternative choice for Windows. Yes, Linux has improved a lot over the years in becoming "less-initiated" friendly but it still has a long way to go. Windows became wildly popular for the single reason that it allowed virtually anyone to adopt easily without bothering about what's going on under the hood. The same analogy goes for all the Windows Administrators (less initiated ones) who became Lords overnight, mainly, because Windows also helped becoming Admins easily, since a lot were still locked away in the hood under the main hood :mrgreen: . While Windows OS these days gives us the option of really getting under the hoods as well as continue to work without being bothered about internal workings, one great thing about MS Windows is that it paved way for a common standard and quality...and almost everyone had to obey those, if they wish to be in the play in that environment.

I absolutely love and appreciate the hands-on approach as demanded by Unix. It has been long I had tried my hands again on System V, Linux variants. Appreciate the Debian strains and the contemporary RHLs, have to revive skills on Kali...but my work keeps me mainly in Windows and Cloud space. Point here is, we really need to get Linux builds done in a way that installtion is user friendly, should work with most of the bells and whistles, right out of the box...maintain a common standard and ensure functional stability (desktop level). What we are doing here gives us a lot of control over the system and at the same time, scares the hell out of newbies. I was able to get my Dad ramp up on Windows Admin, at his age, to safely maintain his home Windows DT, I doubt I can do that with Linux. Mint looks promising though.

I hope you are listing your philosophical views and recording them somewhere either as bugs or demands....we need them! 8) Great Forum you guys have here!

Post Reply

Return to “Newbie Questions”