On Fri, Aug 03, 2007 at 02:53:43PM -0500, John Pierce wrote:
The mythbackend init script available from atrpms.net does not setup $HOME when the script is run at boot time. This means that $HOME defaults to / which is why you end up with /.mythtv/ entries in the filesystem.
The updated scripts in MythTV SVN (http://svn.mythtv.org/trac/browser/trunk/mythtv/contrib/init_scripts) have been updated to daemonise mythbackend with a user (defaults to root, see below) so that the MythTV config entries are created/read at init time for a real user.
When starting mythbackend from a terminal, $HOME is already configured and so mythbackend uses $HOME/.mythtv/. This is the reason you can end up with separate MythTV configurations in /, /root/ and /home/mythtv/ if you also run mythfrontend as the user 'mythtv'
The reason the atrpms.net scripts do not use the daemonise 'user' option is due to the lack of the audio and video groups on Fedora. mythbackend requires access to the AV hardware when it starts and by default on Fedora, only the root user has access to this. A user needs to amend their installation's console permissions/udev scripts to allow non-root users the access to the capture hardware they require to allow mythbackend to run as another user.
Thanks, I read the comment inside the mythbackend init script from the atrpms package about the user issue, but I could not locate any in depth explanation about it.
Now I can google for the udev/console perms for myth and maybe find the needed information.
Again thanks for the explanation.
You will also need root priviledges for some real time capabilities, or you will need a way to dispatch this to the mythtv user. If you manage to get it all working the ATrpms init scripts are eagerly waiting for your patch :)
But beware: Over the years many capable people have been trying to cleanly sort this out, and finally resorted back to running the backend under root.