Can linux router/gateway work with just 1 ethernet and 1 wifi interace?
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Can linux router/gateway work with just 1 ethernet and 1 wifi interace?
Hi All,
I have been recently learning about linux routing and toyed around with it on an old pc.
I am considering buying a mini-ITX to run Ubuntu on.
[Intel D525MW Fanless Dual Core Atom Mini-ITX Board]
The mini-ITX comes with a single Ethernet port. I can add a USB-based WiFi card after Ubuntu is installed.
My question is that, i notice from various forums a Linux based wireless access point router/gateway typically has an external Ethernet interface, internal Ethernet interface and a WiFi interface. Where the internal and WiFi interfaces are bridged.
My question is can I still create a Linux based wireless access point router/gateway with just the external Ethernet and WiFi interfaces?
I presume I can still apply NAT, firewall rules, routing/ip forwarding, have DHCP listen on the WiFi interface etc?
So I'd be bridging the WiFi interface say wlan0 with the external facing Ethernet interface eth0?
Would it still be possible to have the wlan0 and the eth0 on separate networks, say 192.168.1.0 and 192.168.2.0?
In the last PC-based router setup the other day, i noticed the wlan0 and the eth1 interfaces where on the same network as part of the bridge and eth0 was on a different network (external facing). But since I am missing another Ethernet interface, I am having to probably ask ridiculous questions. Apologies for that. I'd like the idea of being able to create firewall rules on both the INPUT and FORWARD chains and playing around with NAT concepts to learn more about networking.
I suppose I could if needs be purchase a USB-based Ethernet adapter to act as eth1 and then bridge it with wlan0.
Yes, you will be sharing the connection via bridging to your ethernet interface. Since you don't have another NIC, you can't assign a separate address.
Given eth0 and wlan0 are on the same network, I presume since packets are either heading for the router/firewall itself or to clients connected via WiFi, that iptables INPUT/OUTPUT chain would come into play for eth0 and the FORWARD chain would then be used for wlan0.
I suppose there is nothing stopping me from geting a USB-based ethernet adapter and bridging it to the wlan0 right?
[If anyone knows of a USB-based WiFi card that supports master mode let me know thanks.]
After realizing the chipset I have...... I have the Alfa AWUS036NH USB adapter. With the correct drivers, which I use compat-wireless, it supports master mode. I bought mine from data-alliance, and they have really good prices.
I'm glad I can install another USB ethernet adapter and bridge a WiFi card capable of Master Mode to it, so I can then have separate networks for eth0 and eth1 bridged with wlan0.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.