Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Interface only get ip config if plugged on boot

Featured Replies

Hi,

Nanopi R1 -  Kernel and Armbian version: 4.19.62-sunxi #5.92

 

I have the following problem:

If I put the ethernet cable on the interface, and then turn on the nano pi, the interface receives a valid ip.

But the problem is, if I start nanopi without the cable connected, and I connect after system boot, the interface does not receive ip configuration.

Configs and logs:

/etc/network/interfaces:

source /etc/network/interfaces.d/*

auto eth0
iface eth0 inet dhcp

auto eth1
iface eth1 inet static
        address 10.100.3.1
        netmask 255.255.255.0
        gateway 10.100.3.1

auto lo
iface lo inet loopback

up command iptables-restore < /scripts/iptables

 

/scripts/iptables

*nat
:PREROUTING ACCEPT [120:10027]
:INPUT ACCEPT [11:1747]
:OUTPUT ACCEPT [24:1848]
:POSTROUTING ACCEPT [4:304]
-A POSTROUTING -o eth0 -j MASQUERADE
COMMIT

 

journalctl  -b 0 -u NetworkManager | grep eth0

Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1115] keyfile: add connection /run/NetworkManager/system-connections/eth0.nmconnection (91ae80f1-5092-4e36-8f48-72f86df06873,"eth0")
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1178] device (eth0): state change: unavailable -> disconnected (reason 'connection-assumed', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1247] device (eth0): Activation: starting connection 'eth0' (91ae80f1-5092-4e36-8f48-72f86df06873)
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1258] device (eth0): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1287] device (eth0): state change: prepare -> config (reason 'none', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1309] device (eth0): state change: config -> ip-config (reason 'none', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1328] device (eth0): state change: ip-config -> ip-check (reason 'none', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1372] device (eth0): state change: ip-check -> secondaries (reason 'none', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1388] device (eth0): state change: secondaries -> activated (reason 'none', sys-iface-state: 'external')
Mar 25 01:38:29 2-0211 NetworkManager[556]: <info>  [1648183109.1538] device (eth0): Activation: successful, device activated.
Mar 25 01:38:37 2-0211 NetworkManager[556]: <info>  [1648183117.8873] device (eth0): carrier: link connected
Mar 25 01:39:56 2-0211 NetworkManager[556]: <info>  [1648183196.5941] device (eth0): state change: activated -> unavailable (reason 'carrier-changed', sys-iface-state: 'external')
Mar 25 01:39:56 2-0211 NetworkManager[556]: <info>  [1648183196.7318] device (eth0): carrier: link connected
Mar 25 01:39:56 2-0211 NetworkManager[556]: <info>  [1648183196.7333] device (eth0): state change: unavailable -> disconnected (reason 'carrier-changed', sys-iface-state: 'external')

 

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.