How to make mythfrontend start automatically with X

| | Comments (0) | TrackBacks (0)
Now that I've covered starting mythbackend on boot, I'm going to explain how to get mythfrontend running as soon as you start X.

Its pretty simple, as its just a few lines in your .xinitrc

I'm using fluxbox, so thats the example I'll be using.

I'm also assuming that you have your X working properly, and have tested it properly
Hopefully, you're planning on running your mythfrontend as a seperate user (ie: not root).

I'm using 'mythtv'
If you don't have your own mythtv user, create one

adduser mythtv

Then edit the .xinitrc file in home directory of the user you intend on running as.
I'll assume that we're using 'mythtv' as your user from here... if yours is different, make sure to change your paths to reflect this.

Open your .xinitrc in your favourite text editor

/home/mythtv/.xinitrc
Put the following lines in it:

exec xset -dpms s off &
exec /usr/bin/fluxbox & wmpid=$!
exec mythfrontend 2>> /home/mythtv/mythfrontend.errors &
wait $wmpid
What this does, is uses xset to turn off the screen saver (makes sense...)
It then starts up fluxbox, and stores the PID in the variable $wmpid
Then it starts up mythfrontend, and outputs the errors to /home/mythtv/mythfrontend.errors
Then it waits on the PID of fluxbox, so X doesn't exit until fluxbox exits

Now go ahead and start up X

startx
With any luck, it'll go straight into mythfrontend

Categories

,

0 TrackBacks

Listed below are links to blogs that reference this entry: How to make mythfrontend start automatically with X.

TrackBack URL for this entry: http://daffy.za.net/cgi-bin/mt/mt-tb.cgi/60

Leave a comment

Powered by Ajax Comments

About this Entry

This page contains a single entry by Kieran Murphy published on October 10, 2007 4:14 PM.

How to make mythbackend start automatically was the previous entry in this blog.

Blog Action Day is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Syndicate

Powered by Movable Type 4.01