Lucil Posted September 19, 2018 Posted September 19, 2018 I've been using an OrangePi Zero hw rev. 1.5 for a few months with no issues, using the Stretch mainline image (4.x kernel). Suddenly the filesystem became read-only. I thought it was a SD card issue so I burned a fresh armbian to a new card. But the device does not show up in the DHCP pool with an allocated IP. Being withought a HDMI connector, an OPi Zero must be accessed via SSH. I've tried all versions, mainline and legacy. Only with Jessie legacy image, it gets an IP from the DHCP pool just on the very first boot. After that, it does not show up. I've tried the images provided by OrangePI and their Ubuntu and Raspbian images work. They have Ubuntu 14.x and Raspbian Jessie. Another strange behavior: the device has different MACs, depending an the distribution used. I think maybe it's something related to this, being one of those el-cheapo adapters with no proper MAC?
chwe Posted September 19, 2018 Posted September 19, 2018 6 minutes ago, Lucil said: an OPi Zero must be accessed via SSH. nope it can be either accessed via USB-UART adapter (that's what those 3 pins near to RJ45 are for.. Or with armbian via USB gadget mode. 11 minutes ago, Lucil said: Another strange behavior: the device has different MACs, depending an the distribution used. I think maybe it's something related to this, being one of those el-cheapo adapters with no proper MAC? yep 11 minutes ago, Lucil said: I've tried all versions, mainline and legacy. Only with Jessie legacy image, it gets an IP from the DHCP pool just on the very first boot. After that, it does not show up. hmm that sounds strange.. But with your previous armbian it worked properly on the same router via DHCP? 1
botfap Posted September 19, 2018 Posted September 19, 2018 Can you try setting the connection details and IP address manually in your image before boot? Does it still not connect? If your device has been randomizing mac addresses, then your DHCP pool may have run out of addresses, even though it doesn't list them as used If you run tcpdump on the dhcp box can you see any DHCP negotiation traffic? 1
Lucil Posted September 19, 2018 Author Posted September 19, 2018 11 minutes ago, chwe said: hmm that sounds strange.. But with your previous armbian it worked properly on the same router via DHCP? Yes, that's why I think it's strange. 9 minutes ago, botfap said: Can you try setting the connection details and IP address manually in your image before boot? Does it still not connect? If your device has been randomizing mac addresses, then your DHCP pool may have run out of addresses, even though it doesn't list them as used If you run tcpdump on the dhcp box can you see any DHCP negotiation traffic? I don't know how to insert the conn details in the image. I don't think I can run tcpdump on the router, as its a TP Link with the stock firmware. As for running out of address space, no, I've tried rebooting the routher, but it has no effect. The box is smart enough to assign the same address to the same MAC. Presumably it's a difference between the image built a few months ago (I think april or may) and today. And because the older OrangePi supplied images work. And because with the older jesse image it boots the first time.
Lucil Posted September 19, 2018 Author Posted September 19, 2018 19 minutes ago, chwe said: Or with armbian via USB gadget mode. How do I do this? It would be great for debugging - to see what's actually going on.
botfap Posted September 19, 2018 Posted September 19, 2018 Try pre configuring the image and network with a static IP before boot There is a simple script in dev that will do that here: https://github.com/botfap/armbian-image-config git clone https://github.com/botfap/armbian-image-config.git cd armbian-image-config For Ethernet: sudo ./armbian-image-config armbian-image.img e|ethenet [dhcp|static] [ipaddr mask] [gw] [dns] e.g. sudo ./armbian-image-config armbian-image.img ethernet static 10.0.0.50 255.255.255.0 10.0.0.254 9.9.9.9 mynet.lan For Wifi: sudo ./armbian-image-config armbian-image.img w|wifi [dhcp|static] ssid key [ipaddr mask] [gw] [dns] [search] e.g. sudo ./armbian-image-config armbian-image.img wifi static MyWifiAP MySecret 10.0.0.51 255.255.255.0 10.0.0.254 9.9.9.9 mynet.lan Obviously replace armbian-image.img with the path and name or your Armbian image file. Then write that file back to SD Card 1
chwe Posted September 19, 2018 Posted September 19, 2018 8 minutes ago, Lucil said: 28 minutes ago, chwe said: Or with armbian via USB gadget mode. How do I do this? It would be great for debugging - to see what's actually going on. well.. just written minutes ago.. tested with current debian server from armbian.com downloadpage (Armbian_5.59_Orangepizero_Debian_stretch_next_4.14.65) on an orangepizero.. Well, let's see if this helps first.. and then we might have a look into the other issues you face.
martinayotte Posted September 19, 2018 Posted September 19, 2018 53 minutes ago, Lucil said: an OPi Zero must be accessed via SSH. Not on the first boot where you didn't provide your WiFi SSID/Password yet ...
Lucil Posted September 19, 2018 Author Posted September 19, 2018 1 hour ago, martinayotte said: Not on the first boot where you didn't provide your WiFi SSID/Password yet ... Obviously I'm using the wired connection. Trying the other sugestions above and will report back. LE: I found a solution... sort of. I did a clean install of an Armbian image (both mainline images work). Booted the first time without the ethernet cable inserted and I inserted the cable after the boot activity stopped (after about a minute). The device did get an IP address this time. I logged in through SSH and configured wireless. And now it works via wireless, onboard adapter. Thinking way back, it is possible that the first time I did the same, configured wireless on the first boot and then used it like that for months. The problems actually began when I moved and repurposed the device and tried to use it wired. Maybe the wired connection was acting all along. As for the suggestions above, I tried configuringit with static network info, but it didn't solve anything. Haven't tried the serial over USB yet.
chwe Posted September 19, 2018 Posted September 19, 2018 6 hours ago, Lucil said: I found a solution... sort of. that's not a solution, that's a workaround.. and IMO a shitty one due to wifi for the OPi zero can be.... uncool If it would be my board, I would prefer to have this fixed befor wifi might quit in the future.. Just as a first one 'sudo armbianmonitor -u' can be helpful see comment at the download page: Quote Onboard wireless module (XR819) has poor software support so wireless connection issues are expected USB gadget mode can be something to test.. And as @martinayotte mentions everytime, and I second that: spending 1-2$ for an USB to UART adapter is it worth when working with SBCs. 1
martinayotte Posted September 19, 2018 Posted September 19, 2018 26 minutes ago, chwe said: I second that: spending 1-2$ for an USB to UART adapter is it worth when working with SBCs. Right ! I've more than 10 around : some FT232, some CH340, some PL2303 and some CP2102 ... 2
Uli Nichtder Posted September 20, 2018 Posted September 20, 2018 (edited) Hi there, after upgrading my OneZero "Farm" as well, I got the same problem. After upgrading to the latest release (they were shut down for a couple of months) and the mandatory reboot after that none of my three Pi Zeros were reachable by ethernet any more... Checking the config on the cards all seems fine. I can confirm that your workaround is the only working one so far - If I plug in the network cable after they're bootet up gives me a valid IP address as well. But thats a real showstopper for a small opi-zero cluster for testing...:-) The funny thing is, I modified my Image with the config Editor ./armbian-image-config Armbian_5.59_Orangepizero_Debian_stretch_next_4.14.65.img ethernet static 192.168.64.81 255.255.255.0 192.168.64.254 192.168.64.254 mynet.lan remote ssh enabled ethernet network with ip 192.168.64.81 active for image: Armbian_5.59_Orangepizero_Debian_stretch_next_4.14.65.img Which is *completely* ignored... (but if I configure a static IP after booting, this config is kept.. but the reboot problem with connected ethernet persists anyway :-( Did something essental got changed regarding the network configuration? Thanks alot! Cheers Uli Edited September 20, 2018 by Uli Nichtder additional information
chwe Posted September 20, 2018 Posted September 20, 2018 can you provide the output of sudo armbianmonitor -u ? @Igor probably something we should keep an eye on even when my OPi0 didn't had problems with upgrade/reboot.
Igor Posted September 21, 2018 Posted September 21, 2018 7 hours ago, Uli Nichtder said: Did something essental got changed regarding the network configuration? Configuration not, but there were changes on the lower level which could provoke such weird problems. I would try to boot the system with the previous version of u-boot, than leaving u-boot and change kernel ...
Uli Nichtder Posted September 21, 2018 Posted September 21, 2018 5 hours ago, chwe said: can you provide the output of sudo armbianmonitor -u ? @Igor probably something we should keep an eye on even when my OPi0 didn't had problems with upgrade/reboot. I am just uploading this: http://ix.io/1n9U (when or where is this data collected? because that is not true, neither for eth0 nor for wlan0 2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000 link/ether 02:42:38:94:64:9d brd ff:ff:ff:ff:ff:ff) Currently THAT is the correct state...: 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000 inet 192.168.64.81/24 scope global eth0 valid_lft forever preferred_lft forever The funny thing is though, when I kept ethernet unpluged while booting, plugged it in after booting, I got a DHCP Address the first time. Then I configured (again) a fixed IP address with armbian-config, which did NOT work after a plugged reboot. Then I repeated that, gaining access again and configured additionaly wifi (which gets also an IP address by DHCP but from a completey different Network). After the next reboot (ethernet plugged in) Wifi was accessible, ethernet was not. But now I could log in via Wifi and saw "eth0" was up (!) but had not been assigned any IP Address - since it should be a fixed one now, the problem does not be dhcp related it seems. The very funny thing is, if i do (and I did :-) a ip add add 192.168.64.81/64 dev eth0 everything I gained a connection again.... So.... nic drivers are good, 'ip li sho' tells me it's detected a link but neither dhcp nor fixed ip address by networkmanager assigns correctly.... so it seems to be a network manager issue. I'll investigate this further... Cheers,
Uli Nichtder Posted September 21, 2018 Posted September 21, 2018 ...its the networkmanager 'crap' which is causing the problems.... I did a very quick and dirty hack und added # By default this script does nothing. ip add add 192.168.64.82/24 dev eth0 ip ro add default via 192.168.64.254 exit 0 in /etc/rc.local.... and guess what, my orange pi is booting with network connection established every time. So, it has to be the network manager causing the trouble... Cheers,
gregvp Posted September 22, 2018 Posted September 22, 2018 This problem is reported in Ubuntu 18.04 generally. The fix hack I am using is to add "@reboot /sbin/dhclient" to the crontab. (sudo crontab -e). Network manager is getting like alsa (and systemd) -- more trouble than it is worth, in all use cases except Lennart Poettering's laptop.
Uli Nichtder Posted September 22, 2018 Posted September 22, 2018 5 hours ago, gregvp said: This problem is reported in Ubuntu 18.04 generally. The fix hack I am using is to add "@reboot /sbin/dhclient" to the crontab. (sudo crontab -e). Network manager is getting like alsa (and systemd) -- more trouble than it is worth, in all use cases except Lennart Poettering's laptop. Ouch.... that is even more quick'n dirtier than my rc.local solution eeeehh.....:) Didn't think that was possible:-) (Because: since is is user related, you cannot directly find it in the /etc if you are searching for something like that) Cheers
Lucil Posted September 22, 2018 Author Posted September 22, 2018 It's not just Ubuntu related. The Debian image has the same problem. And while we're on networking-related issues, with wi-fi conn my Opi Zero runs for about 36 hours, then locks and needs a hard reboot. It has always done that, but there's nothing useful in the logs. It just freezes. I suspect a wifi driver problem, some kind of overflow perhaps. "Solved" it with a daily cron reboot. Mine is HW rev. 1.5, mfg in March this year (according to the sticker), if it matters.
rufik Posted September 22, 2018 Posted September 22, 2018 Since I got rid of network manager (configured in old good way) my SBC connection is rock solid. Network Manager is not reliable somehow... 1
Lucil Posted September 23, 2018 Author Posted September 23, 2018 I can confirm that removing network-manager and configuring the interfaces via /etc/network/interfaces does the trick (at least for now).
chwe Posted September 23, 2018 Posted September 23, 2018 On 9/22/2018 at 2:03 PM, Lucil said: I suspect a wifi driver problem, some kind of overflow perhaps. OPi0's wifi chip XR819 is known to be crappy see: and also mentioned on the DL page.. On 9/22/2018 at 10:12 AM, Uli Nichtder said: Ouch.... that is even more quick'n dirtier than my rc.local solution eeeehh.....:) Didn't think that was possible:-) (Because: since is is user related, you cannot directly find it in the /etc if you are searching for something like that) I think a 'somehow' proper solution would be similar to this one: https://github.com/armbian/build/blob/b554f3d003dcad862ac27bd0eb74ee4381a6366b/lib/distributions.sh#L253-L259 e.g. tell NM that eth0 isn't his business anymore.. I'm not sure if it survives an upgrade. For bionic: just tell them that NM isn't your renderer anymore: https://github.com/armbian/build/blob/b554f3d003dcad862ac27bd0eb74ee4381a6366b/lib/distributions.sh#L334-L337 These are both workarounds not really solutions. On 9/22/2018 at 4:35 AM, gregvp said: Network manager is getting like alsa (and systemd) -- more trouble than it is worth, in all use cases except Lennart Poettering's laptop. Well, if you don't like NM, there's still networkd left for you..
Recommended Posts