[mythtv-users] Can't suspend more than once
Leighton Brough
brough at baremetalsoft.com
Thu Jan 25 14:44:42 UTC 2007
> I can now suspend-to-RAM and successfully restore and start watching
> TV again, however if I try to suspend a second time it doesn't happen.
> I see the following items in the backend log:
>
> ...
> 2007-01-25 18:39:03.060 TVRec(1): Changing from WatchingLiveTV to None
> 2007-01-25 18:39:03.206 Finished recording Unknown: channel 1511
> 2007-01-25 18:39:24.374 I'm idle now... shutdown will occur in 15 seconds.
> 2007-01-25 18:39:33.692 5 secs left to system shutdown!
> 2007-01-25 18:40:19.780 Expiring Unknown from Thu Jan 25 18:37:33
> 2007, 0 MBytes, forced expire (LiveTV recording)
> ...
>
> After telling me there's 5 seconds left till shutdown it keeps on
> expiring old recordings and doesn't shut down - what could be
> happening?
>
>
If you have configured the backend shutdown command to be your
suspend-to-RAM script, then the backend is probably getting confused
when your script returns (i.e. when the system wakes from STR). I found
I needed to make a really minor hack to the source, or the backend
doesn't run the shutdown script again because it still thinks it's
shutting down.
For the 0.20 fixes version from SVN, the hack looks like:
Index: programs/mythbackend/scheduler.cpp
===================================================================
--- programs/mythbackend/scheduler.cpp (revision 12638)
+++ programs/mythbackend/scheduler.cpp (working copy)
@@ -1444,6 +1444,7 @@
blockShutdown))
{
ShutdownServer(prerollseconds);
+ idleSince = QDateTime();
}
}
@@ -1596,6 +1597,8 @@
// and now shutdown myself
myth_system(halt_cmd.ascii());
}
+
+ m_isShuttingDown = false;
}
This should be pretty self explanatory is you're a C coder, but I guess
isn't much use if you don't want to modify the source.
Leighton
More information about the mythtv-users
mailing list