How to properly network two Linux Mint computers so I can sync [SOLVED]
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Well, the "laptop.local" thing is supposed to work fully transparently/automatically and, if it works, is a fair idea. Frankly it might be an issue with our network equipment (routers, switches) that those of us that are having issues with it are having, so frankly, I'd try and see if it works for you.
Yes, the two-line thing won't do.
Yes, the two-line thing won't do.
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Actually, by the way, yes, you can in fact also do "static IP" in the true, old-fashioned sense although I wouldn't do it as described by deepak's link, but through NetworkManager. But it's a laptop... and disabling DHCP means you'd then not be setup correctly for any network other than your home network. So, well, maybe, maybe not, ...
-
- Level 20
- Posts: 12337
- Joined: Sun Aug 09, 2015 10:00 am
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I have done that to my laptop, I don't go to another network. My router ip is 192.168.1.1. I have set static IP as 192.168.1.100, very less chance that dhcp will use this address as there have to be 100 devices on the network. Mine has only 6 maximum.rene wrote: ⤴Mon May 11, 2020 6:26 am Actually, by the way, yes, you can in fact also do "static IP" in the true, old-fashioned sense although I wouldn't do it as described by deepak's link, but through NetworkManager. But it's a laptop... and disabling DHCP means you'd then not be setup correctly for any network other than your home network. So, well, maybe, maybe not, ...
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I didn't think of that.
I've now set the wifi and ethernet to both have an ip of 192.168.1.5 and it works. I won't have them both connected at once so won't have to worry about conflicts.
Thanks. Now I won't need to change the fstab file
I've now set the wifi and ethernet to both have an ip of 192.168.1.5 and it works. I won't have them both connected at once so won't have to worry about conflicts.
Thanks. Now I won't need to change the fstab file
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I in that case tend to advise desktops rather than laptops, but heydeepakdeshp wrote: ⤴Mon May 11, 2020 6:31 am I have done that to my laptop, I don't go to another network.
While your router may in practice hand out sequential IPs and start low, note that there's nothing in the protocol to guarantee any such on a theoretical level. As such I'm sure it works in practice now as well, but what I do on networks where I have a static segment is configure its DHCP server to hand out e.g. 98 addresses max starting from 192.168.x.2, and use 192.168.x.100 and above for static. Or more commonly conversely in fact, with DHCP handing out 155 addresses starting at 100, but, whatever.
[EDIT] Off by one...
Last edited by rene on Mon May 11, 2020 7:00 am, edited 1 time in total.
-
- Level 20
- Posts: 12337
- Joined: Sun Aug 09, 2015 10:00 am
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I have a raspberry pi. I have set different ips for eth0 and wifi. Shouldn't be a conflict ,and it's easy to avoid it.
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
qiana lover: feel free to continue; intermezzo's done...
-
- Level 1
- Posts: 23
- Joined: Wed Jul 03, 2019 7:42 pm
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Hi again! Sorry for the 2 week hiatus have been busy juggling many things but really need to get this connection to work as there is crucial information I need to be able to access regularly from one computer to the other. I really appreciate all the help so far.
Where we left off -
1) yes I have fixed the etc/exports file of Computer A to remove the spaces.
2) I have successfully exported using the command on Computer A (the server computer)
3) In trying to mount on the client, I have done the following
- I have made a directory on a secondary disk on computer B. /mnt/userA
- I have typed the following command
sudo mount 192.168.0.28:/home/userA /mnt/userA
(I think 0.28 was the number in my case?)
It then returns the message:
mount.nfs: requested NFS version or transport protocol is not supported
I'm sure I did something wrong here again. What could it be?
Where we left off -
1) yes I have fixed the etc/exports file of Computer A to remove the spaces.
2) I have successfully exported using the command on Computer A (the server computer)
3) In trying to mount on the client, I have done the following
- I have made a directory on a secondary disk on computer B. /mnt/userA
- I have typed the following command
sudo mount 192.168.0.28:/home/userA /mnt/userA
(I think 0.28 was the number in my case?)
It then returns the message:
mount.nfs: requested NFS version or transport protocol is not supported
I'm sure I did something wrong here again. What could it be?
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I don't really know. It still takes me ages to trouble shoot my connection when an ip address changes.
Check the ip addresses are correct. I'm finding I have to set it to specific ip addresses on both computers.
That error brings the following to mind though - but remember I'm clueless. You sure you have nfs server and client installed on both machines. If the protocol is not supported it's like you lack the software to support the action.
So I can go in any direction from one machine to the other I install the server and client on both.
Check the ip addresses are correct. I'm finding I have to set it to specific ip addresses on both computers.
That error brings the following to mind though - but remember I'm clueless. You sure you have nfs server and client installed on both machines. If the protocol is not supported it's like you lack the software to support the action.
So I can go in any direction from one machine to the other I install the server and client on both.
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Turn ufw firewall to off.
-
- Level 1
- Posts: 23
- Joined: Wed Jul 03, 2019 7:42 pm
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
nn70 I don't think you are clueless at all - in fact quite an expert! Thank you so much for your help.
I can report that:
- I ended up installing nfs client and nfs server on BOTH machines
- ufw firewall was actually OFF for both machines
- I ended up just rebooting both machines, exporting from ComputerA and then typing the mount command from ComputerB and this time... it worked! Oh my goodness I can finally start doing the things I wanted. Thank you so much nn70 and rene for helping on this.
Now that it is set up - I would like to request help for some quality of life improvements if I may, but this is not urgent.
It seems like every time the computers are restarted, I need to type the export command from computer A and the mount command from computer B. Is there any way to add these commands to the start up sequence of each computer? So that the connection is always there?
Many thanks.
I can report that:
- I ended up installing nfs client and nfs server on BOTH machines
- ufw firewall was actually OFF for both machines
- I ended up just rebooting both machines, exporting from ComputerA and then typing the mount command from ComputerB and this time... it worked! Oh my goodness I can finally start doing the things I wanted. Thank you so much nn70 and rene for helping on this.
Now that it is set up - I would like to request help for some quality of life improvements if I may, but this is not urgent.
It seems like every time the computers are restarted, I need to type the export command from computer A and the mount command from computer B. Is there any way to add these commands to the start up sequence of each computer? So that the connection is always there?
Many thanks.
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I am clueless. I've only been full time on Linux for about 6 weeks. Rene is the one to thank.
I'm glad you got it working. It's a good connection. Better than windows networking I think.
To get it to reconnect after a reboot you need to do the fstab step. It's in Rene's first description when he told me what to do.
Do your ip addresses change as I don't think you can do an ip range for the fstab thing. Here's the example he gave me in post 2 of this thread. You'll need to change the ip address for your example, plus the folders.
If all's well, you can on the client make the export conceptually available always as long as the server is reachable by adding the mount to /etc/fstab. E.g, something like
192.168.1.123:/home/nn70 /mnt/nn70 nfs noauto,x-systemd.automount,x-systemd.mount-timeout=10s,x-systemd.idle-timeout=10m
I don't know if there are any formatting gotchas with this fstab entry (spaces that shouldn't be there for example).
I'm glad you got it working. It's a good connection. Better than windows networking I think.
To get it to reconnect after a reboot you need to do the fstab step. It's in Rene's first description when he told me what to do.
Do your ip addresses change as I don't think you can do an ip range for the fstab thing. Here's the example he gave me in post 2 of this thread. You'll need to change the ip address for your example, plus the folders.
If all's well, you can on the client make the export conceptually available always as long as the server is reachable by adding the mount to /etc/fstab. E.g, something like
192.168.1.123:/home/nn70 /mnt/nn70 nfs noauto,x-systemd.automount,x-systemd.mount-timeout=10s,x-systemd.idle-timeout=10m
I don't know if there are any formatting gotchas with this fstab entry (spaces that shouldn't be there for example).
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Wait a minute though. You should not need to do exportfs -rav every time. That should stick.
If you don't have the fstab setup the mount command should be enough - as in, you will need to do that after a reboot, but you won't need to exportfs -rav
If you don't have the fstab setup the mount command should be enough - as in, you will need to do that after a reboot, but you won't need to exportfs -rav
-
- Level 20
- Posts: 12337
- Joined: Sun Aug 09, 2015 10:00 am
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
If the ip addresses keep on changing:-
sudo apt-get install nmap
Once the application is installed, enter the following command:
nmap -sn 192.168.1.0/24
It will give the ips of the devices on your lan.
sudo apt-get install nmap
Once the application is installed, enter the following command:
nmap -sn 192.168.1.0/24
It will give the ips of the devices on your lan.
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Thanks. I've installed it, run it, and looked at the man page. The manual is endless
I see it does indeed query the network and tells me every ip address currently assigned, as you said.
Is there a way to get it to show the device names? I only have 3 devices connected to the network just now but still I would have to go to the laptop to check which of these ips belongs to it - unless I'm missing something.
I see it does indeed query the network and tells me every ip address currently assigned, as you said.
Is there a way to get it to show the device names? I only have 3 devices connected to the network just now but still I would have to go to the laptop to check which of these ips belongs to it - unless I'm missing something.
-
- Level 20
- Posts: 12337
- Joined: Sun Aug 09, 2015 10:00 am
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
You should set up a static ip to the server at least.nn70 wrote: ⤴Sat May 23, 2020 1:14 pm Thanks. I've installed it, run it, and looked at the man page. The manual is endless
I see it does indeed query the network and tells me every ip address currently assigned, as you said.
Is there a way to get it to show the device names? I only have 3 devices connected to the network just now but still I would have to go to the laptop to check which of these ips belongs to it - unless I'm missing something.
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Regards,
Deepak
Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
The server is setup on a static ip as it always connects via ethernet so I have the router assigned to give that mac the same ip every time.
The laptop sometimes connects via ethernet and sometimes via wifi, and they have different ip addresses (which surprised me a bit).
I tried a couple of things to give the laptop the same ip whether it connects via ethernet or wifi but neither worked well.
The laptop sometimes connects via ethernet and sometimes via wifi, and they have different ip addresses (which surprised me a bit).
I tried a couple of things to give the laptop the same ip whether it connects via ethernet or wifi but neither worked well.
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
No, not this time
qiana lover:. As nn70 indicated, to have the to mount (conceptually) available always, all you need is to add it to the client's /etc/fstab. I.e., if you now from said client mount as
sudo mount 192.168.0.28:/home/userA /mnt/userA
you add to client's /etc/fstab the line Code: Select all
192.168.0.28:/home/userA /mnt/userA nfs noauto,x-systemd.automount,x-systemd.mount-timeout=10s,x-systemd.idle-timeout=10m
exportfs -rav
on the server: that's just for when you change the server's /etc/export.At the same time there's a subthread running on the IP-addresses thing but I feel you're better of if we wait to deal with THAT until you have things setup with the explicit IP address above; it's about a conceptually different issue (addressing systems, rather than sharing files between them as such).
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
I as indicated still quite advise to first of all try zeroconf addressing, i.e., mDNS. To from the system with hostname "laptop" address the system with hostname "server" as "server.local", conversely from the system with hostname "server" address the system with hostname "laptop" as "laptop.local". Testing if that works at all is a simple matter of trying
Code: Select all
nn70@laptop:~$ ping -c3 server.local
Code: Select all
nn70@server:~$ ping -c3 laptop.local
Generally, the second option is configuring the DHCP-server on your network to always hand out the same IP-addresses to the same systems and then just continue to address by IP directly or add IP/name pairs to /etc/hosts and address by said name -- but that's in your case frustrated by a single system having multiple MACs depending on Wi-Fi vs Ethernet (normal, even if not always the case) and your router not wanting to assign the same IP to different MACs (as normal as know-it-better software is; quite, that is).
The third option as suggested by Deepak is configuring both the wired and wireless connection with the same static IP. As suggested by me, not via the method he suggested but via Network Manager, the usual network settings as reachable via Settings and/or the network-icon thingy in your systray. Although come to think of it you may in that case want/need to to set neither connection to "connect automatically" on startup lest it would find there to be a conflict when it tried to bring up both, even if one of them was eventually not available.
As in, please just do the first .local thing and only get back to us if it regularly craps out for you as well
Re: How to properly network two Linux Mint computers so I can sync [SOLVED]
Ok, that is my next project then. I'll need to get the laptop out and try it. I didn't try it before as I think you said there can be issues with it. Sounds like that's not always the case so, so I'll give it a crack.
I will post back once I've tried.
And thanks.
I pretty much understand the commands, but what does -c3 do? I just searched it up but it seems too short and specific for my search engine.
I will post back once I've tried.
And thanks.
I pretty much understand the commands, but what does -c3 do? I just searched it up but it seems too short and specific for my search engine.