TBone Posted July 28, 2016 Share Posted July 28, 2016 Hi Forum, My CT with "Armbian_5.14_Cubietruck_Debian_jessie_4.6.2" image doesn't shut down. Neither short push of power button nor shutdown -P (issued as root) doesn't really power off the board. The red LED is lightning and the display is ON, it halts after reporting "Reached Target Shutdown". The board is OK, for a long push of PB it powers off and with a Cubieez image it shuts down well. Has anyone seen this issue? What to do with it? Thanks, T Link to comment Share on other sites More sharing options...
Igor Posted July 28, 2016 Share Posted July 28, 2016 How do you power your board? Link to comment Share on other sites More sharing options...
TBone Posted July 28, 2016 Author Share Posted July 28, 2016 Both From battery and From the coaxial power plug. It behaves the same if detaching te external power. As if the last i2c commands were not sent to the pmu. Link to comment Share on other sites More sharing options...
tkaiser Posted July 28, 2016 Share Posted July 28, 2016 Both From battery and From the coaxial power plug. It behaves the same if detaching te external power. As if the last i2c commands were not sent to the pmu. We had/have the same problem with H3 legacy kernel. Linux correctly shuts down but with some kernel versions leds remained active, with others not. Since I don't wanted to waste more time I simply tried to define led trigger to heartbeat since with this setting the led will be switched off when kernel stops: https://github.com/igorpecovnik/lib/blob/master/scripts/armhwinfo#L277-L282 Would be interesting if you change this from green to red in /etc/init.d/armhwinfo in case CT's red led is accessible from userspace. Link to comment Share on other sites More sharing options...
zador.blood.stained Posted July 28, 2016 Share Posted July 28, 2016 Would be interesting if you change this from green to red in /etc/init.d/armhwinfo in case CT's red led is accessible from userspace. No, red LED is connected directly to 3.3v power, so it's a clear sign that PMU doesn't shut down correctly. I just tested my cubietruck, and there are no issues with shutdown (Debian Stretch, kernel 4.6.4, powered from barrel plug and battery) 1 Link to comment Share on other sites More sharing options...
TBone Posted July 28, 2016 Author Share Posted July 28, 2016 How can I know the board revision? Tomorrow I will try with the original image without any extra package installed. Now I use hostapd, dnsmasq samba. I tried to stop all of the services I installed but it didn't help. Link to comment Share on other sites More sharing options...
zador.blood.stained Posted July 28, 2016 Share Posted July 28, 2016 Tomorrow I will try with the original image without any extra package installed. Now I use hostapd, dnsmasq samba. I tried to stop all of the services I installed but it didn't help. Shutdown problem may be caused by extra kernel modules (so kernel crashes on modules unload) or connected peripherials (i.e. USB devices). Are you using hostapd with onboard Wi-Fi module or with USB wireless adapter? Link to comment Share on other sites More sharing options...
TBone Posted July 28, 2016 Author Share Posted July 28, 2016 I'm using the onboard peripherals only. USB slot is empty. But I loaded g_mass_storage. That's the one I haven't tried to rmmod before shutdown. Link to comment Share on other sites More sharing options...
TBone Posted July 29, 2016 Author Share Posted July 29, 2016 It looks the issue is solved, CT shuts down correctly. Module g_mass_storage was preventing the normal shutdown. I added an init.d script to remove the module during shutdown. Just if someone had something similar I uploaded the script as txt file, otherwise I had no rights to attach. So, thank you very much all of you. shutdownhelper.txt 2 Link to comment Share on other sites More sharing options...
tkaiser Posted July 29, 2016 Share Posted July 29, 2016 Thanks for the inspiration, added this to our most 'mis-used' init script as commented example Link to comment Share on other sites More sharing options...
Recommended Posts