Linux Mint – Windows File Sharing Just Works

Samba Built In
Samba Built In

Hurray! Windows File Sharing just works in Linux Mint 17!

It’s been a long time since I tried it.  Back in 2010 when I was using Ubuntu, I wrote a post about how to set up Samba, and WinBind to get network sharing going and was quite disappointed that it wasn’t working. Well, that process was so cumbersome that I haven’t used it much over the years and in spite of the fact that about half of my computers are Linux, I haven’t bothered to set it up, or check to see how things have progressed. But I was sharing files recently and lo and behold, it works just fine!

As you can see from this picture, I am looking into a share from a Linux Mint 17 system into a Windows 10 system and can see and read those files. The Windows 10 system drives are shared read/only, as is the best practice. More about that later. But here is what you can expect if you have a mixed network, and how you can use Windows File sharing between Windows 10 and Linux Mint 17.

First of All

First let me set some expectations.

  • I have several Windows 10 systems, so I can’t really talk about Windows 7 or 8. Your mileage may vary.
  • All my systems share whole drives, basically each of the drives, as Read Only. There is only one drive that is Read / Write and it is the one that holds things I want backed up automatically to the cloud. Using Carbonite by the way. They don’t seem to mind if you back up one computer, but shovel a whole network onto that computer. I back up a couple of hundred GB this way.
  • There are three Linux Mint systems, one Linux Mint VM on my primary Windows machine, and four Windows 10 systems.
  • I’ll complete some more detailed testing later, but these are the initial results of just giving it a try.

All the Software is Built-In and Configured

Unlike the previous Ubuntu system, LM17 comes with all the software pre-installed and configured. I didn’t have to do anything. I started with my previous instructions and when I couldn’t find “WinBind” in the software manager, I just gave the whole thing a try with the LM17 install as it was Out of the Box.

Seeing the Windows Network From LM17

Update: These pictures were taken from a Linux Mint 17 Guest running on a Windows 10 VirtualBox Host. This should not have worked, and I cannot reproduce these results. I cannot account for that. See the update information at the bottom of the post. However, when communicating between a LM17 host and Windows 10 Host on the same network segment, these results are correct and can be reproduced.

To see the Windows Network, open a file manager and choose network under the Go menu.

File Manager Go Menu
File Manager Go Menu

This will take you to the network panel:

Go Network
Go Network

The network view shows the Linux systems and the Windows Network as a folder. To go to the Windows Network, just click on it.

It takes a while
It takes a while

Oddly, it takes a while to open the windows network, even if you have already done this. But it’s only about 15-20 seconds. At that point you can see the windows network:

Windows Network
Windows Network

My Workgroup name is WINDYWEATHER, so this appears, along with the default workgroup of WORKGROUP.

WORKGROUP
WORKGROUP

The WORKGROUP is of course, the Linux systems on my network because I have never bothered to change the default workgroup to WINDYWEATHER. And I have not established shares on those systems either, but I may do so in the future.

Default Share on Armor30
Default Share on Armor30

Here is the default share on one of the Linux Mint systems.

If you navigate to a Windows system you get a very reasonable file window:

A90_01006
Windows computers

If you then navigate within those computers, you can drill down into their shares:

See Files on Other Systems
See Files on Other Systems

You can see files on both the Host and other Window systems on the network. The shared drive is automatically mounted.

Reaching the Win 10 Host
Reaching the Win 10 Host

I did need to enter my windows password and I saved this permanently. My usernames and passwords are all the same on all my systems. Again, your mileage may vary. Also, beware if you are logging into Windows 10 using your Microsoft Cloud account rather than a local login. I’m not going to test this case.

Another interesting thing is that you can ping the Windows Systems, which did not work in the past.

Ping Other Systems on the Network
Ping Other Systems on the Network

When you are done, just UnMount the share.

As you can see above, the share appears as a mount point in the file manager on the left hand folder tree. To stop using the share, just UnMount it with a right click as is the normal Linux practice.

A90_01007
Unmount when done

That’s all there is to read shared files from Windows 10 to LM17.

Sharing Linux Mint Files

To share Linux files two things are required. One is that the Linux system must be on the same local network as the target system. Note that in the previous case ( Linux reading a Windows 10 share ), the networks were not the same. The LM17 system is running in a VirtualBox VM, which establishes a separate network inside the host computer. In this case, the Linux system is able to reach outside and reach the Windows 10 system. But it is not able to reach into another network. My home network is roughly as follows:

Local Network
Local Network

What I found was the I could reach into the Windows 10 system from the Linux VM, and into a Linux box on the same router, but not into a Linux system on Router Two. So the Samba Windows sharing will not reach across NAT routers. But it will reach across the VirtualBox software router. Perhaps this would work if Router Two had windows file sharing ports opened in it.

To create a share on Linux, right click on the folder in the right Tree of the file manager and choose sharing:

S1WRQ8~W
Create a Linux Share

The name defaults to the user name, but this in general seemed to always cause a problem. Also the length of the share name is quite restricted. Since my network is private, I allowed guest access to avoid any password issues.

The next case is to look for this share from the Virtual Machine Linux running inside the Windows 10 system.

Looking from Linux VM to a Real Linux system.
Looking from Linux VM to a Real Linux system.

This works fine. Use GO > Network to find the system and then find the share and open it.

Looking from a Windows 10 system into the Linux system looks like this:

Windows 10 Looking Into a Linux System
Windows 10 Looking Into a Linux System

So all the interesting sharing works among systems as long as they are on the same LAN segment. Or perhaps multiple segments work if the Nat Router is opened appropriately.

Enjoy,
ww

Update:

Using a Windows 10 host and a Linux Mint 17 guest, Virtual Box version 5.0.6 is required. This version fixes some bugs in Bridged Adapter for Windows 10.

From Linux VM Guests to Windows Host Networks

Use the Bridged Adapter type to communicate back to the host and to the external network.

Use the Bridged Adapter in the Guest
Use the Bridged Adapter in the Guest

An earlier version of VirtualBox had a bug that prevented the “Bridged Adapter” from working with Windows 10. This adapter does not filter any of the protocols and this allows Windows file services to work in both directions.

For the purposes of this test, I have edited the /etc/samba/smb.conf file to put the LM17VM on the WINDYWEATHER workgroup. After editing the file with “sudo gedit /etc/samba/smb.conf” to change the workgroup name, I restarted the LM17 guest to make sure the changes took effect. Once this is done, the LM17 Guest can see the WIndows 10 Host for file sharing.

See All Windows Machines
See All Windows Machines
Reaching the Win 10 Host
Reaching the Win 10 Host

In this case, Armor90 is the Windows 10 host and I’m establishing a permanent password for access to those accounts. There will also be a prompt to authenticate access to the local key ring.

See Files on Another System
See Files on Other Systems

Once the connection is made, the Windows 10 host files are accessible from the LM17 guest.

Now let’s look back from the Windows 10 system to the LM17 guest.

Windows 10 Host Files
LM17 Guest files seen from the Win10 Host

Doing this in the normal way from the file explorer, we can see the LM17VM guest machine and the files that were established by sharing the user directory with the name darrellVM. Do this as above by choosing properties, sharing and then establishing a read-only share. Read Only is best for safety. Pull files rather than pushing them. There is an example above of setting up a share on the zbox system.

The LM17 guest machine cannot be seen from elsewhere on the network, nor can the LM17 guest see any of the other machines on the network. I’m not clear why this was working before, but as I say, I cannot reproduce that result that clearly was working based on the screenshots above. From forum posts on the VirtualBox forums, I expect that bridging will be fixed in the future and may allow wider sharing among the Linux guest and Windows network. I looked at the possibility of using port forwarding of SMB ports in the NAT router, but this looked like too complex.

Enjoy, ww