I thought this was going to be plug and play but looks like some manual config is going to be necessary.
My RPI has one ethernet port. It is used to connect the RPI/OpenWrt router to a wired internet. It also has 2 wifi connections. One to connect to a wireless network and the second as an AP for clients to connect to the RPI/OpenWrt router.
I want to add eth1 so I can add a network switch for wired clients like the wireless AP.
When I plug in the usb ethernet adapter and run lsusb, the Pi sees it. When I go to Network > Interfaces to add a new device, there is no eth1 to choose. If I insert eth1 into the custom box, nothing happens.
I am not sure I understand the topology you're building, so I can't answer without more information.
Can you draw a simple diagram of how the Pi fits into your network and what is plugged into the two ports (eth0 and eth1) such that we can understand how eth1 will be used?
Re: wireless -- don't use the on board wifi, and USB adapters are also pretty bad as APs. You will be far better off with a proper AP, even an older 'plastic' all-in-one wifi router can easily outperform these other options.
So your goal is to make eth0 (the built-in ethernet) an upstream connection, and then have eth1 (USB adapter) as the lan side? I'd actually recommend the reverse configuration, but either is valid. The benefit of using eth0 as the lan side is that it is always connected, no additional driver package needed, etc. This means that you will always be able to connect to the lan side, even if something goes wrong with the USB adapter's drivers or connection.
Another benefit is that the OpenWrt default configuration uses eth0 within br-lan which is then used as the device for the lan network interface. This means that you don't need to make changes to those defaults... just add a new interface like this (if you do it with a lowercase 'wan' as shown below, the firewall is already pre-configured for this, so it'll just work):
config interface 'wan'
option device 'eth1'
option proto 'dhcp'
Returning to your original question:
If you keep your original plan (eth1/USB ethernet adapter = lan side), no, you want it to be a static IP. Otherwise, it won't have an address and your connectivity will break.
If you change your plan such that the external ethernet is for the wan, then you'll configure it as a DHCP client (per my example above).
BTW, this is not a good option for a travel router. You'd be much better off with a real travel router such as the GL-inet MT3000 or the Cudy TR3000. Those will have much better performance than your Pi for wifi, everything is built-in (so less mechanical stuff to deal with, more physically robust, too), and they're running a really good chipset with great support with official OpenWrt.
I bought one of those about 3 years ago when I gave up trying to get OpenWrt working. It works well and got me out of a pinch when my home router crapped out. I still have it but its no longer supported and can't be updated. Also, clients can only connect via the wireless and the upstream by wired only.
A lot of that was over my head. I'm not exactly understanding. I may not be using eth0 (the built-in ethernet) as the upstream depending on the situation, it could be wireless is my only option. It could wireless is my only option. I don't understand why eth1 would not always be active.
I would also need anything connecting to eth1 be given an IP address just like the wireless AP. Would it be better to attach it to the wan?
I don't really understand how some of my interfaces got their names.
This doesn't sound like one of the devices I was mentioning -- those are very much supported and can run the latest OpenWrt.
If you can tell me what is confusing, I can try to explain a different way.
This is one big reason why you would be better off with the USB-ethernet adapter used to connect to the upstream... when you don't need it, you can leave that adapter unplugged entirely. You'll almost always want to have the wired lan connectivity available -- it's best if that is the built-in port.
Like I said, it's best to make that eth0 (internal port) instead. By default, OpenWrt is already setup to do that with eth0.
I'm not sure what you mean here, but if you're talking about which physical port to use as a wan, I would suggest the USB-ethernet adapter for the wan.
You added the wan, eth1, and wg0. When you did that, you provided names. The lan was there by default.
Bought one of what? GL.iNet GL-AR750S-Ext (Slate) Gigabit Travel AC VPN Router (2022) It is no longer support. Had it out the other week and tried to do an update.
I messed around last night until I broke it. I tried setting a static IP as you suggest. It broke the internet connectivity. It doesn't really matter if the client wired connection is eth0 or eth1. My Dell server has 2 NICs. I believe one is for remote access or can be setup that way.
There is a eth0 and eth1. I guess eth1 is still showing up because its plugged in. I did delete the interface when I copied my config files from a backup. I backed up the image before adding it. I can reflash the card if you think I should.
I'll give it a go again using eth0. What do I need to do?
Set up a wan network with Device eth1 and protocol dhcp client. When you plug in the adapter and connect it to a typical Ethernet network (which has a dhcp server) it should come up.
Note that you may need to change your lan IP if the wan network happens to be using the same IP subnet. lan→wan routing depends on having different IP ranges.
I went ahead an tried to set it up. I used a static IP since eth1 will be used to connect to the ISP. It hasn't broken anything, still have internet connectivity. I don't really have a way to test it. I've run out of ethernet ports. My switch is going bad, some ports work, some ports occasionally. Might be a few days before I can get a replacement.
Also the AR750S is still supported by official OpenWrt. It’s an ath79/nand platform. Compared to a Raspberry Pi 4 it has a lot slower CPU, but the networking and wifi is much better.
Very few residential ISPs (not to mention hotels, cafes, etc.) would have you use static IP as the connection protocol. The vast majority of upstream networks you will encounter will be either DHCP or PPPoE.
To test that it's working, you only need 1 or 2 total ports.
eth1 connects to the upstream network
eth0 and/or wifi is used to connect your downstream devices (i.e. your computer/phone/etc.).
If you can route through to the internet, it's working and likely configured appropriately for the specific environment you're using to test.
As @mk24 already pointed out, this device its sill supported by official OpenWrt. And although the CPU is indeed slower, you'll find that this is a much better option for your travel router. It has 3 built in ethernet ports and wifi that can run circles around the Pi's wifi. It's also designed for the purpose of being used as a travel router, so it's far more robust than a Pi with a bunch of stuff hanging off of it (i.e. a USB-ethernet adapter and/or a USB wifi adapter).
You will be much happier with the AR750S in the long run -- it's just so much more straight forward.