Find the answer to your Linux question:
Results 1 to 3 of 3
Hello everyone. It feels so good to be finally sitting behind a Debian OS machine. Ahhh.... I'm getting an error message when I try to do anything as root. Code: ...
  1. #1
    Just Joined!
    Join Date
    Feb 2007
    Location
    L.A. (lower alabama, that is)
    Posts
    29

    Error message when working as 'root'

    Hello everyone.

    It feels so good to be finally sitting behind a Debian OS machine. Ahhh....

    I'm getting an error message when I try to do anything as root.
    Code:
    Xlib: connection to ":0.0" refused by server
    Xlib: No protocol specified
    One spot I found advised to run
    Code:
    xhost +
    to enable it, but I can't help but wonder if that is just a temporary bandaid. Even the person who gave this fix said that it wasn't advisable.

    If I run
    Code:
    xhost +root
    I get
    Code:
    xhost:  bad hostname "root"
    What's causing this error?

    Does anyone know of a permanent fix?

    Any and all help is much appreciated.

    Thanks,

    Billy

  2. #2
    Just Joined!
    Join Date
    Jun 2005
    Posts
    8
    i think
    Code:
    xhost +hostname
    or
    Code:
    xhost +hostname:username
    in your case localhost:root
    check this post

  3. #3
    Just Joined!
    Join Date
    Feb 2007
    Location
    L.A. (lower alabama, that is)
    Posts
    29
    Quote Originally Posted by elsheikhmh
    i think
    Code:
    xhost +hostname
    or
    Code:
    xhost +hostname:username
    in your case localhost:root
    check this post
    Thanks for the reply elsheikhmh. The "xhost +hostname" command seems to be a temporary fix. It goes away when you reboot.

    A permanent fix is adding the line
    Code:
    export XAUTHORITY=/home/your_user_name/.Xauthority
    to /etc/profile seems to keep the fix even after reboot. It worked for me, at least. (Be sure to replace the your_user_name with your user name. Like, mine is "billy".)

    Something else that I didn't consider is to simply open the "Root Terminal" instead of just "Terminal". But it's kind of handy (to me, a noob) to be able to switch back and forth with a simple command in the same terminal window.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •