Network 2 Linux Mint 17.1 machines

Connection sharing, Firewall, Samba..etc
Forum rules
Before you post please read how to get help
oldcharlie
Level 2
Level 2
Posts: 70
Joined: Mon Oct 13, 2014 7:14 am
Location: Florida

Network 2 Linux Mint 17.1 machines

Postby oldcharlie » Sat Dec 20, 2014 5:33 pm

I had Linux Mint 13 networked to a windows 7 PC using samba and everything worked fine. That's history. I installed Linux Mint 17.1 on my desktop (Old Mint 13) and gave my window 7 laptop away. Bought a new Acer Aspire laptop and installed Linux Mint 17.1 on it.

I had assumed that the two Linux Mint 17.1 machines would see each other automatically and that I would not need samba to network and share file between the two. I am using a netgear router and ethernet for all devices. Networking issues tend to make me feel like I'm going around in circles so I am requesting that any responses please keep you answer simple. I don't want to talk about Linux to Windows issues. I don't want to talk about wireless. My main questions right now are:
1: Can I network two linux PC's running Linux Mint 17.1 cinnamon using software included with the package?
2: If the answer to that question is no, then do I still need to use samba?

I intend to read and study the answer before moving on to my next question (In a new post) if that is necessary.
I thank everyone in advance for thier response.
Linux Mint 18.1 Cinnamon 64 bit; 4.4.0-53 Kernel; AMD FX6300; 16GB; NVIDIA GeForce GTX 950; 250GB Crucial SSD; 1TB Segate HDD

altair4
Level 18
Level 18
Posts: 8349
Joined: Tue Feb 03, 2009 10:27 am

Re: Network 2 Linux Mint 17.1 machines

Postby altair4 » Sat Dec 20, 2014 6:01 pm

If by "network" you mean file sharing no you do not need to use samba. There are alternatives.

However I have an all Linux / OSX network ( with a few Windows machines ) and I use samba because it's the default system these days on all operating systems. There's 2 ways to approach the issue of browsing to find other samba machines in the network.

**** You can use the Microsoft method which is the traditional approach: Samba Browsing Problems Checklist

**** Or you can use a native Linux way which is how my systems are set up. On both systems:

[1] Make sure avahi-daemon is running on both machines:

Code: Select all

sudo service avahi-daemon start

[2] Make sure port 5353 is open. If you are not sure just disable the firewall if you are using one:

Code: Select all

sudo ufw disable

[3] Create an avahi samba service file:

Code: Select all

gksu gedit /etc/avahi/services/samba.service

[4] Then copy and paste the following into that file:

Code: Select all

<?xml version="1.0" standalone='no'?>
<!DOCTYPE service-group SYSTEM "avahi-service.dtd">
<service-group>
   <name replace-wildcards="yes">%h SMB</name> ## Display Name
   <service>
       <type>_smb._tcp</type>
       <port>445</port>
   </service>
</service-group>

Please note: The very first line cannot have any leading spaces in front of it or else it won't work. If you use gedit you will know you did it right when after you save the file it changes colors like this:
avahi-samba-service.png

[5] You don't need to do this but just in case restart avahi:

Code: Select all

sudo service avahi-daemon restart


When you use Nemo on either machine and select "Network" you should see the other machine as "hostname SMB"

Samba done the Linux way. No more workgroups. No more netbios names. No more name resolve orders. No more nmbd or any other Windows specific services required.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.

oldcharlie
Level 2
Level 2
Posts: 70
Joined: Mon Oct 13, 2014 7:14 am
Location: Florida

Re: Solved Network 2 Linux Mint 17.1 machines

Postby oldcharlie » Sat Dec 20, 2014 6:50 pm

Altair4,
Well that was pretty straight forward - tried the Native Linux way and indeed my two computers show up as aries SMB and atlas SMB. I hate to admit it but I have been searching this forum and others for two days and must have found over 100 posts but they all tended to get very complicated quickly and did not really address my specific issue. Until I read your post I had never heard of The Native LInux way. Not surprising as I am a rank beginner with Linux. After the big corporation ended support for XP, I took the plunge to Linux and after a few months went 100%. I thank you kindly for your replay and information
Linux Mint 18.1 Cinnamon 64 bit; 4.4.0-53 Kernel; AMD FX6300; 16GB; NVIDIA GeForce GTX 950; 250GB Crucial SSD; 1TB Segate HDD

kencm
Level 1
Level 1
Posts: 9
Joined: Sat Nov 22, 2014 9:23 am

Re: Network 2 Linux Mint 17.1 machines

Postby kencm » Mon Dec 22, 2014 6:37 pm

newbe following and followed instructions. The SMB's show up but I cannot connect - connection refused. Any further help?

altair4
Level 18
Level 18
Posts: 8349
Joined: Tue Feb 03, 2009 10:27 am

Re: Network 2 Linux Mint 17.1 machines

Postby altair4 » Mon Dec 22, 2014 7:05 pm

You should start your own separate thread since it has nothing to do with this one and besides this one is solved.

When you do posting the output of the following commands from the server would help in the diagnosis:

Code: Select all

testparm -s

Code: Select all

net usershare info --long


Telling us what version and what desktop environment you are using on both machines would also be helpful.

If you want a shot from the hip: smbd isn't running on one or the other or both machines so start it:

Code: Select all

sudo service smbd start
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.

User avatar
nuagedeboucane
Level 2
Level 2
Posts: 53
Joined: Thu Mar 13, 2014 1:17 pm

Re: Network 2 Linux Mint 17.1 machines

Postby nuagedeboucane » Tue Jan 13, 2015 12:41 pm

Following this advice did solve my networking problems. Even if I'm not the op, I want to say a big Thank You, altair4!!
To repair something, you must break it before ;-)

grandsurfy
Level 1
Level 1
Posts: 2
Joined: Mon Sep 19, 2011 4:04 pm

Re: Network 2 Linux Mint 17.1 machines

Postby grandsurfy » Mon Jan 26, 2015 3:11 pm

Thank,s I have had this problem on & off for years, This has worked for me :D

shadowvzs
Level 1
Level 1
Posts: 28
Joined: Sat Apr 11, 2015 10:47 am

Re: Network 2 Linux Mint 17.1 machines

Postby shadowvzs » Sun Apr 12, 2015 7:24 am

for me not work, i did the steps and i see my wife laptop in network but can't do nothing with it
i got 17.1 kde, she got 17.1 cinamon

http://i61.tinypic.com/2yo3fpj.png

to 1st 2 icon if i click then nothing happen, if click to 3rd then appear that picture but cant see her hard drive or copy there or anything, just a bulk window

she on her laptop doesn't see my pc

http://i60.tinypic.com/2411edl.png

how can i fix this?

testparm -s
Load smb config files from /etc/samba/smb.conf
rlimit_max: increasing rlimit_max (1024) to minimum Windows limit (16384)
Processing section "[printers]"
Processing section "[print$]"
Processing section "[root directory]"
Processing section "[Prog_dvd]"
Loaded services file OK.
WARNING: You have some share names that are longer than 12 characters.
These may not be accessible to some older clients.
(Eg. Windows9x, WindowsMe, and smbclient prior to Samba 3.0.)
Server role: ROLE_STANDALONE
[global]
server string = %h server (Samba, Linux Mint)
server role = standalone server
map to guest = Bad User
obey pam restrictions = Yes
pam password change = Yes
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
username map = /etc/samba/smbusers
unix password sync = Yes
syslog = 0
log file = /var/log/samba/log.%m
max log size = 1000
dns proxy = No
usershare allow guests = Yes
panic action = /usr/share/samba/panic-action %d
idmap config * : backend = tdb

[printers]
comment = All Printers
path = /var/spool/samba
create mask = 0700
printable = Yes
print ok = Yes
browseable = No

[print$]
comment = Printer Drivers
path = /var/lib/samba/printers
read only = No
guest ok = Yes

[root directory]
path = /
guest ok = Yes

[Prog_dvd]
path = /media/shadowvzs/Prog_dvd
guest ok = Yes

altair4
Level 18
Level 18
Posts: 8349
Joined: Tue Feb 03, 2009 10:27 am

Re: Network 2 Linux Mint 17.1 machines

Postby altair4 » Sun Apr 12, 2015 8:48 am

I would request that you start your own topic please.

This is a Solved topic and deals with two Cinnamon machines. This method will work as described between machines running Cinnamon, Gnome, Unity, XFCE, LXDE, and even Apple's OSX.

KDE is another matter. I have KDE in a VBox guest and it will also work but it's not intuitive and takes forever to display the contents of the remote shares. The whole file sharing / Samba component of KDE and Dolphin in particular is just an over engineered mess in my opinion. From a another machine running Cinnamon for example the KDE share is displayed instantly.

I'm willing to try to debug this thing with you but it may drag on for a while since I try my best to stay our of KDE as much as possible.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.

shadowvzs
Level 1
Level 1
Posts: 28
Joined: Sat Apr 11, 2015 10:47 am

Re: Network 2 Linux Mint 17.1 machines

Postby shadowvzs » Sun Apr 12, 2015 12:51 pm

altair4 wrote:I would request that you start your own topic please.

This is a Solved topic and deals with two Cinnamon machines. This method will work as described between machines running Cinnamon, Gnome, Unity, XFCE, LXDE, and even Apple's OSX.

KDE is another matter. I have KDE in a VBox guest and it will also work but it's not intuitive and takes forever to display the contents of the remote shares. The whole file sharing / Samba component of KDE and Dolphin in particular is just an over engineered mess in my opinion. From a another machine running Cinnamon for example the KDE share is displayed instantly.

I'm willing to try to debug this thing with you but it may drag on for a while since I try my best to stay our of KDE as much as possible.


thank you, i opened another thread viewtopic.php?f=157&t=194004

phoenixcomm
Level 1
Level 1
Posts: 33
Joined: Fri Mar 23, 2012 7:04 pm

Re: Network 2 Linux Mint 17.1 machines

Postby phoenixcomm » Sun Apr 12, 2015 1:14 pm

Samba is only a default on a windows platform.. The vast new users are coming from a "Samba" environment.. So hey if its not broke don't fix it...
BUT NFS has been around for a long time.. and its not going anywhere.
The reason why we have windows networking and dhcp... is the :twisted: MicroSoft moto.. :twisted:
Steal it, if we can steal it then we
BUY it..
and If that can't be done BRAKE IT..
(ala Sun Microsystems vs Microsoft; Java lawsuit... and remember they lost.) so here comes C#

Cris H.

altair4
Level 18
Level 18
Posts: 8349
Joined: Tue Feb 03, 2009 10:27 am

Re: Network 2 Linux Mint 17.1 machines

Postby altair4 » Sun Apr 12, 2015 1:35 pm

I stopped reading your rant after the very first sentence:
Samba is only a default on a windows platform.

[1] The samba server and client services are installed by default in Mint.
[2] Since Mavericks, SMB ( aka Samba ) is the default file sharing protocol in OSX ( in fact they wrote their own implementation ):
When you connect from a Mac using OS X Mavericks or OS X Yosemite to another computer using file sharing, your Mac automatically tries to use the Service Message Block (SMB) protocol to communicate. If SMB is not available, OS X tries to connect using Apple File Protocol (AFP).

Had you read my post you would have realized that what I proposed was replacing the Windows way of doing Samba ( smbd + nmbd ) with the native Linux way of doing Samba ( smbd + mDNS ). Once the switch is made I can even disable all the Windows specific components of Samba and not only does it still work it works much better.

You're welcome and have a nice day.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.


Return to “Other networking topics”

Who is online

Users browsing this forum: Google [Bot] and 2 guests