Share a Windows Folder on Another Linux Computer

Although Windows is the predominant operating system on desktops, Linux distributions are an interesting alternative. In this way, users have the possibility to choose the operating system that we are most interested in using on the PC depending on many factors. Now we will see how to share a Windows folder, on a Linux PC.

It is true that Linux and Windows systems have great differences, both in terms of functionality and appearance. This is something that becomes especially clear as we delve into the different operating systems that we are talking about. It is precisely for this reason that many users around the world complement the use of both platforms in order to get the most out of both. In this way they can share partitions on the same computer, while we can find Linux on Windows on a local network.

Share a Windows Folder on Another Linux Computer

As we tell you, there are many differences between both platforms, something that for example we can see in the different file systems and protocols in use. But with everything and with it we can see ourselves in the situation in which we want to share files between them, something that can be somewhat difficult. The main reason for this is that they use two different sharing protocols, but let’s see how we can fix it.

And that does not mean that it is impossible to mount a Windows shared folder in Linux, something in which we will help in the next few lines. Specifically, below we are going to see how to do it in the simplest way, even for users with little experience in these topics.

Share a Windows folder for Linux

Well, once we know all this, the first thing we are going to do is prepare the folder that we want to share in Windows and then mount it in Linux . Before doing anything, the first thing to do is make sure that Windows has been configured correctly. This will help the Redmond operating system to allow network file sharing.

To enable this that we discussed in Windows 10, the first thing we have to do is click with the right button of the mouse on the network icon.

Configure Windows to share folders

This is found in the notification area of the Windows taskbar. From here we can access the option called Open network and Internet settings.

Abrir configuración de red

Next, once the new window opens, in the left panel we find the section called Status. We go there and in the right pane we click on Network and Sharing Center.

configuración recursos compartidos

On the right in the new window that appears, click on the link that says Change advanced sharing settings. This is when we must make sure that the Enable network discovery and Enable file and printer sharing options are enabled.

Activar detección de redes

Then we just have to click on the selectors next to both options to make sure that it is and to be able to share folders . We no longer have to click Save Changes to finalize the configuration.

Prepare the folder to share in Windows

Once all this is done that we tell you, we have to open a Windows File Explorer window. This, for example, we achieve through the Win + E key combination, to locate the folder that we want to share with your Linux-based PC. Once we see it, we click with the right button on it and select the Properties option.

Thus, in the Properties section of the folder, we go to the Share tab and then opt for Advanced Sharing. Here we can activate the Share this folder box and then click on Permissions.

Uso compartido avanzado

Say that in the Permissions section we must set the control permissions for the folder. By default Windows grants read-only access to your files, but if we want to allow everyone to read or write to the folder, we click Allow for the permission set under Full Control. Once we are done we accept everything, so this folder should now be shared on the network ready so that we can access it from a Linux PC.

permisos compartir carpeta Windows

Prepare shared folder on Linux

Now we have to boot our computer with the open source operating system, Linux. Depending on the Linux distribution we use, we may be able to mount the shared folder with Windows automatically from the file explorer of that distro. However, this may not work correctly in all cases, although before we can try to see if we have access to it directly, without further changes.

If not, the safest way to mount Windows shared folders on Linux is to use the CIFS-utils package. This will allow us to mount the folder that interests us in this case, using the Linux terminal. It is worth mentioning that this set of utilities allows Linux machines to access shared SMB files used by Windows-based PCs.

Install CIFS-utils on the Linux machine

At this point we will tell you that to install the CIFS-utils package, we open a new terminal window, for example with the key combination Ctrl + Alt + T. Once in it, if we work with distributions based on Ubuntu or Debian , we write the following:

sudo apt install cifs-utils

cif linux compartir carpeta

For example, in the case that we have the Arch Linux distro, we use the command:

pacman -S cifs-utils

Once installed in a set of applications, we will have the possibility of mounting our shared Windows folder from the Linux terminal itself.

Mount Windows SMB Share on Linux

From that moment on what we have to do is create a directory before we can mount the shared Windows SMB folder in Linux. This is where Linux will mirror the contents of the shared folder. To do this, we open a terminal window again and type the following:

sudo mkdir /mnt/share

Once this has been created, we enter the following command:

sudo mount.cifs //WINDOWS/CARPETA_COMPARTIDA /mnt/share -o user=CUENTA

Here we have to replace the Windows field with the IP address of the Windows PC, and SHARED_FOLDER with the name of the Windows folder as well. For the username, we replace ACCOUNT with our Windows username or Microsoft account email. At this point we may be asked to type the Windows password before the mounting process is complete. We write it and click Enter.

Therefore, if we have used the correct information, the Windows folder should be mounted and accessible from the Linux folder that we have created.