Find the answer to your Linux question:
Results 1 to 6 of 6
This seems to have happened rather randomly and I can't find any solution for it. I'm a bit lazy as of late and as a result, I've been running certain ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Aug 2007
    Posts
    7

    X.org and su


    This seems to have happened rather randomly and I can't find any solution for it.

    I'm a bit lazy as of late and as a result, I've been running certain applications through console. Of course, some of these apps require internet access and as a result I have to start nm-applet in sudo. But one day, I booted up and I started nm-applet and noticed I get:
    Code:
     No protocol specified
    konversation: cannot connect to X server :0.0
    on just about every single application that requires anything to do with X.org. I use HAL to configure X.org for me and everything has been working rather smoothly until this.

    THE KEY: If I start all of my internet-wanting applications before I start nm-applet in sudo, then they start just fine. Anything I start after 'sudo nm-applet --sm-disable' and I'm completely screwed. Any idea on what might be causing this?

    NOTE: It's not nm-applet. If I start anything in sudo, that means I can't start anything else.

    DISTRO: Arch Linux NOTE: Unrelated to distribution.

  2. #2
    Linux Guru reed9's Avatar
    Join Date
    Feb 2009
    Location
    Boston, MA
    Posts
    4,651
    If I'm understanding what you're saying, I believe it's because xserver doesn't allow root to connect.

    Try this
    Code:
    DISPLAY=:0.0 xhost +
    But, you shouldn't use sudo to run gui programs as root, anyway, use kdesu or gksu. I haven't used networkmanager for ages, but I don't recall nm-applet needing to be run as root either.

  3. #3
    Just Joined!
    Join Date
    Aug 2007
    Posts
    7
    Strange... I can't start the process unless I'm in root.... I'll look further into the situation.

    Also, xhost returns:
    Code:
    No protocol specified
    xhost:  unable to open display ":0.0"
    This is a known problem but I've yet to see a solution. Any idea?

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Guru reed9's Avatar
    Join Date
    Feb 2009
    Location
    Boston, MA
    Posts
    4,651
    Regarding networkmanager, are you a member of the network group?

    What are these other programs you're starting with 'sudo'?

  6. #5
    Just Joined!
    Join Date
    Aug 2007
    Posts
    7
    None.

    Seems the above description of the sudo app causing the problems is wrong. It just started after I randomly tried to start k3b to burn ROS. I can't seem to pinpoint the direction the bug is coming from. For eth0, I don't even use nm-applet.

  7. #6
    Just Joined!
    Join Date
    Aug 2007
    Posts
    7
    I fixed it. It was a PolicyKit configuration problem. It seems to be a bit different for everyone and the solution is everywhere. Just google for 'PolicyKit configuration'.

Posting Permissions

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