From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Tim X Newsgroups: gmane.emacs.help Subject: Re: Root Session - from Shell command Date: Fri, 06 Jul 2007 13:42:50 +1000 Organization: Posted via Supernews, http://www.supernews.com Message-ID: <87vecynqo5.fsf@lion.rapttech.com.au> References: <1183644493.115835.274090@m37g2000prh.googlegroups.com> <1E9CBEAA-9335-41D3-A998-67F38BB3270F@Web.DE> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1183696946 9764 80.91.229.12 (6 Jul 2007 04:42:26 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 6 Jul 2007 04:42:26 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Jul 06 06:42:25 2007 connect(): Connection refused Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1I6feC-0002JP-HP for geh-help-gnu-emacs@m.gmane.org; Fri, 06 Jul 2007 06:42:24 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I6feC-0004lt-3t for geh-help-gnu-emacs@m.gmane.org; Fri, 06 Jul 2007 00:42:24 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!news3.google.com!sn-xt-sjc-05!sn-xt-sjc-08!sn-post-sjc-02!sn-post-sjc-01!supernews.com!corp.supernews.com!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.50 (gnu/linux) Cancel-Lock: sha1:LsC9lg0Ce2BRFbNdpAMzV1/Q/Cs= Original-X-Complaints-To: abuse@supernews.com Original-Lines: 46 Original-Xref: shelby.stanford.edu gnu.emacs.help:149908 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:45497 Archived-At: david@adboyd.com (J. David Boyd) writes: > Peter Dyballa 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