Forcing XORG to use /root?

David Greaves david at dgreaves.com
Sun Nov 23 10:10:37 PST 2008


Schumi Imor wrote:
> Hello,
>   I'm not sure how to asking this question, but here are the details.
> I have an embedded device running Debian with xorg, I have a init.d
> script to run "startx &" and another xinitrc script to run "firefox",
> it all works great, but it seems XORG is not running in any user mode,
> not even root, since I haven't logged in and all this is happening
> before login. But for some reason, firefox is going and getting the
> .mozilla profile from / instead of /root.
> On the other hand, if remove the startx from init.d and login as root,
> then run "startx" all works fine and firefox gets its profile from
> /root/.mozilla.
> 
> So, forgive me if this ends up to be a mozilla question, but I'm
> wondering if there is a way to tell xorg to run under a certain user
> before login... to solve this issue?

You are right... this is nothing to do with xorg :)

You need to setup the environment as if you'd logged in.

Nb Even for an embedded device you should be starting applications as a non-root
user; especially if you run things like firefox.

Over at maemo they simply have a user called 'user' and use debian script
facilities to run most daemons as that user.

Feel free to pop into #maemo on freenode and ask for some pointers to the code...


David



-- 
"Don't worry, you'll be fine; I saw it work in a cartoon once..."



More information about the xorg mailing list