[mythtv-users] Mythbackend crashing (?), won't restart (can't bind socket)

Keith Layne keith at laynes.org
Sat Dec 30 06:17:44 UTC 2006


Hi,

I am running the latest svn version of myth, and am experiencing some weird
behaviour.  I used to occasionally have the frontend fail to start live TV,
or tell me that the tuner (I only have one) was busy even though I knew it
was not.  In this case, I would ssh into the myth server and use the init.d
script to restart the service.  This was mildly annoying, but was only
occasional.

At some point, the problem got worse.  Now I get the same problem in the
frontend, including no schedules showing up (but still can access file in
mythmusic/video).  However, when I try to run the init script to restart, it
fails.  Somehow (I'm not exactly sure where) the killproc() function is
failing.  It really doesn't give me any more info.  The process is killed,
but the lockfile is never removed.  That's not the real problem.  The
process is zombied and never gets cleaned up.  I tried sending SIGCHLD to
init, but that didn't do anything.  Anyway, on restart attempts I get the
following:

QServerSocket: failed to bind or listen to the socket
2006-12-29 21:00:44.135 Failed to bind port 6543. Exiting.

Here is what netstat tells me:

[root at server]# netstat -lnp | grep 6543
tcp        0      0 0.0.0.0:6543                0.0.0.0:*
CLOSE_WAIT	-


The socket never gets released (not after at least a couple of hours
anyway).  I have to reboot to get it to use the same sockets.  I remember
that in the unix sockets library that there is an option when listening to
release the socket so you can reuse it without waiting.  I don't think it
would, but could that solve the problem? (I know myth uses a QServerSocket)
It seems that somehow killing the mythbackend process does not allow a clean
shutdown.  

Here is some info about my hardware:

[root at server ~]# uname -a
Linux server 2.6.18-1.2257.fc5 #1 SMP Fri Dec 15 16:07:14 EST 2006 x86_64
x86_64 x86_64 GNU/Linux

I am using a single Hauppage PVR-150 with the ivtv driver.

I know that this may not be all the info someone might need to help me, but
I'm still going through the logs to try to figure stuff out.  Plus, I'm
hesitant to reboot in the middle of a show my wife wanted to record just to
test the system...Anyway, any help/tips/pointers in the right direction
would be appreciated.

Keith



More information about the mythtv-users mailing list