Mailing List Archive

mythbackend segfaulting (reason unknown)
Mythbackend is segfaulting... here is what it's spitting out.


jeff@corsair bin]$ gdb mythbackend
GNU gdb 5.3-22mdk (Mandrake Linux)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "i586-mandrake-linux-gnu"...
(gdb) run
Starting program: /usr/local/bin/mythbackend
[New Thread 16384 (LWP 2781)]
Starting up as the master server.
Probed: /dev/v4l/video0 - Television
Probed: /dev/v4l/video0 - Composite1
Probed: /dev/v4l/video0 - S-Video
[New Thread 32769 (LWP 2786)]
[New Thread 16386 (LWP 2787)]
[New Thread 32771 (LWP 2788)]
adding: corsair as a player 1
adding: corsair as a player 0
ERROR opening file '/home/jeff/mythtv//ringbuf3.nuv' in
ThreadedFileWriter.
adding: corsair as a player 0
adding: corsair as a remote ringbuffer
[New Thread 49156 (LWP 2802)]
Changing from None to WatchingLiveTV
[New Thread 65541 (LWP 2803)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 65541 (LWP 2803)]
0x40a81fdc in memcpy () from /lib/i686/libc.so.6
(gdb)



Here is what mythfrontend is outputting on the debug..

[jeff@corsair bin]$ gdb mythfrontend
GNU gdb 5.3-22mdk (Mandrake Linux)
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "i586-mandrake-linux-gnu"...
(gdb) run
Starting program: /usr/local/bin/mythfrontend
[New Thread 16384 (LWP 2888)]
connecting to backend server: 127.0.0.1:6543
^[[D[New Thread 32769 (LWP 2899)]
[New Thread 16386 (LWP 2900)]


Any suggestions or help would be awesome, I wanted to get this working
again, had it working in mandy 9.0 but stupid me blew it out. So
upgraded to 9.1 and almost have it working again.

Downloaded fresh copies of 8.0 and xml 0.5.10 (neither cvs).

Basically mythfilldatabase runs fine and I get mythtv running and have
no problems until I try to record or watch tv. I know the video card
works as it's perfect in xawtv and worked before on mandy 9.0.

Thanks,
Jeff
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
I know this is probably not what you want to hear but I changed
/etc/init.d/myth-backend from

#USER=mythtv
to
USER=root

and the crashes went away.

Not that this is a good idea, But it will let you watch tv, and record.

--------------------------------------------------------------
James S. White GAPS Incorporated
james@gapsinc.com Electrical Engineer - Etc.
http://www.jameswhite.org Caffeine is my anti-drug.
--------------------------------------------------------------
How many people have to die before we put an end to dying altogether?
-- theonion.com

On 6 Jun 2003, Jeff Waters wrote:

> Mythbackend is segfaulting... here is what it's spitting out.
>
>
> jeff@corsair bin]$ gdb mythbackend
> GNU gdb 5.3-22mdk (Mandrake Linux)
> Copyright 2002 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you
> are
> welcome to change it and/or distribute copies of it under certain
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB. Type "show warranty" for
> details.
> This GDB was configured as "i586-mandrake-linux-gnu"...
> (gdb) run
> Starting program: /usr/local/bin/mythbackend
> [New Thread 16384 (LWP 2781)]
> Starting up as the master server.
> Probed: /dev/v4l/video0 - Television
> Probed: /dev/v4l/video0 - Composite1
> Probed: /dev/v4l/video0 - S-Video
> [New Thread 32769 (LWP 2786)]
> [New Thread 16386 (LWP 2787)]
> [New Thread 32771 (LWP 2788)]
> adding: corsair as a player 1
> adding: corsair as a player 0
> ERROR opening file '/home/jeff/mythtv//ringbuf3.nuv' in
> ThreadedFileWriter.
> adding: corsair as a player 0
> adding: corsair as a remote ringbuffer
> [New Thread 49156 (LWP 2802)]
> Changing from None to WatchingLiveTV
> [New Thread 65541 (LWP 2803)]
>
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread 65541 (LWP 2803)]
> 0x40a81fdc in memcpy () from /lib/i686/libc.so.6
> (gdb)
>
>
>
> Here is what mythfrontend is outputting on the debug..
>
> [jeff@corsair bin]$ gdb mythfrontend
> GNU gdb 5.3-22mdk (Mandrake Linux)
> Copyright 2002 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you
> are
> welcome to change it and/or distribute copies of it under certain
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB. Type "show warranty" for
> details.
> This GDB was configured as "i586-mandrake-linux-gnu"...
> (gdb) run
> Starting program: /usr/local/bin/mythfrontend
> [New Thread 16384 (LWP 2888)]
> connecting to backend server: 127.0.0.1:6543
> ^[[D[New Thread 32769 (LWP 2899)]
> [New Thread 16386 (LWP 2900)]
>
>
> Any suggestions or help would be awesome, I wanted to get this working
> again, had it working in mandy 9.0 but stupid me blew it out. So
> upgraded to 9.1 and almost have it working again.
>
> Downloaded fresh copies of 8.0 and xml 0.5.10 (neither cvs).
>
> Basically mythfilldatabase runs fine and I get mythtv running and have
> no problems until I try to record or watch tv. I know the video card
> works as it's perfect in xawtv and worked before on mandy 9.0.
>
> Thanks,
> Jeff
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@snowman.net
> http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
>
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
On Friday 06 June 2003 02:26 pm, Jeff Waters wrote:
> Mythbackend is segfaulting... here is what it's spitting out.
<snip>
> ERROR opening file '/home/jeff/mythtv//ringbuf3.nuv' in
> ThreadedFileWriter.
<snip>

Don't know why I even bother printing out error messages, really.

Isaac
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

> ERROR opening file '/home/jeff/mythtv//ringbuf3.nuv' in
> ThreadedFileWriter.

This is a clue. Why isn't the file able to be created? Does
mythbackend have the permissions to create this file in this
directory? Does it exist?


-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>

iQA/AwUBPuDmGPc1NpCTlP0JEQLiXwCg/hmSDDMPzvCQjdIp2XrqyOSgrT8An1gj
SzexcdIXGsX0gNTUwX50Zc8D
=A26w
-----END PGP SIGNATURE-----
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
At 01:40 PM 6/6/2003 -0500, James S. White wrote:
>I know this is probably not what you want to hear but I changed
>/etc/init.d/myth-backend from
>
>#USER=mythtv
>to
>USER=root
>
>and the crashes went away.
>
>Not that this is a good idea, But it will let you watch tv, and record.


James -- If I were to guess from this quasi-solution (and the original
symptom) about what is going on, it would be that you (the mythtv userid, I
mean) do not have permission to access some needed device. A sound device
is a good candidate (is mythtv a member of group audio? group video?).

I've seen mythbackend fail ugly when it cannot access a resource,
particularly when run from an init script.
[older messages deleted]
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
That's what I assumed as well. I added mythtv (the user I run it as) to
the audio and video groups, I also tried chmod 666 on /dev/audio*, /dev/dsp*,
/dev/vbi*, and /dev/video*.

Still No Joy.

--------------------------------------------------------------
James S. White GAPS Incorporated
james@gapsinc.com Electrical Engineer - Etc.
http://www.jameswhite.org Caffeine is my anti-drug.
--------------------------------------------------------------
How many people have to die before we put an end to dying altogether?
-- theonion.com

On Fri, 6 Jun 2003, Ray Olszewski wrote:

> At 01:40 PM 6/6/2003 -0500, James S. White wrote:
> >I know this is probably not what you want to hear but I changed
> >/etc/init.d/myth-backend from
> >
> >#USER=mythtv
> >to
> >USER=root
> >
> >and the crashes went away.
> >
> >Not that this is a good idea, But it will let you watch tv, and record.
>
>
> James -- If I were to guess from this quasi-solution (and the original
> symptom) about what is going on, it would be that you (the mythtv userid, I
> mean) do not have permission to access some needed device. A sound device
> is a good candidate (is mythtv a member of group audio? group video?).
>
> I've seen mythbackend fail ugly when it cannot access a resource,
> particularly when run from an init script.
> [older messages deleted]
>
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@snowman.net
> http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
>
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
Ray Olszewski wrote:

> At 01:40 PM 6/6/2003 -0500, James S. White wrote:
>
>> #USER=mythtv
>> to
>> USER=root
>>
>> and the crashes went away.
>
From what Isaac quoted so funnily, the reason should be obvious
(compare subject): You set the video storage dir to the home dir of your
account jeff, but account mythtv of course has no access to that (by
default). root does. Set the storage dir to something sensible and make
sure that account mythtv can access it (read/write) and it should be OK.

> I've seen mythbackend fail ugly when it cannot access a resource,
> particularly when run from an init script.

The error message that Isaac quoted were totally clear.

Ben
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hrmm. Sounds like maybe your login program is handling some of the
permissions; I seem to remember something similar where if the first
login is root, then it would setup devices for root and local users
couldn't access the devices in the devfs hierarchy because of
owner/group information. Did you look through devfsd.conf and
friends at the permissions?


-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>

iQA/AwUBPuEWI/c1NpCTlP0JEQKpUgCfUsn4Bri5Dyo6QgizHMOltdIJ5BYAn1Ms
dvul5mNur2gKDj3cJcxxFgaT
=+oWU
-----END PGP SIGNATURE-----
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

> Hrmm. Sounds like maybe your login program is handling some of the
> permissions; I seem to remember something similar where if the
> first login is root, then it would setup devices for root and local
> users couldn't access the devices in the devfs hierarchy because of
> owner/group information. Did you look through devfsd.conf and
> friends at the permissions?

Of course, having a non-root user trying to access a user directory
that's not your own is going to cause problems as well. Why are you
running as mythtv, but putting the ringbuffer into /home/jeff? Don't
do that. Put it somewhere accessible to all users, especially if
you're running as a daemon.

-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>

iQA/AwUBPuEaMPc1NpCTlP0JEQIHDQCgk51a8FKsSca02uTrttXRFtIteWQAoIp/
s8I1d836krvOEV3p3UbYd+zP
=8D+V
-----END PGP SIGNATURE-----
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
On Fri, 2003-06-06 at 18:48, Robert Kulagowski wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> > Hrmm. Sounds like maybe your login program is handling some of the
> > permissions; I seem to remember something similar where if the
> > first login is root, then it would setup devices for root and local
> > users couldn't access the devices in the devfs hierarchy because of
> > owner/group information. Did you look through devfsd.conf and
> > friends at the permissions?
>
> Of course, having a non-root user trying to access a user directory
> that's not your own is going to cause problems as well. Why are you
> running as mythtv, but putting the ringbuffer into /home/jeff? Don't
> do that. Put it somewhere accessible to all users, especially if
> you're running as a daemon.
>
> -----BEGIN PGP SIGNATURE-----
> Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
>
> iQA/AwUBPuEaMPc1NpCTlP0JEQIHDQCgk51a8FKsSca02uTrttXRFtIteWQAoIp/
> s8I1d836krvOEV3p3UbYd+zP
> =8D+V
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@snowman.net
> http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
>


Thanks all I've tried some things, first I found many of the files in my
mythtv-0.8 directory where I un-compressed the files to were owned by
root.
So I wiped the file and untar'd the file again, this time making sure it
was all under my name and not root. Compiled and config'd under my name
and su'd to install. Now I ran again as myself mythbackend and frontend.
Again the back end segfaulted. So I su'd to root and re-ran back and
front to be sure I didn't have permission problems, again backend
segfaulted.

Also James I don't have a /etc/init.d/myth-backend file.. all my run
files for myth are in /usr/local/bin/. I opened up mythbackend thinking
I could edit this as you did yours but that was not possible.

Any other suggestions?

Thanks,
Jeff
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
My problem was indeed permissions. Check your cache (buffer) and Record
directories. They are the directories on page two of the "General"
setup in mythtv-setup. They must be writable by the user mythtv-backend
runs as. I set them up as root which is why the mythtv user couldn't
write to them.

Thanks to everyone who replied.

Now I need to know if anyone has a joy2key rc file for the myth apps?
I hope to have USB Logitech Wingman control by tomorrow. :)

--------------------------------------------------------------
James S. White GAPS Incorporated
james@gapsinc.com Electrical Engineer - Etc.
http://www.jameswhite.org Caffeine is my anti-drug.
--------------------------------------------------------------
How many people have to die before we put an end to dying altogether?
-- theonion.com

On 6 Jun 2003, Jeff Waters wrote:

> On Fri, 2003-06-06 at 18:48, Robert Kulagowski wrote:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > > Hrmm. Sounds like maybe your login program is handling some of the
> > > permissions; I seem to remember something similar where if the
> > > first login is root, then it would setup devices for root and local
> > > users couldn't access the devices in the devfs hierarchy because of
> > > owner/group information. Did you look through devfsd.conf and
> > > friends at the permissions?
> >
> > Of course, having a non-root user trying to access a user directory
> > that's not your own is going to cause problems as well. Why are you
> > running as mythtv, but putting the ringbuffer into /home/jeff? Don't
> > do that. Put it somewhere accessible to all users, especially if
> > you're running as a daemon.
> >
> > -----BEGIN PGP SIGNATURE-----
> > Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
> >
> > iQA/AwUBPuEaMPc1NpCTlP0JEQIHDQCgk51a8FKsSca02uTrttXRFtIteWQAoIp/
> > s8I1d836krvOEV3p3UbYd+zP
> > =8D+V
> > -----END PGP SIGNATURE-----
> >
> > _______________________________________________
> > mythtv-users mailing list
> > mythtv-users@snowman.net
> > http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
> >
>
>
> Thanks all I've tried some things, first I found many of the files in my
> mythtv-0.8 directory where I un-compressed the files to were owned by
> root.
> So I wiped the file and untar'd the file again, this time making sure it
> was all under my name and not root. Compiled and config'd under my name
> and su'd to install. Now I ran again as myself mythbackend and frontend.
> Again the back end segfaulted. So I su'd to root and re-ran back and
> front to be sure I didn't have permission problems, again backend
> segfaulted.
>
> Also James I don't have a /etc/init.d/myth-backend file.. all my run
> files for myth are in /usr/local/bin/. I opened up mythbackend thinking
> I could edit this as you did yours but that was not possible.
>
> Any other suggestions?
>
> Thanks,
> Jeff
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@snowman.net
> http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
>
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
On Fri, 2003-06-06 at 15:06, Robert Kulagowski wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> > ERROR opening file '/home/jeff/mythtv//ringbuf3.nuv' in
> > ThreadedFileWriter.
>
> This is a clue. Why isn't the file able to be created? Does
> mythbackend have the permissions to create this file in this
> directory? Does it exist?
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
>
> iQA/AwUBPuDmGPc1NpCTlP0JEQLiXwCg/hmSDDMPzvCQjdIp2XrqyOSgrT8An1gj
> SzexcdIXGsX0gNTUwX50Zc8D
> =A26w
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@snowman.net
> http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
>


LOL!, sometimes I amaze myself with the sheer stupidity I display.
Yes, I forgot to create the directory I told myth to write too.
Seems my eagerness to get this up and working again got the better of
me.

Now I need to figure out why I get a green screen when trying to record
and a black one when watching live tv :-/


Thanks,
Jeff
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
On Friday 06 June 2003 06:30 pm, Robert Kulagowski wrote:
> Hrmm. Sounds like maybe your login program is handling some of the
> permissions; I seem to remember something similar where if the first
> login is root, then it would setup devices for root and local users
> couldn't access the devices in the devfs hierarchy because of
> owner/group information. Did you look through devfsd.conf and
> friends at the permissions?

My thought also. Depending on how your system is setup, device permissions
might be reset/granted to the 'console' user based on the file
/etc/pam.d/console.perms (or something like it). I don't know about devfs...
this is how it works on my RH8 setup.

-JAC
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
I'm right there on the short bus too. I ran into some color problems when I
was watching live tv and found they were due to me accidentally hitting the
'c' key. Which cycles through your video inputs. Apparently in the WinTV
Card I have, Reading the Composite1 signal when you are wired up for S-Video
gives you black-and-white. Who knew? (Your Mileage May Vary)

> LOL!, sometimes I amaze myself with the sheer stupidity I display.
> Yes, I forgot to create the directory I told myth to write too.
> Seems my eagerness to get this up and working again got the better of
> me.
>
> Now I need to figure out why I get a green screen when trying to record
> and a black one when watching live tv :-/

--------------------------------------------------------------
James S. White GAPS Incorporated
james@gapsinc.com Electrical Engineer - Etc.
http://www.jameswhite.org Caffeine is my anti-drug.
--------------------------------------------------------------
How many people have to die before we put an end to dying altogether?
-- theonion.com
RE: mythbackend segfaulting (reason unknown) [ In reply to ]
On Fri, 2003-06-06 at 20:25, James S. White wrote:
> I'm right there on the short bus too. I ran into some color problems when I
> was watching live tv and found they were due to me accidentally hitting the
> 'c' key. Which cycles through your video inputs. Apparently in the WinTV
> Card I have, Reading the Composite1 signal when you are wired up for S-Video
> gives you black-and-white. Who knew? (Your Mileage May Vary)
>
> > LOL!, sometimes I amaze myself with the sheer stupidity I display.
> > Yes, I forgot to create the directory I told myth to write too.
> > Seems my eagerness to get this up and working again got the better of
> > me.
> >
> > Now I need to figure out why I get a green screen when trying to record
> > and a black one when watching live tv :-/
>
> --------------------------------------------------------------
> James S. White GAPS Incorporated
> james@gapsinc.com Electrical Engineer - Etc.
> http://www.jameswhite.org Caffeine is my anti-drug.
> --------------------------------------------------------------
> How many people have to die before we put an end to dying altogether?
> -- theonion.com
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@snowman.net
> http://lists.snowman.net/cgi-bin/mailman/listinfo/mythtv-users
>

Yea it's working, now.. haha.. I have to now figure out how to get the
bt878 sound to work so I can do hardware recording... I tried it but was
giving me massive sound buffer overflow errors. I'll work on it later it
seems.

- Jeff
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
Jeff Waters wrote:

>LOL!, sometimes I amaze myself with the sheer stupidity I display.
>
hehe :)

>Yes, I forgot to create the directory I told myth to write too.
>
Yes, that's an easy trap to fall into - probably too easy. Windows
installers ask the user, if he wants to create the directory, if the
chosen directory doesn't exist. Maybe that could be an idea.

(yeah, I know, I should spply a patch.)
Re: mythbackend segfaulting (reason unknown) [ In reply to ]
On Saturday 07 June 2003 12:12 am, Ben Bucksch wrote:
> Yes, that's an easy trap to fall into - probably too easy. Windows
> installers ask the user, if he wants to create the directory, if the
> chosen directory doesn't exist. Maybe that could be an idea.
>
> (yeah, I know, I should spply a patch.)

Damn straight =) I _have_ made this particular error more obvious since 0.8,
though -- it now just exits after printing it out, instead of trying to
continue and dying.

Isaac