-
Ethernet driver bug (?) using several MAC addresses (vlan use case) on the integrated NIC
Hello, After several days of debug I put the finger on a very strange issue using integrated Ethernet. I use my Rockpro64 mostly as a Samba and DNS server. In my network context I implement 2 vlans as vlan interfaces (eth0.10 and eth0.20). Each of these interfaces needs to use a specific mac address that differs from physical eth0 mac address (it is an important point). If I use only the physical mac my router is not be able to route correctly between vlans (probably an ivl/svl issue). Under this context I first noticed that when I bring down eth0.20 although using vlan 10 (so eth0.10) connectivity is lost. I then write a script to gather all needed information (ie. ip link/addr/route/rule/neigh, ping, arping, netstat, ...) ==> no peculiar problem I then add a background tcpdump and, guess what, the connectivity loss didn't occur anymore ! After thinking a bit, I made the assumption that the main difference is the use of promiscuous mode during tcpdump. ==> and "bingo" : setting 'promisc' flag on eth0 acts as a workaround. Also if I do not set a specific mac for vlan and use physical mac leads to no connectivity issue, despite the wrong routing. The key point seems that bringing down a vlan interface unregisters all macaddress from listening process instead only the needed, so the connectivity problem. I don't know if it's a hardware limitation, a driver bug or Armbian issue, but I am open to any fix or at least, any debug hint that helps to narrow down the root cause. Regards.
-
armbian-ramlog problems and possible improvements
Hello, I wonder if there other improvements. Indeed I did some changes to have thing working better. (Using Armbian 23.8.1 on Rockpro64) For example : - In journald.conf : had to set Storage as "volatile" instead of "auto". If not there is truncation of journald content at every midnight log rotation. I saw that some armbian-ramlog script steps depends on "volatile" Storage value. EDIT 23/01/2024 : in fact with "volatile" journal logs are never flushed to persistent storage. So I returned back to "auto" but needed to amend postrotate (see below). - In armbian-ramlog postrotate, I have done these changes : postrotate) cd /var/log.hdd/ #find . -type f -print | grep -E -v "(\.gz|\.xz|\.[0-9]|armbian-ramlog)" | while IFS= read -r file find . -type f -printf '%P\n' | grep -E -v "(\.gz|\.xz|\.[0-9]|armbian-ramlog)" | while IFS= read -r file do dest="/var/log/$file" # Fix: journal path exclusion if [[ "$dest" == */journal* ]] && [ -L $RAM_LOG/journal ]; then continue; fi # Fix: create full directory path if not exists if [ ! -d ${dest%/*} ]; then mkdir -p ${dest%/*}; fi cat $file > $dest done ;; So basically : - slightly modified the find action ( -printf '%P\n') to remove the leading dot - test and skip current file if $dest contains "/journal" and $RAM_LOG/journal is a link (to /var/log.hdd/journal). This leads to not overwrite journal files, so no truncation - added an mkdir -p so the full path is created if needed (if not there could be some errors with "deep" paths) I could submit a PR if needed. Also in armbian-truncate-log I see this line : [ -d /var/log.hdd/journal ] && find /var/log.hdd/journal -ctime 1 \( -name '*@*' -o -name '*~' \) -delete Why is it needed/done ? IMHO this could lead to delete history on ssd (permanent) storage although this truncation script seems to be purported for cleaning in-memory log partition. The path should be /var/log/ instead of /var.log.hdd, I assume (?)
arnaudf
Members
-
Joined
-
Last visited