Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Openbox Problem for Root. Please read.
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Sikander
n00b
n00b


Joined: 08 Oct 2003
Posts: 29

PostPosted: Sat Jan 10, 2004 5:32 pm    Post subject: Openbox Problem for Root. Please read. Reply with quote

Hi,

I can't open OpenBox when I'm root. It works for me as a regular user though. In /home/adrian/ I have in my .xinitrc ...

Code:
#! /usr/bin/env bash

# make sure GTK apps use XFT if available
set GDK_USE_XFT=1
export GDK_USE_XFT

# set a wallpaper
# Esetroot ~/image/test.jpg

# load a window manager

exec /usr/bin/openbox


And when I log in as 'adrian' and type StartX the screen goes black and then a pointer appears and I'm in Openbox.

But if I type, as root, either "exec openbox" or "openbox" I get...

Quote:
Openbox-CRITICAL:**:Failed to open the display


and sometimes I get booted as root. I have to keep adding my PATH as root each time so I type:

Quote:
$ PATH="/usr/X11R6/bin:$PATH"
$ PATH="/usr/bin:$PATH"


when I start.

When I type 'startx' as root it takes me to that WindowsManager that is installed by default when Gentoo is compiled -- the one with the green bars and that weird looking clock in the upper-righthand corner.

Please help. I have tried Google and this forum's search. As far as the root's .xinitrc file I just copied what I have above. Sine it wasn't working I thought I put it in the wrong directory so there is a copy of the .xinitrc in...

Quote:
/
/home


Any help will be appreciated.

Thanks,

Adrian
Back to top
View user's profile Send private message
Andersson
Guru
Guru


Joined: 12 Jul 2003
Posts: 525
Location: Göteborg, Sweden

PostPosted: Sat Jan 10, 2004 5:38 pm    Post subject: Re: Openbox Problem for Root. Please read. Reply with quote

Sikander wrote:
I can't open OpenBox when I'm root.

It's just as well. X starts a lot of different programs, which means a lot of risks. These programs shouldn't run with root permissions. Just start openbox as a regular user and use a terminal emulator and the command su to do your root tasks.
Sikander wrote:
I have tried Google and this forum's search. As far as the root's .xinitrc file I just copied what I have above. Sine it wasn't working I thought I put it in the wrong directory so there is a copy of the .xinitrc in...

Quote:
/
/home

Root's home is /root/ ;)
Back to top
View user's profile Send private message
Sikander
n00b
n00b


Joined: 08 Oct 2003
Posts: 29

PostPosted: Sat Jan 10, 2004 5:47 pm    Post subject: Reply with quote

Hi Andersson,

:oops: Thanks a lot! I copied the .xinitrc to that folder and it worked.

I'm new to Linux, well, new enough, that I don't know how to make things like the "PATH'/" stuff permanent. Earlier I was on as 'adrian' and opened XMMS. I tried to open the MP3 I listened to last night -- nothing. So I started thinking maybe my module i gone and such and then realized that the 'user' doesn't have permission to access the hard drive with my MP3s. So I close XMMS, SU'es and then opened it again to hear my music. My searches for "add defualt PATH" in google haven't produced any fruitful results. I did find an argument on wether PATH="/usr/bin:$PATH was safer than $PATH="/usr/bin" or something along those lines.

Anyway, thanks again for the help. I appreciate it. :D

Adrian
Back to top
View user's profile Send private message
Andersson
Guru
Guru


Joined: 12 Jul 2003
Posts: 525
Location: Göteborg, Sweden

PostPosted: Sat Jan 10, 2004 6:01 pm    Post subject: Reply with quote

About the path... there are some paths in /etc/env.d/00basic. Not all paths, I don't know in what file the others are but I guess you could add your paths to that file.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum