[mythtv-users] mythfrontend floods .xsessions-error

Michael T. Dean mtdean at thirdcontact.com
Wed May 9 21:05:40 UTC 2007


On 05/09/2007 04:52 PM, Juergen Sachs wrote:
> I am runniung the mythfrontend as specified user "mythtv".
> After some time, the ".xsession-errors" file in the home of the user grows 
> until it fills up the whole home partition.
> The only thing to stop it is to quit mythfrontend, delete the file and restart 
> mythfrontend. Then it work for some days without filling up the file with 
> errors.
...
> cat ~/.xinitrc
> # startup mythtv frontend
> #
> # init TV Output of grfik card
> nvtv -t -r 800,600 -s Large -S PAL -C SVIDEO
> #
> # start mythfrontend
> exec mythfrontend
> #
> # end quit if exited
> exit 0

Your .xinitrc is broken.  If you do an "exec", it replaces the running 
shell (i.e. that running the .xinitrc with the specified command.  That 
means that your exit 0 will never execute (and that all of 
mythfrontend's output goes to the .xinitrc's output--which I'm guessing 
is your .xsession-errors).  And, you should /really/ run a window manager.

Below is a more appropriate way to handle starting a WM and mythfrontend 
in a .xinitrc.  With this approach, if a file ~/.mythtv/autostart 
exists, X starts mythfrontend and waits for it to exit (so, X exists 
when mythfrontend does).  Otherwise, it waits for the window manager to 
exit.  If you configure your system with autologin/auto-X-on-/dev/tty#, 
it will automatically restart after you exit or after a crash.

Note, though, that you should run the WM regardless (and should start it 
before starting any X apps).  Running without a WM is not a supported 
configuration.  I use fluxbox, but RatPoison is an even smaller (more 
lightweight) WM that's very appropriate (and simply requires your 
changing "fluxbox" to "ratpoison" in the sample excerpt below).  Also, 
uncomment the irexec/irxevent lines as appropriate.

Mike

# Start the window manager
fluxbox & wmpid=$!

# Ensure irexec and irxevent are not running
#killall irexec
#killall irxevent

# Start irexec
#irexec -d
# Start irxevent
#irxevent &

if [ -f $HOME/.mythtv/autostart ]; then
    # Start mythfrontend
    mythfrontend -l /home/mythtv/log/mythfrontend.log
else
    # Wait for the window manager to exit
    wait $wmpid
fi



More information about the mythtv-users mailing list