0

So let me preface this question by stating that I am not so well versed in the linux ways hence simple explanations are appreciated. On to the question at hand.


Question

I am currently running an Arch Linux server (selected the server option in the archinstall script) its mostly to run docker containers, its connected to the internet using WiFi. I recently decided to connect some of the devices to the server via a network switch (it's an unmanaged/plug-and-play switch). Since the network switch is unmanaged I know that I need to manually assign ip address to the devices connected to it. The problem is that I can, at any given point, only get one of the 2 networks working fine on the system.

If I configure the Ethernet then the WiFi network no longer has access to the internet (still connected to the WiFi network, just no internet access). If I disable the Ethernet then then I have internet access but no access to the devices connected in the wired LAN. How do I solve this so that both networks are connected and still have access to the internet?


What I tried:

I followed the guide found here. I tried both the netctl method and the systemd method. I would like to say that I had more luck with the netctl method for a static IP for the Ethernet network, but that's just because it's easier to do.

Since netctl can also be used to connect to a WiFi network I tried to use that to connect to the WiFi instead of iwctl, I figured maybe its not working cause its 2 different scripts/programs managing them. But that didn't work as netctl just didn't connect to the WiFi network. I used the examples provided by them, "wireless-wpa", and tweaked the contents to match what I had. At first it didn't work cause the passkey was getting rejected, so I got the encrypted passkey using "wpa_passphrase" and used that, but that didn't work either. It just said 'wpa authentication failed' (might not be exactly that, I did revert everything before typing the question, so the details are a bit off in error messages)

I did think maybe I was changing too much of what the netctl ethernet example had so here's an example of what it looked like after my changes

Description='A basic static ethernet connection'
Interface=enp0s26
Connection=ethernet
IP=static
Address=('192.168.1.102/24')
Gateway=('192.168.1.1')
DNS=('8.8.8.8' '8.8.4.4')

+ whatever was there after DNS (I didn't touch those)

Yes, all I did was change the interface name but I figured I should show what the config I used was.


How Did I Check the Connections:

I used ping.

Check for internet access was ping www.google.com.

Check for ethernet connection was ping 192.168.1.22 (IP I set for my windows machine)


Misc.

the netctl example for static IP ethernet has a different IP for DNS. I did try that as well. But no dice there, I'm pretty sure it looked like this:

Description='A basic static ethernet connection'
Interface=enp0s26
Connection=ethernet
IP=static
Address=('192.168.1.102/24')
Gateway='192.168.1.1'
DNS=('192.168.1.1')

+ whatever was there after DNS (I didn't touch those)

As I started typing in the Title for the question I did run across this Stack Exchange question, but I have no idea whats going on there.

1
  • So netctl doesn't come with all the tools it needs to use WiFi and dhcp for some reason... I had to install dhcpcd, wpa_supplicant and, dialog, to get it work fine. dhcpcd cause my wifi porfile would use it to get an IP (I think). wpa_supplicant to allow netctl to connect to wpa encrypted networks (again I think). dialog to get the wifi-menu -o command to work, useful to generate the profile for WiFi. Just note that connection will fail when using wifi-menu if you didn't have dhcpcd installed.
    – Exodos
    Commented May 19, 2022 at 8:02

1 Answer 1

0

So I have, since posting the question, figured out the reason I wasn't able to use netctl to set up both connections, it was a routing problem. I used the instructions here to change the routing scheme the system used and it works.

Well not 100% working, but that's just an issue with netctl not being able to autostart with system cause the interfaces are already up but that's a different question.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .