-
root not running X programs
I'm running a normal user
and I've don su
and entered root password
and now In konsole I do sudo firefox and expect things to work.
but they don't.
What am I to do ?
stefan:/home/stef# sudo firefox
(firefox-bin:8234): Gtk-WARNING **: cannot open display:
i'm stupid
-
Why do you want to run firefox as root? Your regular user account should be able to run it.
Also, the purpose of sudo is to enable regular users to enter privileged commands. As root, you shouldn't have to use sudo.
So if you want to run firefox, you could
Code:
regular_user$ firefox &
If you really want to run firefox as root, you can
Code:
regular_user$ su -
Password: <password>
root# firefox &
Unless, you know what you're doing, I don't recommend running a browser as root.
-
Originally Posted by nabetse
Unless, you know what you're doing, I don't recommend running a browser as root.
The catch 22 is that if you knew what you were doing, you probably wouldn't want to do that. I've sometimes run Konqueror as root-- as a file manager, to check and adjust permissions graphically, but not as a web browser. I really shouldn't criticize, as I have no idea what you have in mind here.
What's with the ampersand "firefox &"?
I've never used that to launch desktop applications from the command line. I just type the name of the application. What does it do?
Last edited by blackbelt_jones; 10-19-2007 at 12:55 AM.
-
The ampersand "&" means to run the process in the background. This is so that it does not tie up your terminal and you can use that terminal to run other commands.
-
Try this
Code:
ssh -X -Y root@localhost
. I'm fairly sure that graphical apps will run now.
It's a known "problem" with OS/2. It runs continuously until the underlying hardware crumbles under you hands....
the irony of quality
-
As your regular user, type "xhost +local:", that will allow any local users to connect to and run GUI apps on your X server.
But why do you want to run Firefox as root? There shouldn't be a need for it and it isn't recommended.
-
Originally Posted by spx2
I'm running a normal user
and I've don su
and entered root password
and now In konsole I do sudo firefox and expect things to work.
but they don't.
What am I to do ?
stefan:/home/stef# sudo firefox
(firefox-bin:8234): Gtk-WARNING **: cannot open display:
What this looks like is that you're trying to use sudo from su... that doesn't make any sense.
Anyway, this is all sounding a lot more complicated than it has to be. In simpler terms:
1. (In my experience) you can't open x-based applications with sudo.
2. You can usually open them with su. This is usually done with editors (I do it with gedit and xemacs) and file managers (Konqueror or Nautilus, etc). There are security risks, so as a basic rule of thumb, the farther away that you do this from the internet, the better. I think that I speak for all of us when I say that we have no idea what advantage can be gained from opening firefox as root.
Last edited by blackbelt_jones; 10-19-2007 at 11:37 AM.
-
this sux
no, really...check out sux
the problem is, only your user has access to your X session.
sux solves that
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|