We have Beaglebone black based custom board with 256MB RAM and 4GB eMMC.
We upgraded from Linux-3.12 to Linux-4.4 and busybox-1.20.2 to busybox-1.26.2.
Now in busybox-1.26.2 we are seeing and issue which was not there in busybox-1.20.2
I added following code in the one of the last init script.
if [ -f /home/ankur ] ; then
count=50
rm /home/ankur
echo "----Check Whoami----"
whoami #prints root
reboot
echo "--------------------"
while [ true ]
do
count=$((count - 1 ))
echo "Count = $count"
if [ $count -le 0 ];then
break;
fi
echo "Sleep 1"
sleep 1
done
fi
I touched the file in /home/ankur and then rebooted the board.
What I observed is, system didn't reboot but counter went down to 0 and then other init script executed and then board rebooted.
So it seems like busybox is getting signal for reboot but handling only after init scripts executed.
Now my question, is there a way to reboot the board before completion of all init scripts. Is there any busybox config which will disable this reboot blockage ?
reboot -f(force reboot without going through init) works but we need to run the stop script also so can't use it.