View previous topic :: View next topic |
Author |
Message |
ruina n00b
Joined: 16 Aug 2003 Posts: 21
|
Posted: Fri Aug 29, 2003 12:46 am Post subject: cannot open display |
|
|
Pessoal,
Eu preciso iniciar uma aplicação como root mas no ambiente X de usuário... mas eu não estou conseguindo pois dá a seguinte mensagem quando executo:
Code: |
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
Gtk-WARNING **: cannot open display: :0.0
|
Não tenho idéia do que devo fazer.... para que não haja essa restrição de uso?
Obrigado,
-ruina |
|
Back to top |
|
|
AngusYoung Retired Dev
Joined: 20 Dec 2002 Posts: 473 Location: Czech Republic
|
Posted: Fri Aug 29, 2003 1:39 am Post subject: |
|
|
Você tá usando ssh ? _________________ My blog
Twitter |
|
Back to top |
|
|
cleber n00b
Joined: 05 Aug 2003 Posts: 74 Location: São Paulo - Brazil
|
Posted: Fri Aug 29, 2003 2:45 am Post subject: |
|
|
Por um momento pensei que era um post em inglês... hehehe
Eu tb tive isto qdo tentei dar um xconfig (não sei porque, já que uso o menuconfig...) do kernel.
Para isto, volte a ser o usuário que logou no X e rode o comando com sudo. Para isto, vc tem que estar no /etc/sudoers .
Para dar make xconfig, vc precisa fazer o seguinte:
e entrar a sua senha.
Good luck, man! _________________ Saru mo ki kara ochiru - Japanese proverb.
Cleber Mori Home Page: http://www.2ks.com.br |
|
Back to top |
|
|
pilla Bodhisattva
Joined: 07 Aug 2002 Posts: 7729 Location: Underworld
|
Posted: Fri Aug 29, 2003 12:23 pm Post subject: |
|
|
Para o bash,
usuario:
root:
Code: |
%export DISPLAY=localhost:0
|
_________________ "I'm just very selective about the reality I choose to accept." -- Calvin |
|
Back to top |
|
|
humpback Retired Dev
Joined: 19 Oct 2002 Posts: 394 Location: Coimbra - Portugal
|
Posted: Sun Aug 31, 2003 12:37 am Post subject: |
|
|
Pilla: Esse método é um pouco mau pois abre uma série de buracos.
Code: |
humpback@sam humpback $ su -
Password:
sam root # xauth merge /home/humpback/.Xauthority
sam root # xeyes
|
Neste momento já deve aparecer uns olhinhos
Caso nada apareça (e este método é ainda mais limpo):
Code: |
humpback@sam humpback $ su -
Password:
sam root # export XAUTHORITY=/home/humpback/.Xauthority
sam root # xeyes
|
Em alternativa (mas que come muito mais CPU) é alterar a configuração do sshd para aceitar ligações como root e:
Code: |
humpback@sam humpback $ ssh -X root@localhost
root@localhost's password:
Last login: Sun Aug 31 01:33:50 2003 from localhost
/usr/X11R6/bin/xauth: creating new authority file /root/.Xauthority
sam root # xeyes
|
A melhor forma é mesmo a segunda. _________________ Gustavo Felisberto
Humpback @ #gentoo-pt
------------
It's most certainly GNU/Linux, not Linux. Read more at
http://www.gnu.org/gnu/why-gnu-linux.html .
------------- |
|
Back to top |
|
|
ruina n00b
Joined: 16 Aug 2003 Posts: 21
|
Posted: Wed Sep 03, 2003 7:51 pm Post subject: |
|
|
Infelizmente... nenhuma dessas opções funcionaram.
Code: |
priss root # export XAUTHORITY=/home/humpback/.Xauthority
priss root # mtr www.uol.com.br
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
Gtk-WARNING **: cannot open display: :0.0
|
|
|
Back to top |
|
|
AngusYoung Retired Dev
Joined: 20 Dec 2002 Posts: 473 Location: Czech Republic
|
Posted: Wed Sep 03, 2003 8:55 pm Post subject: |
|
|
ruina wrote: | Infelizmente... nenhuma dessas opções funcionaram.
Code: |
priss root # export XAUTHORITY=/home/humpback/.Xauthority
priss root # mtr www.uol.com.br
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
Gtk-WARNING **: cannot open display: :0.0
|
| substitui export XAUTHORITY=/home/humpback/.Xauthority por export XAUTHORITY=/home/meuhome/.Xauthority
(se o seu home for "humpback" desconsidere ) _________________ My blog
Twitter |
|
Back to top |
|
|
humpback Retired Dev
Joined: 19 Oct 2002 Posts: 394 Location: Coimbra - Portugal
|
Posted: Thu Sep 04, 2003 2:03 am Post subject: |
|
|
ruina wrote: | Infelizmente... nenhuma dessas opções funcionaram.
Code: |
priss root # export XAUTHORITY=/home/humpback/.Xauthority
priss root # mtr www.uol.com.br
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
Gtk-WARNING **: cannot open display: :0.0
|
|
Hrrrrr...... humpback é o meu username, no seu caso deve colocar o login do seu user. _________________ Gustavo Felisberto
Humpback @ #gentoo-pt
------------
It's most certainly GNU/Linux, not Linux. Read more at
http://www.gnu.org/gnu/why-gnu-linux.html .
------------- |
|
Back to top |
|
|
pilla Bodhisattva
Joined: 07 Aug 2002 Posts: 7729 Location: Underworld
|
Posted: Thu Sep 04, 2003 11:43 am Post subject: |
|
|
humpback wrote: |
Hrrrrr...... |
Amigo..... amigo..... calma..... _________________ "I'm just very selective about the reality I choose to accept." -- Calvin |
|
Back to top |
|
|
ruina n00b
Joined: 16 Aug 2003 Posts: 21
|
Posted: Sat Sep 06, 2003 8:25 pm Post subject: |
|
|
hehehehe!! essa foi muito boa!!
Minha total falta de atenção.... Me desculpem hehehehe
Quando olhei já havia postado.... "humpback" parece ser um comando muito comum. hehehe que mané eu fui! |
|
Back to top |
|
|
|