0
Marcus Nguyen

How to disable eth0 without cable

Recommended Posts

Hi everyone,

 

I am using nmtui to setup static ip both eth0 and wlan0 on orange pi zero. It works fine if only one of them was activated

I want to use both. If LAN cable was be connected into pi, the board is run on ethernet. On other side, run on wifi when the cable was pluged out

When I rebooted the pi without LAN cable, the eth0 auto activated lead to I can't access the module via wifi even though it is connected successful. I must connect via serial and disable eth0 after that I connected via wifi. 

Share this post


Link to post
Share on other sites

Are you setting the same static IP to both interfaces or are they in different networks? Do you have configured a bridge or some kind of bonding?

Can you tell a little bit more on the network configuration?

I see my eth0 going down, when unplugging the cable. When booting without cable, it stays down and only WiFi is up and reachable.

 

Share this post


Link to post
Share on other sites
4 hours ago, Marcus Nguyen said:

It works fine if only one of them was activated

It sound like usual trouble :

Both devices are on the same subnet and therefore have the same gateway.

Then you are doing SSH on the WiFi and then unplug the ETH0, your SSH is frozen because returned packets will come back to the wrong ETH0 gateway, you just replug the ETH0 and you see that the current SSH session is alive again...

Solution : don't use the same subnet on both network type !

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
0