Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Need help configuring system with two NICs
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 9646
Location: almost Mile High in the USA

PostPosted: Tue May 11, 2021 10:43 pm    Post subject: Reply with quote

pstickar wrote:

- In the router connected to eth0, I'll instruct its dhcp server to assign a fixed IP address to my computer (mac-address ot eth0).
- I'll write that fixed IP address in the field "Default gateway" of that same router.

I did not know that such a thing can work. It looks like an infinite loop to me.

After seeing what your network intent was (your LAN machines should NOT have internet access), now a better idea of what you need to do can be devised.

It indeed is a infinite loop if you set it that way, so actually what you want to do is to leave that field blank. If you can't leave that field blank (e.g. the router/switch insists you put something there), then you have to set your PC to delete that route and NeddySeagoon has a clean way of doing it if you're using netifrc to configure your ethernet device.
_________________
Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
Ralphred
Guru
Guru


Joined: 31 Dec 2013
Posts: 472

PostPosted: Tue May 11, 2021 11:08 pm    Post subject: Reply with quote

eccerr0r wrote:
what you want to do is to leave that field blank.

That fulfils all the criteria, and saves time and energy on the private LAN machines trying to get outside, if they don't have a gateway of last resort they'll just report no route to host, as opposed to waiting for a timeout on a bunk gateway.
eccerr0r wrote:
If you can't leave that field blank (e.g. the router/switch insists you put something there)

You can with that router, it's one of TP-Links better offerings, will most likely work when the warranty expires too :).
pstickar wrote:
If one day I take the PC to another place, without WiFi, and I connect a cable to eth0, accessing the big bad internet, it might be a nightmare.

If that's a possible use case, don't alter the PC config, and just delete the "default gateway" from the routers DHCP settings

The Unix philosophy of "Do one job, do it well" works really nicely if you are trying to design resilient networks, a [modem]-[router]-[switch]-[AP] will be much easier to set-up and far more robust than a [8 port-wifi-modem-router], I even prefer midspans to PoE switches if I don't need it on the majority of ports.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum