How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce? [SOLVED]

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce? [SOLVED]

Post by jameskga »

Hello!

I am tired of moving my external HD around, so I need a way of transferring files across my three systems (Windows 10, Mint 18.3 Xfce [beta], and Mint 18.3 Cinnamon).

My goal is to achieve this using only built-in features of the three operating systems. Tutorials for Cinnamon seem to indicate directory sharing in Nemo is going to be as easy as right-clicking a folder and clicking share this folder, but I don't know what to do on Xfce and all the instructions I can find are severely outdated.

Without touching any settings, I poked around in Xfce and found clues to suggest Xfce can maybe do this, but I don't know how to use Samba (an application I only just learned of by googling how to do this), elements of which seem to be already installed (see screenshots).

If I search 'samba' in the Software Manager, I see samba-related stuff is already installed, such as this:

Image

If I check file permissions on my Public folder (is this a good folder to turn shared?), under the Group dropdown menu, I see sambashare is a group. Can I somehow use this?

Image

It seems like sharing a directory would be something very common and easily done across all Linux Mint. But do I need additional software? I would like to accomplish this without the use of any additional software...

Funny story about the Win10 side of this equation: I went to a directory of Eve Online screenshots to test share it over my LAN. I go to see what changed, and my ENTIRE windows home directory was there for download. Like seriously? By default?? Incredibly reckless behavior, dudes at Microsoft!
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
User avatar
coffee412
Level 8
Level 8
Posts: 2183
Joined: Mon Nov 12, 2012 7:38 pm
Location: I dont know
Contact:

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by coffee412 »

Iam on Mint Mate desktop that uses caja as the file manager. But this should work for you on systems with the nemo file manager.

1. Install nemo-share.

Code: Select all

sudo apt-get install nemo-share
If it asks to install samba choose yes.

Fire up your file manager and right click a directory you want to share and setup the sharing on it.

Report back any problems :)
Ryzen x1800 Asus Prime x370-Pro 32 gigs Ram RX480 graphics
Dell PE T610, Dell PE T710
- List your hardware Profile: inxi -Fxpmrz
MeshCentral * Virtualbox * Debian * InvoiceNinja * NextCloud * Linux since kernel 2.0.36
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by jameskga »

that's why i can't find good info, i don't have nemo. xfce ships with thunar file manager
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by jameskga »

Thank you, that worked to share linux to Windows. I can make these private, but how do I set username and passwords for the folders? Also how do I get thunar to open Windows shares? I can see it on the desktop, but I get an error:

Failed to open "PC-NAME".

Failed to retrieve share list from server: Connection timed out.
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
altair4
Level 20
Level 20
Posts: 11419
Joined: Tue Feb 03, 2009 10:27 am

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by altair4 »

jameskga wrote:Thank you, that worked to share linux to Windows. I can make these private, but how do I set username and passwords for the folders?
Unlike Windows Linux has a user name and two passwords not one. One is used to log into the box locally and the other is used for samba. You create the samba password by adding your local Linux user to the samba password database:

Code: Select all

sudo smbpasswd -a jameskga
It will ask you for sudo's password then the SMB password you want to use for that user. It can be the same as your local login password.
Also how do I get thunar to open Windows shares? I can see it on the desktop, but I get an error:
Failed to open "PC-NAME".
Failed to retrieve share list from server: Connection timed out.
That's a name resolution problem. The netbios mechanism that Windows uses is a cumbersome, outdated, and frustrating thing but it is what it is. Take a look at the checklist first: viewtopic.php?f=42&t=88146&start=0

Windows 10 offers an alternative method that is not available to previous versions if you are interested: viewtopic.php?f=42&t=199907
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by jameskga »

I can see you are an expert in this field! I will try your solutions this evening to see what I can do. Thank you so much for your help, altair.
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
User avatar
Quexos
Level 2
Level 2
Posts: 85
Joined: Wed Jul 29, 2015 9:49 pm

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by Quexos »

I'll take a shot at this...from an Xfce point of view.

First, accessing a shared folder/drive on a Windows 10 machine from a Linux machine has resulted in nothing but grief for me...so F That! I got the same "Failed to retrieve share list from server: Connection timed out." no matter what hoops of flame I jumped through.

But to share a folder/drive on the Linux machine with anything else is a breeze.

ON THE SHARING MACHINE:
=======================
1. I install system-config-samba (just a GUI for easy Samba setup).
2. Try to run system-config-samba and if it fails to start (it probably will, there's a long time glitch with it that it doesn't create it's
own config file or something like that). To fix that throw this into the terminal to create the file, enter, then try again:
sudo touch /etc/libuser.conf
3. Start system-config-samba (just Samba in the start menu > System) and create your shares, allowed users, passwords.

CREATE SHORTCUTS ON THE MACHINE ACCESSING THE SHARE:
====================================================
**I manually assign my LAN IP addresses, so adjust this as needed**
1. Right click desktop > Create Launcher...
Name: whatever-you-like
Command: thunar smb://192.168.1.20/ - (you can be more specific: thunar smb://192.168.1.20/name of shared drive/shared folder/)
2. Right click the launcher and tick the box to allow it to run as a program, double click it and BAYUM! Shared.

FROM WINDOWS, to LINUX SAMBA:
=============================
Create a shortcut with the target: \\192.168.1.20 - (or \\192.168.1.20\name of shared drive\shared folder)
altair4
Level 20
Level 20
Posts: 11419
Joined: Tue Feb 03, 2009 10:27 am

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by altair4 »

@jameskga, This post is not a contradiction to anything Quexos posted. It's just some things you might want to keep in mind.

[1] You have successfully created your samba shares on Mint though thunar. Those share "definitions" are located in /var/lib/samba/usershares and based on your later posts they seem to be working.

[2] If you install and use system-config-samba you will also have share definitions in /etc/samba/smb.conf. It's likely these two share "definitions" will not match which will case some unpredictability. It is my recommendation to use one method or the other - but not both - on the same shared folder.

[3] There is nothing wrong with accessing a host with it's ip address. In fact it's the most efficient mechanism. But should you not have or desire static ip addresses on all your systems remember that Win10 can access a Linux machine with it's mDNS qualified host name \\linux-host-name.local - in explorer and Linux can do the same with windows smb://windows-host-name.local - in thunar with the change I described in the HowTO above.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by jameskga »

Thank you. I followed that SMB checklist and got everything working. Everything, except the ability to view my Windows shares on either Linux computer. But this could be because I didn't actually share anything across the Homegroup. On the other hand, if I click my Windows 10 PC on the network view, I can see all my files....I need to test this from a roommate's Windows PC next to make sure they don't also have access to that.
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
altair4
Level 20
Level 20
Posts: 11419
Joined: Tue Feb 03, 2009 10:27 am

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce?

Post by altair4 »

But this could be because I didn't actually share anything across the Homegroup.
This is the definition of a Windows HomeGroup:
The HomeGroup Protocol is used to create a trust relationship that facilitates the advertising and publishing of content between machines via a peer-to-peer infrastructure. This relationship is achieved with the use of Web Services on Devices (WSD) and a PeerGroup infrastructure. There is no client-server relationship in this protocol; in order to participate in a homegroup, all machines implement the protocol in the same manner.
Side note: The first sentence sounds painfully close to how Avahi works which is what both Linux and macOS use to discover and connect to each other. Sadly it's just not implemented the same way.

Linux does not implement WSD or a Windows PeerGroup. In short there is no such thing as a Windows HomeGroup in Linux, macOS, or even earlier versions of Windows. Linux and macOS can only access a Windows SMB share.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
User avatar
jameskga
Level 4
Level 4
Posts: 220
Joined: Sat Jun 04, 2016 8:23 pm

Re: How do I share a directory to linux and windows PCs on a local network in Mint 18.3 Sylvia Xfce? [SOLVED]

Post by jameskga »

Thank you everyone who contributed to this thread. It really helps, and I can go back to it now.
They say your favorite Mint edition was the one you installed when you still went to school with your friends.
I am out there
Locked

Return to “Xfce”