PDA

View Full Version : gedit problems with root



yellow
28th October 2008, 11:13 AM
hey

i very recently shifted to linux : fedora . I am using 2.6.25-14.fc9.i686.

The tweaking on linux requires to edit some system config file and that requires switching to root (while i am actually logged in as normal user).
I do it by typing 'su -' command in terminal. But then i cannot open gedit to edit the files. it says

No protocol specified
cannot open display:
Run 'gedit --help' to see a full list of available command line options.


If i login as root and then try to open gedit through terminal - it works..

whats wrong...

thanks for help

Dangermouse
28th October 2008, 11:57 AM
Hi and welcome to the forum :)
I suspect you just did a typo thats all, might be worth rechecking a common mistake,
there is also another way you can browse and open the files in root for editing by

su
nautilus

yellow
28th October 2008, 12:29 PM
hey thanks but it is no typo
and same happens with nautilus.
if i donot switch to root and in terminal i try to use gedit or nautilus then its fine... it works

bee
28th October 2008, 12:38 PM
i don't see any error in what you are doing there.
So, why don't you post a screenshot!? :rolleyes:

When you've solved your issue. I would also suggest you to install beesu (http://forums.fedoraforum.org/showthread.php?t=201579) in order to don't have to open your terminal each time (http://forums.fedoraforum.org/showpost.php?p=1100838&postcount=6) you need to browser as root. :D :cool:

bye!! :)

yellow
28th October 2008, 01:56 PM
i am sorry but its not uploading my files

bee
28th October 2008, 02:14 PM
i am sorry but its not uploading my filesah!! it's not a problem, there are online free services, like http://rapidshare.com/ to upload files!! it's good because u don't need to take one account, but you can just upload! :cool: :cool: :cool: :D

bye!:):)

Dangermouse
28th October 2008, 02:21 PM
There does seem to be a problem with uploading files (investigating)at the moment, but Bee has given a excellent solution, or as its in a terminal you could just copy paste the output.


Howdy bee got any spare honey:)

yellow
28th October 2008, 02:25 PM
a million thanks beee

herez the link
http://rapidshare.com/files/158340709/Screenshot.png.html
i used 'uname' as well so that you can see my kernel ver and stuff

i am stuck coz i can just move on without this stuff

bee
28th October 2008, 02:37 PM
i'm here :p :D

Well, looks like your console (gnome terminal) is working good. :rolleyes:
I was thinking there were something of wrong with your "display"...
If you type "su" without "-" will it work?
You can type as user "env" and as root "env" and look there what is "DISPLAY=" set to... maybe the problem is there (MAYBE!) lol :D
if you don't see it, you could try to type: export DISPLAY=:0.0 when you are root... :rolleyes::rolleyes::rolleyes:

bye! :)

Dangermouse
28th October 2008, 02:43 PM
Hi you also typed just gedit
it should be
gedit /path/to/thefile

bee
28th October 2008, 02:47 PM
Hi you also typed just gedit
it should be
gedit /path/to/thefile
well, also typing just "gedit" have to work (if all is okay it must work)...it'll just starting the program with a new blank unsaved file.

bye!! :)

yellow
28th October 2008, 03:09 PM
thankssss bee

ok let me write the complete thing...
logged in as normal user i typed 'env' and noted that DISPLAY=:0.0.
I switched to (typing su) root, typed env and still it gives the environment variables for normal user which is actually logged in.
So i logged out ( and for me it meant rebooting : see my logout problem) I logged in as root and typed env in terminal and noticed that DISPLAY=:0.0. Even then i typed
export DISPLAY=:0.0
logged out and logged in as normal user. and switched to root in terminal and opened gedit. now it works, i even opens files, i checked it but on terminal it gives this error...


(gedit:3462): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.


though the problem is solved but what is this error....

i tried with 'su' as well (instead of 'su -') but it didnt work..

For DangerMouse: it was not opening files as well thats how i found it coz i was trying to edit some config file...

thanks again but do look into this message

bee
28th October 2008, 04:01 PM
(gedit:3462): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.it isn't a critical error... software are usual to print in your terminal warning messages...

so, if you type and read:

[bee@localhost ~]$ su
Password:
[root@localhost bee]# gedit
(gedit:30355): GnomeUI-WARNING **: While connecting to session manager:
Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed.
[root@localhost bee]#
the solution is:

[bee@localhost ~]$ su -
Password:
[root@localhost ~]# gedit
[root@localhost ~]#

as you can see....(if all is okay) you need to add the "-" in su to avoid that warning...

I don't have understand, except that GnomeUI-WARNING, is your problem solved or there are something that doesn't work!?:confused:

bye! :)

fedoraman08
28th October 2008, 04:04 PM
ah!! it's not a problem, there are online free services, like http://rapidshare.com/ to upload files!! it's good because u don't need to take one account, but you can just upload! :cool: :cool: :cool: :D

bye!:):)

mediafire.com, turboupload.com is good for small file too:eek:

yellow
28th October 2008, 05:14 PM
yup thanks its solves my problem but i dont understand a bit about this

MOREOVER it means i HAVE to first login as root and export my DISPLAY variable and then log in as normal user and proceed.
BECAUSE i rebooted my computer and logged in as normal user and switched to root and tried to export DISPLAY but that didnt work..

thanks a million

bee
28th October 2008, 06:29 PM
yup thanks its solves my problem but i dont understand a bit about this

MOREOVER it means i HAVE to first login as root and export my DISPLAY variable and then log in as normal user and proceed.
BECAUSE i rebooted my computer and logged in as normal user and switched to root and tried to export DISPLAY but that didnt work..

thanks a million

i'm also not understanding what you are saying here, i'm sorry but i don't get it :confused::confused::confused:

bye! :)