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.

RX/TX stats on welcome banner (motd script): Refine RegEx to match real network interfaces only but ignore virtual interfaces by Docker & Co

Featured Replies

Environment:

Armbian on an Odroid-HC2 (Homecloud 2) which uses the odroid-xu4 firmware.

Reproduction:

  1. After initial installation on the welcome banner "RX today:" always shows a nice value.
  2. Install and run some docker containers. This changes /sys/class/net/ . AFAIK it adds so called "virtual network interfaces".
  3. From then on the Armbian welcome screen displays like this:
  • Error: Interface "veth•••••••" not found in database.
  • Note: • redacted by me.


Analysis:

/etc/default/armbian-motd
…
PRIMARY_INTERFACE="$(ls -1 /sys/class/net/ | grep -v lo | egrep "enp|eth" | head -1)"
…



The current regular expression falsely matches veth••••••• (created by Docker).

$ ls -1 /sys/class/net/
br-••••••••••••
docker0
enx••••••••••••
lo
veth•••••••



I fixed it for myself by changing PRIMARY_INTERFACE to this:

"$(ls -1 /sys/class/net/ | grep -v lo | egrep "^en" | head -1)"



Fix Proposal:
A developer with proper knowhow of the network interface naming conventions changes the default regular expression / pipe for PRIMARY_INTERFACE so that it safely only matches a real hardware interface for all typical systems, also working fine when using docker or other software which may create virtual network interfaces or other stub like entries there.

Notes:

  • This bug was already discussed in a forum thread in a "how to help yourself" manner.
  • This here now is a formal bug report with the inquiry to please fix it.

Edited by porg
Added note that this is a bug report

Solved by atone

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...

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.