![]() |
how to troubleshoot boot sequence?
I'm running the latest version of OS2008 on my N810, and having consistent problems booting from the internal mmc card.
The boot process hangs at the "Nokia" splash screen--the progress bar fills the screen, but nothing happens after that. The problem is consistent with or without the charger in place, and the tablet fails to continue booting after several hours. I don't think there's any problem with the mmc format or data--booting from the internal flash allows me to acces the mmc card with no errors. Here's what I've done to try to trace the boot process:
So, are there any suggestions for additional ways to trace and troubleshoot the boot process? What happens in the Maemo boot process after the init scripts complete that can cause the process to hang, and how can I get more detail on what step is hanging? Thanks! |
Re: how to troubleshoot boot sequence?
instead of editing each script in /etc/init.d you may try to edit /etc/init.d/rc and add debug code to startup() function like this
Code:
# you can also install syslog and see /var/log/syslog after unsuccessful boot to install something to nonbooting system first boot working system, connect to network, mount nonbooting system and chroot to it Code:
mount /dev/mmcblk0p2 /opt If there is no /var/log/syslog you may create it first time (not sure about this) |
Re: how to troubleshoot boot sequence?
Thanks for responding so quickly!
Quote:
The debugging shows that all of the scripts are called...now the display freezes with a screen that shows:
In a change from the boot process before editing /etc/init.d/rc, there is no blue progress bar vizible at the bottom of the screen, and no "Nokia" graphic. Do you have any suggestions about what comes next in the startup process... Is there any way to boot the tablet in text mode (runlevel 3), or to get more debugging on the steps that follow S99zzinitdone? SNIP! Quote:
Thanks! |
Re: how to troubleshoot boot sequence?
Quote:
Quote:
Quote:
|
Re: how to troubleshoot boot sequence?
I'm getting a virtually identical set of symptoms when booting off the the internal MMC on my 810.
I've updated the /etc/init.d/rc and added a number of logging statements to help identify where booting freezes and the watchdog process reboots. Here's the tail of syslog after failed boot: Code:
Feb 3 21:34:10 Nokia-N810-50-2 user: Starting temp-reaper-startup.sh Is it possible that a process started by a previous init script has hung and caused the watchdog to restart. If so, has anybody got any pointers to tracking it down? Thanks |
Re: how to troubleshoot boot sequence?
Quote:
One can also boot to usb networking recovery mode, log-in, leave the shell running and then try to continue booting and examine system (via ps or whatever) when it hangs somewhere. This needs modification of bootmenu.sh to not to shutdown usb networking. Here is the change (in bold) for binding it to menu key Code:
while true ; do Also if system reboots then one also needs modification to stop doing this (/etc/init.d/minireboot). |
Re: how to troubleshoot boot sequence?
Thanks, that approach is working and letting see further into the boot sequence.
I've updated bootmenu.sh (but not disabled minireboot yet). Here's the process list just before (within 1 sec of) the boot failing and restarting Code:
PID Uid VSZ Stat Command I'll disable minireboot next and see what results that gives. |
Re: how to troubleshoot boot sequence?
There is no X server running (/usr/bin/Xomap), this is fairly critical. At least matchbox window manager is already started so X server should be already up too. I think this is the line
Code:
Feb 3 21:34:10 Nokia-N810-50-2 user: Waiting for X |
Re: how to troubleshoot boot sequence?
I can see how that might be classed as fairly critical! :)
I'll see if manually restarting X gives any clues. Thanks. |
Re: how to troubleshoot boot sequence?
1 Attachment(s)
Well, sure enough X is exiting - here's the evidence from syslog:
Code:
Feb 5 20:28:06 Nokia-N810-50-2 DSME: Closed a client connection Manually starting X (executing "/usr/bin/Xomap -mouse tslib -nozap -dpi 96 -wr -nolisten tcp") produces the following: Code:
The XKEYBOARD keymap compiler (xkbcomp) reports: Any other suggestions, or should I give up on this installation and roll back to a previous backup? |
Re: how to troubleshoot boot sequence?
I've had similar problems. I've tried running x-server manually and it did borked out with a message that it cannot fild dsmetool (although it was there). I have modified the x-server script and put the full pathname /usr/sbin/dsmetool instead of the shell -x check and the tablet booted ok.
Just a general question but is there a early boot filesystem check for the ext2 partition when booting from the very same partition ? |
Re: how to troubleshoot boot sequence?
Quote:
You could perhaps copy some init script from debian. Just make sure to disable stuff that drops you to shell prompt requiring manual repair :-) Also as rootfs is mounted rw you need to remount it ro before checking or hack initfs. Maybe adding ro to bootmenu item filesystem options could work? |
Re: how to troubleshoot boot sequence?
Having the same problem (device stops booting at the splash screen), and having read this thread, I still wonder how I am supposed to access the file system once the system is blocked? I would do a reflash as a next step. What are my options?
|
Re: how to troubleshoot boot sequence?
Quote:
|
Re: how to troubleshoot boot sequence?
Well, the way to access the filesystem is from your other boot; you should have already cloned to SD if you're going to do this. ;)
Since (I assume) you don't have an SD with a bootable system on it, you'll pretty much have to reflash, or do serial console stuff. If, OTOH, you have such an SD about (perhaps your update just hosed bootmenu as well as bringing the system down), you can hook up with the USB cable as though to flash, and run Code:
flasher-3.0 --set-root-device mmc (I just did that one to pull my N800 out of a non-bootable (and non-updated) internal system coupled with a freshly updated (and initfs-hosing) system on the SD; still have yet to recover the internal, but it was straightforward to kick things back up like this to regain the SD...) Alternatively, if you were all set up with bootmenu + SD, you could have backed up just the initfs partition, in which case you can do a straight flash of that.That would be like Code:
flasher-3.0 -f -n initfs_custom_bootmenu.jffs |
Re: how to troubleshoot boot sequence?
I've had similar (but not the same problem) with boot sequence today and had some interesting findings about that. First of all, syslog gives much more details than any kind of manual debug output. Then there are files in /var/lib/dsme/stats showing which startup script failed and how many times (and which one was the cause to reboot).
And finally my biggest finding - I used maemo-control-services to disable some "unnecessary" stuff like multimediad (who would need sound on N810 after all :o). Afterwards I started having some problems with sound so I reenabled multimediad and decided to reboot. That's how I got into reboot loop. But fortunately I was able to boot from flash (normally I boot from external SD card), chroot into problematic partition and use syslog just to find out multimediad is dying. As I suspected, disabling it (update-rc.d is the script to do that from command line, in case anyone wonders) made the system start without problems. Moreover, I could start multimediad after bootup, but not using proper boot sequence. I also thought that maybe /usr/sbin/multimediad file got corrupted, so I uninstalled the whole multimediad package (together with bunch of other sound-related stuff) and then reinstalled again (with the same stuff). And than I was enlightened: Maemo (like Debian, I suppose) has no boot script dependency, so disabling and reenabling services may lead to borked system. In my case original multimediad links in /etc/rc?.d dirs were prefixed by 25, while after disabling and reenabling it the prefix was 20. Considering that there is a service dsp-something with prefix 24 I guess it's quite easy to figure out why multimediad crashed after toggling it off and on again. Btw. it really eludes me why there is no way to define boot script dependencies. I guess I'm a bit spoiled by Gentoo, which is my primary distribution for PCs, which eg. brings ssh down and up again when restarting network interface (basing on dependencies). There a situation like mine would never happen :p |
All times are GMT. The time now is 05:16. |
vBulletin® Version 3.8.8