Anyway to detect if XBMC has locked up and to then restart it?
#1
I had XBMC lockup completely tonight. Nothing worked, no buttons on the remote worked, no keys on the keyboard did anything, no mouse movement, nothing.

On the old XBox I'd just hit the big power button and 5 seconds later we'd be back up and running. On my Linux HTPC it's also got MythTV running and at the time there were 4 shows recording so that wasn't an option. Even without the MythTV complication, a soft machine reset is at least a 30 second wait.

I'm using a Wii Remote and the Event Client running in a separate process still seemed to be working fine because I could power off the Wii Remote and then reconnect using buttons 1 + 2 and the remote vibrated like it normally does when it connects to XBMC.

Is there anyway for an Event Client to detect if XBMC is actually responding to the events it's sending?

If XBMC isn't responding, is there anyway to restart it?

I really want XBMC to be my frontend rather than the MythTV frontend, but I need some sort of solution to restart XBMC when it locks up which, based on previous experience, will be at least three times a week with the myth:// integration. Eventually the HTPC won't have a keyboard or mouse, just the Wii Remote.
Reply
#2
After ssh'ing into the box, xbmc.bin was using 100% CPU as if the video was still playing. Bizarre.

Was playing an in progress HD DVB-T MythTV recording through the myth:// protocol at the time everything locked up.
Reply
#3
Write a script that attempts to connect to XBMC's EventServer or HTTP port. If you don't get a response within X number of seconds, kill the process. Depending on how you have it starting up (e.g. GDM with .xsession script), XBMC may be re-launched without further intervention. If not, you'll need to start it again in this script.

You can run the script as a cron job or you could have it daemonize itself and launch when XBMC launches.
Reply
#4
Have you considered logging what it's doing and posting so that maybe the devs can figure out the core issue? If it'd that consistant hopefully they could track it down and solve it...
Openelec Gotham, MCE remote(s), Intel i3 NUC, DVDs fed from unRAID cataloged by DVD Profiler. HD-DVD encoded with Handbrake to x.264. Yamaha receiver(s)
Reply
#5
BLKMGK Wrote:Have you considered logging what it's doing and posting so that maybe the devs can figure out the core issue? If it'd that consistant hopefully they could track it down and solve it...

Yes, I've raised another enhancement request (http://forum.xbmc.org/showthread.php?p=260677) so we can do this more easily. Either way I need a solution to it locking up right now. Hopefully it won't be necessary one day...
Reply
#6
Have you checked the existing log it already creates?
Openelec Gotham, MCE remote(s), Intel i3 NUC, DVDs fed from unRAID cataloged by DVD Profiler. HD-DVD encoded with Handbrake to x.264. Yamaha receiver(s)
Reply
#7
No, wasn't sure it would have enough information. Probably should have. The log is being written to a RAM disk on /var/tmp as the root partition is on a compact flash drive so whatever was there is gone now.

I've updated the logging settings in advancedsettings.xml to contain debugging information so next time it happens I'll copy the log file to a permanent drive location via ssh and have a look.

Sorry this all seems arse about face. I'll try my best to provide information about why it's locking up, so the bigger problem can be resolved. For the moment I'm trying to get the HTPC robust enough that I can toss out the old XBox. It really is amazing how good the XBMC experience was on the XBox hardware after spending what seems like an eternity trying to get a similar level of experience on a Linux box - many of the issues completely unrelated to XBMC. If only the XBox could play HD Smile
Reply
 
Thread Rating:
  • 1 Vote(s) - 5 Average



Logout Mark Read Team Forum Stats Members Help
Anyway to detect if XBMC has locked up and to then restart it?51
This forum uses Lukasz Tkacz MyBB addons.