View previous topic :: View next topic |
Author |
Message |
maqe Tux's lil' helper
Joined: 11 Feb 2006 Posts: 75
|
Posted: Mon Jul 31, 2006 7:21 pm Post subject: MythTV: frontend and backend init scripts |
|
|
I´m running latest mythtv from svn / fixes-release and i can not get mythbackend to start from boot and i can not get mythfrontend to start when i enter X. Can anyone help me with some inits scripts that work? |
|
Back to top |
|
|
belrpr Guru
Joined: 22 May 2006 Posts: 440
|
Posted: Mon Jul 31, 2006 7:29 pm Post subject: Re: MythTV: frontend and backend init scripts |
|
|
maqe wrote: | I´m running latest mythtv from svn / fixes-release and i can not get mythbackend to start from boot and i can not get mythfrontend to start when i enter X. Can anyone help me with some inits scripts that work? |
For the backend:
rc-update add mythbackend default
then it will start at boot time. |
|
Back to top |
|
|
maqe Tux's lil' helper
Joined: 11 Feb 2006 Posts: 75
|
Posted: Mon Jul 31, 2006 7:33 pm Post subject: Re: MythTV: frontend and backend init scripts |
|
|
belrpr wrote: | maqe wrote: | I´m running latest mythtv from svn / fixes-release and i can not get mythbackend to start from boot and i can not get mythfrontend to start when i enter X. Can anyone help me with some inits scripts that work? |
For the backend:
rc-update add mythbackend default
then it will start at boot time. |
When i compile from source i don´t get any init scripts at all... |
|
Back to top |
|
|
Nicias Guru
Joined: 06 Dec 2005 Posts: 446
|
Posted: Mon Jul 31, 2006 7:55 pm Post subject: |
|
|
check out the files /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.rc and /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.conf.
Copy them as /etc/init.d/mythbackend and /etc/conf.d/mythbacked respectively. That should do it for init files. |
|
Back to top |
|
|
beandog Bodhisattva
Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Mon Jul 31, 2006 8:03 pm Post subject: Re: MythTV: frontend and backend init scripts |
|
|
maqe wrote: | I´m running latest mythtv from svn / fixes-release and i can not get mythbackend to start from boot and i can not get mythfrontend to start when i enter X. Can anyone help me with some inits scripts that work? |
Just put the startup in /etc/conf.d/local.start, and then add it to the default runlevel.
Code: | # vim /etc/conf.d/local.start
su - username -c "/usr/local/bin/mythbackend &"
# rc-update add local default |
For mythfrontend, I recommend starting X with a non-root user, and having mythfrontend startup when your WM starts. The setup for that depends on which one you're using though. _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
|
maqe Tux's lil' helper
Joined: 11 Feb 2006 Posts: 75
|
Posted: Mon Jul 31, 2006 8:15 pm Post subject: |
|
|
Nicias wrote: | check out the files /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.rc and /usr/portage/media-tv/mythtv/files/mythbackend-0.18.2.conf.
Copy them as /etc/init.d/mythbackend and /etc/conf.d/mythbacked respectively. That should do it for init files. |
Thanks alot for the help with those...
after adding mythbackend with rc-update add mythbackend default i get a boot message that says mythbackend started ok and when i check it with rc-status i says started but if i run ps aux | grep mythbackend i can´t find it and when i tries to start mythfrontend i get an error that the backend is´t started. Nothing in /var/log/mythtv/mytbackend.log |
|
Back to top |
|
|
maqe Tux's lil' helper
Joined: 11 Feb 2006 Posts: 75
|
Posted: Mon Jul 31, 2006 8:23 pm Post subject: Re: MythTV: frontend and backend init scripts |
|
|
beandog wrote: | maqe wrote: | I´m running latest mythtv from svn / fixes-release and i can not get mythbackend to start from boot and i can not get mythfrontend to start when i enter X. Can anyone help me with some inits scripts that work? |
Just put the startup in /etc/conf.d/local.start, and then add it to the default runlevel.
Code: | # vim /etc/conf.d/local.start
su - username -c "/usr/local/bin/mythbackend &"
# rc-update add local default |
For mythfrontend, I recommend starting X with a non-root user, and having mythfrontend startup when your WM starts. The setup for that depends on which one you're using though. |
This seems to work but i get alog of ugly output when backend starts even if i use & at the end? |
|
Back to top |
|
|
beandog Bodhisattva
Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Mon Jul 31, 2006 9:13 pm Post subject: Re: MythTV: frontend and backend init scripts |
|
|
maqe wrote: | This seems to work but i get alog of ugly output when backend starts even if i use & at the end? |
Sorry about that. Try this:
Code: | su - username -c "/usr/local/bin/mythbackend 2&> /dev/null " |
I think that's right. I suck at piping stderr. _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
|
maqe Tux's lil' helper
Joined: 11 Feb 2006 Posts: 75
|
Posted: Tue Aug 01, 2006 6:56 am Post subject: Re: MythTV: frontend and backend init scripts |
|
|
beandog wrote: | maqe wrote: | This seems to work but i get alog of ugly output when backend starts even if i use & at the end? |
Sorry about that. Try this:
Code: | su - username -c "/usr/local/bin/mythbackend 2&> /dev/null " |
I think that's right. I suck at piping stderr. |
That dosent work either... In local.start there is an exampel how to hide output but with 1>&2 but it dosent work? |
|
Back to top |
|
|
beandog Bodhisattva
Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Tue Aug 01, 2006 7:55 pm Post subject: |
|
|
Actually I think its "mythbackend &> /dev/null"
The one you listed would just dump everything to stderr. _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
|
maqe Tux's lil' helper
Joined: 11 Feb 2006 Posts: 75
|
Posted: Wed Aug 02, 2006 2:19 pm Post subject: |
|
|
beandog wrote: | Actually I think its "mythbackend &> /dev/null"
The one you listed would just dump everything to stderr. |
hehe that did´t do it either, it seems like its hard to run something in local.start without getting alot of extra output ... |
|
Back to top |
|
|
NiklasH Apprentice
Joined: 30 Aug 2002 Posts: 211 Location: On top of something
|
Posted: Thu Aug 03, 2006 10:43 pm Post subject: |
|
|
A better way of doing it, IMHO:
Put mythfrontend in your .xinitrc, then change the line
in the "Terminals" section in /etc/inittab that starts with c6 to this:
Code: | c6:2345:respawn:/usr/bin/openvt -fwc 2 -- /bin/su - mythtv -c /usr/bin/startx > /dev/null
|
(This is assuming that mythfrontend runs as user mythtv, otherwise you change the 'su - mythtv' to the user you want)
This has the advantage of restarting X if mythfrontend crashes (which it seems to do now and then)
Works great for me. _________________ Banana Republic |
|
Back to top |
|
|
JuMPeRfLy n00b
Joined: 23 Mar 2004 Posts: 30 Location: Bangor, Wales
|
Posted: Fri Aug 04, 2006 1:12 pm Post subject: |
|
|
You need to give mythbackend a log file
"mythbackend --logfile /var/log/mythtv/mythbackend.log &"
or "mythbackend -d --logfile /var/log/mythtv/mythbackend.log" to start in daemon mode
should stop it printing to stderr
I had problems with the init script too, the backend wouldn't actually start. Removing "--chuid mythtv" from the start section fixed the problem.
Code: |
start-stop-daemon --start --quiet \
--exec /usr/bin/mythbackend \
--make-pidfile --pidfile /var/run/mythbackend.pid \
-- -d --verbose ${MYTH_VERBOSE} \
--logfile /var/log/mythtv/mythbackend.log
|
|
|
Back to top |
|
|
anxt Apprentice
Joined: 25 Feb 2003 Posts: 254 Location: Frozen Tundra, Canada
|
Posted: Tue Aug 22, 2006 7:38 am Post subject: |
|
|
This also fixed the problem for me as well. Thanks. |
|
Back to top |
|
|
MonkeyTheCode n00b
Joined: 20 Apr 2007 Posts: 1
|
Posted: Fri Apr 20, 2007 12:36 am Post subject: bug report filed |
|
|
for those that care, 175291 has been filed for this issue. FWIW, I've seen this with a 0.18.1 and a 0.20 based installation, on separate systems. |
|
Back to top |
|
|
Cardoe Retired Dev
Joined: 28 Jun 2002 Posts: 32
|
Posted: Fri Apr 20, 2007 2:30 pm Post subject: |
|
|
beandog: The real suggestion is if you're clueless. Don't go compiling things on your own and don't go tweaking and configuring things on your own. Instead use the way that's been setup long long ago and tested by many people.
emerge mythtv. enable USE=autostart. Follow the instructions. _________________ Cardoe
Retired Gentoo Developer
Gentopia, MythTV, D-Bus |
|
Back to top |
|
|
beandog Bodhisattva
Joined: 04 May 2003 Posts: 2072 Location: /usa/utah
|
Posted: Fri Apr 20, 2007 2:57 pm Post subject: |
|
|
Cardoe wrote: | beandog: The real suggestion is if you're clueless. Don't go compiling things on your own and don't go tweaking and configuring things on your own. Instead use the way that's been setup long long ago and tested by many people. |
Hmm, true enough. Anyone whose read my blog knows the horrors of running straight from the SVN repo. _________________ If it ain't broke, tweak it. dvds | blurays | blog | wiki |
|
Back to top |
|
|
DocterD Tux's lil' helper
Joined: 15 May 2004 Posts: 129
|
Posted: Tue May 08, 2007 5:33 pm Post subject: Re: bug report filed |
|
|
MonkeyTheCode wrote: | for those that care, 175291 has been filed for this issue. FWIW, I've seen this with a 0.18.1 and a 0.20 based installation, on separate systems. |
just fixed it. |
|
Back to top |
|
|
|