Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

[SOLVED]Gedit problem as superuser in terminal.

Ask for help with issues regarding the Installations of the Debian O/S.
Post Reply
Message
Author
robgeek
Posts: 132
Joined: 2012-06-25 03:34

[SOLVED]Gedit problem as superuser in terminal.

#1 Post by robgeek »

Hello. I'm using Debian Wheezy 7.1 with Gnome3 and when i try to open Gedit as super user in a terminal, i get the following message:
EggSMClient-WARNING **: Failed to connect to the session manager: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed


** (gedit:9722): WARNING **: Could not connect to session bus
How can i solve this problem?
Last edited by robgeek on 2013-10-19 21:06, edited 1 time in total.

peter_irich
Posts: 1403
Joined: 2009-09-10 20:15
Location: Saint-Petersburg, Russian Federation
Been thanked: 11 times

Re: Gedit problem as superuser in terminal.

#2 Post by peter_irich »

It is normal, it is better not run gui-application as root.
Use any console editor in terminal. vim, nano, mcedit, joe, le, fte.

Peter.

robgeek
Posts: 132
Joined: 2012-06-25 03:34

Re: Gedit problem as superuser in terminal.

#3 Post by robgeek »

Why is normal? Why in Debian Squeeze 6 with Gnome 2 i can do this?

cynwulf

Re: Gedit problem as superuser in terminal.

#4 Post by cynwulf »

You are not supposed to run gui apps such as gnome terminal, nautilus, gedit, etc as root.

Whether it worked or not in gnome 2 in squeeze is irrelevant.

If you want to get around this you will have to read up on launching these apps through pkexec or you can try gksu and see if that still works.

User avatar
aicardi
Posts: 388
Joined: 2009-11-18 01:30
Location: Chicago

Re: Gedit problem as superuser in terminal.

#5 Post by aicardi »

robgeek wrote:Hello. I'm using Debian Wheezy 7.1 with Gnome3 and when i try to open Gedit as super user in a terminal, i get the following message:
EggSMClient-WARNING **: Failed to connect to the session manager: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed


** (gedit:9722): WARNING **: Could not connect to session bus
How can i solve this problem?
Use gksu in terminal as normal user, not as super user.

Code: Select all

$ gksu gedit
Jessie/Xfce

thericeking
Posts: 9
Joined: 2013-07-20 22:35

Re: Gedit problem as superuser in terminal.

#6 Post by thericeking »

I had the same issue. Is a real pain trying to edit source list without this. For me is the only way I know how to do it.

pcalvert
Posts: 1939
Joined: 2006-04-21 11:19
Location: Sol Sector
Has thanked: 1 time
Been thanked: 2 times

Re: Gedit problem as superuser in terminal.

#7 Post by pcalvert »

Never mind....
Last edited by pcalvert on 2013-07-21 11:38, edited 1 time in total.
Freespoke is a new search engine that respects user privacy and does not engage in censorship.

kedaha
Posts: 3521
Joined: 2008-05-24 12:26
Has thanked: 33 times
Been thanked: 77 times

Re: Gedit problem as superuser in terminal.

#8 Post by kedaha »

Code: Select all

$ gksu gedit
results in:

Code: Select all

(gedit:6126): EggSMClient-WARNING **: Failed to connect to the session manager: None of the authentication protocols specified are supported
To avoid such warnings, use the su command appending a hyphen - thus:

Code: Select all

$ su -
Password: 
Now you can use gedit or emacs cleanly, for example:

Code: Select all

root@localhost:~# gedit /etc/apt/sources.list
Alternatively:

Code: Select all

$ su -l
or

Code: Select all

$ su --login
Without the "problem."
DebianStable

Code: Select all

$ vrms

No non-free or contrib packages installed on debian!  rms would be proud.

peter_irich
Posts: 1403
Joined: 2009-09-10 20:15
Location: Saint-Petersburg, Russian Federation
Been thanked: 11 times

Re: Gedit problem as superuser in terminal.

#9 Post by peter_irich »

There are else two variants.
1) As user enter command

Code: Select all

xhost local:root
After that root will be able ran gedit from terminal.
2) To copy user's .Authority to /root.

Peter.

pcalvert
Posts: 1939
Joined: 2006-04-21 11:19
Location: Sol Sector
Has thanked: 1 time
Been thanked: 2 times

Re: Gedit problem as superuser in terminal.

#10 Post by pcalvert »

There is also sux. Although I don't know why, the folks at aptosid seem to have a preference for that one.

Phil
Freespoke is a new search engine that respects user privacy and does not engage in censorship.

Post Reply