View previous topic :: View next topic |
Author |
Message |
grant123 Veteran
Joined: 23 Mar 2005 Posts: 1080
|
Posted: Mon Sep 17, 2012 8:04 pm Post subject: 2 networks on my laptop? |
|
|
I have my laptop set up as a router so I can share my internet connection with my wife's laptop with a pair of USB ethernet dongles. There is a desktop I'd like to be able to ssh into via ethernet from my laptop but I don't need to share my internet connection with it. I have a third ethernet dongle for this and the desktop has built-in ethernet. How should I configure the connection to the desktop? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54236 Location: 56N 3W
|
Posted: Mon Sep 17, 2012 8:16 pm Post subject: |
|
|
grant123,
The easy answer is not to use the 3rd USB dongle - use a switch and plug the 3 devices on your local area newtwork into the switch.
Do not allow the desktop a default route if you don't want it on the internet.
Other answers depend on your laprop router setup and the operating systems on your wifes PC and the desktop CP.
You can have three point to point links from the router but the idea makes my head hurt.
Does the router run a dhcp server or is your network entirely static. Even worse, so you use zeroconf (link local addresses) _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
grant123 Veteran
Joined: 23 Mar 2005 Posts: 1080
|
Posted: Tue Sep 18, 2012 5:41 am Post subject: |
|
|
I actually got it working by starting /etc/init.d/net.eth1 on my laptop, /etc/init.d/net.eth0 on the desktop, and adding a line for eth1 to /etc/shorewall/interfaces. I can share my internet connection with the desktop by adding a line to /etc/shorewall/masq.
This was really too easy so I'm wondering what I might have overlooked? |
|
Back to top |
|
|
eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9679 Location: almost Mile High in the USA
|
Posted: Tue Sep 18, 2012 7:14 am Post subject: |
|
|
I was about to say... I always had troubles like this when I was at school, had all these things and theoretically we could make a network out of them... with the added contraint without buying anything else.
Like for instance I had a 10base2 computer and a 10baseT network. Well I had another 10base2 card for the other machine I had and theoretically I could bridge the machines together...
I'd say this is almost the same kind of problem. While since you just need to access that one machine once in a while, and that one machine does not need to access out, this simplifies things a lot. The only thing I'd have to say is watch out for your udev autoconfig for eth0 and eth1 - though it should keep them the same each time you plug in a specific ethernet adaptor. If you lose the udev autoconfig you may lose connectivity between the machines when they confuse one for the other...
Otherwise I don't think there are many other issues. But it only gets fun when you want all three machines have internet access and have all three machines able to connect to each other seamlessly...
And yes, after being out of school for over a decade, I end up buying the switch now. _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54236 Location: 56N 3W
|
Posted: Tue Sep 18, 2012 5:45 pm Post subject: |
|
|
grant123,
Ah well, buy the switch next time you add to your network. Its lower cost than another USB dongle.
Maybe I've been out of school too long too. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
|