[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Root Session - from Shell command
From: |
Tim X |
Subject: |
Re: Root Session - from Shell command |
Date: |
Fri, 06 Jul 2007 13:42:50 +1000 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (gnu/linux) |
david@adboyd.com (J. David Boyd) writes:
> Peter Dyballa <Peter_Dyballa@Web.DE> writes:
>
>> Am 05.07.2007 um 16:08 schrieb flebber:
>>
>>> So maybe I need to edit my bash profile to allow emacs access to the
>>> shell ???
>>
>> No, you can't login in *shell* buffer, and neither in *terminal*
>> buffer. The proper way from inside GNU Emacs would be to use tramp:
>>
>> C-x C-f /sudo::/boot/grub/grub.conf RET
>>
>> --
>> Greetings
>>
>> Pete
>>
>
>
> But you should be able to 'su'. I do that all the time in Mandriva.
>
> Dave
>
>
>
Depending on your X setup, you can have issues if you open a term, su to root
and then try to run emacs as emacs will try to run the X version. This can fail
if you don't have the appropriate xauth cookies (which control access to the X
display).
The simplest way to get around this is to run emacs with the -nw switch so that
it will run within the term rather than trying to run as an X client.
Of course, far simpler is just to use tramp.
Some setups hide this stuff and manage the .Xauthority cookies in a way that
makes all this 'invisible' to the end user. Some people even suggest using the
xhost command to grant access to your X display, but this is insecure,
especially if running on a multi-user system.
Tim
--
tcross (at) rapttech dot com dot au