[mythtv-users] Mythbackend not doing auto-shutdown
brad+myth at templetons.com
Wed Dec 20 07:38:35 UTC 2006
On Wed, Dec 20, 2006 at 07:13:46AM +0000, Graeme Wilford wrote:
> On 19/12/06, Brad Templeton <4brad at templetons.com> wrote:
> >On Tue, Dec 19, 2006 at 07:34:58PM +0000, Graeme Wilford wrote:
> >> On 19/12/06, David Watkins <watkinshome at gmail.com> wrote:
> >> >On 19/12/06, Phill Edwards <philledwards at gmail.com> wrote:
> >> >> > I'm running MythTV 0.20 installed from ATrpm binary packages. I've
> >> >> > noticed recently that mythbackend isn't going into auto-shutdown
> >> >> > it should be. It used to work and I don't know what's changed
> >> >> > recently. If I restart the mythbackend service it immediately goes
> >> >> > into auto-shutdown.
> >> >
> >> >The only thing that ever caused me problems is when mtd is left
> >> >running (following ripping or transcoding I think). Manually killing
> >> >mtd caused the idle shutdown to be initiated.
> >> I was having these problems:
> >> 1) In 0.19 and 0.20, the auto-shutdown doesn't kick-in if any
> >> 'potential' recordings rather than 'actual' recordings are scheduled
> >> within idleWaitForRecordingTime minutes. Depending on the value you
> >> use for this, how many recording rules you have and how much gets
> >> picked up, you may not even notice.
> >> 2) In 0.20, there's a strange interaction between tvwish and
> >> mythbackend where tvwish's connection status isn't removed after it
> >> disconnects, ie. mythbackend still registers as having a frontend
> >> connected and won't shutdown after tvwish has been run.
> >> I've fixed (1) and have a patch for it. Although not the latest
> >> version, the patch should be in the mailing list archives. For (2),
> >> after adding gobs of extra debugging to the scheduler, I still
> >> couldn't see what tvwish was doing differently to mythfrontend in
> >> terms of connecting and disconnecting and have had to disable it for
> >> now...
> >> Cheers,
> >> Wilf.
> >> --
> >> Me at google | MythTV blog: http://mezzanines.blogspot.com/
> >Odd. I have not had a problem with shutdowns. I will have to see
> >if there's something new in the protocol that I am not doing when
> >I complete a session -- I just close the socket and the program
> >terminates which should close any socket in any event. For
> >you was the program hanging there?
> No, tvwish is running and terminating properly. Even after the socket
> is cleaned up, the session remains registered with the backend.
> My auto-shutdown backend debugging code lists connected sessions and
> each time I run tvwish, I end up with an additional tvwish session
> added to the list...
You could put a debug statement into tvwish's backend_command function
in mythlib.pl and see what sort of commands it is doing, and to see if
it doesn't do a DONE. Seems like a bug in Myth in any event, a closed
socket should be a closed session even if I don't do the DONE, but as far
as I can tell I do. I don't wait for an answer on DONE but I was just
copying some other code there.
More information about the mythtv-users