LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 07-23-2005, 11:40 PM   #1
alaskazimm
Member
 
Registered: Mar 2004
Location: Watching it snow in bush Alaska
Distribution: *ubuntu, Smoothwall, WinXP Pro
Posts: 126

Rep: Reputation: 15
Can't start emacs from shell


and I can't edit anything as root. When I start the shell and log in as root, I try to open a config file in emacs. But then I get this error message -

"Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

emacs: Cannot connect to X server :0.0.
Check the DISPLAY environment variable or use `-d'.
Also use the `xhost' program to verify that it is set to permit
connections from your machine."

When I try to run xhost I get the same error message. I'm sure there is a config file that I need to set up but I don't know which one. I had this same problem in Slackware 10.1 which is why I'm trying Kubuntu 5.04 at the moment.

Thanks for the help ahead of time,
 
Old 07-24-2005, 12:25 AM   #2
alaskazimm
Member
 
Registered: Mar 2004
Location: Watching it snow in bush Alaska
Distribution: *ubuntu, Smoothwall, WinXP Pro
Posts: 126

Original Poster
Rep: Reputation: 15
D'oh! Wouldn't you know it, as soon as I post, the next webpage I read contains the answer.

Just sudo emacs <filename>

Simple when you know the answer.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Shell mode & ssh in emacs phuna Linux - Software 1 08-03-2005 04:37 PM
emacs shell-mode doesn't interpret prompt variable CoonerTheRed Linux - Software 1 05-09-2005 04:23 AM
Shell in emacs tuananhbirm Mandriva 2 11-22-2004 11:19 AM
emacs problem in shell mode bujecas Slackware 1 10-25-2004 04:37 AM
What packages do I need to install to start programming in emacs? O_o Linux - Newbie 7 11-10-2003 03:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 02:03 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration