Re: Upon bootup, how do I do an "xhost + machine" without using a terminal window?



Gilbert Sebenste wrote:
Hello all,

One more question for the gurus this morning, which I couldn't get an
answer to earlier.

I want to start up some programs that require the use of X window :2.
Unfortunately, to do that, I have to physically be at the machine and on
a terminal window, type:

xhost + something.something.com

Which would then allow all X processes to run from that machine.
But I want to do it automatically upon bootup. I tried to do this in
/etc/rc.d/rc.local, but it gives me:

xhost: unable to open display ""

OK. So how do I solve this?

Thank you very much for any help,

Gilbert

xhost only runs under X, and has to be run on the X server you want
to change access for. That is why you get the error.

There are a couple of ways around this. Probably the least secure
way would be to add it to /etc/X11/xinitd/xinitrc-common. The
problem here is that it will allow any program on
something.something.com to connect to any X server running on that
machine.

A better way would be to use ssh to start the program on the other
machine with X tunneling. That way, you are sure only the programs
you want to run can access the X server.

There are also some things you can do with xauth, but I don't
understand it well enough to explain it to someone else.

Mikkel
--

Do not meddle in the affairs of dragons,
for thou art crunchy and taste good with Ketchup!

--
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list



Relevant Pages

  • My solution for preventing xhost +
    ... from running xhost + and thereby exposing an/the X server. ... If the script detects this condition, ... echo "Re-enabling access control per Security Policy." ...
    (Focus-SUN)
  • Re: Python relocation error
    ... Mark L. Cooper wrote: ... > the server locally is where I have problems. ... > I've lost the Red Hat Network Alert Icon. ... Again, from a terminal window as root, I ...
    (linux.redhat)
  • Python relocation error
    ... I've set up a Red Hat 9 server to run squid and Shorewall for a small office ... applet from a terminal window as root I get: ... Again, from a terminal window as root, I ...
    (linux.redhat)
  • Re: Migrating to Windows Server 2003 from Windows Server 2000 and using Remote Desktop Client
    ... On the Terminal Server, open Terminal Services Configuration - rdp- ... Open Client Connection manager. ... autocad 5. ... In the terminal window only the autocad ...
    (microsoft.public.windows.terminal_services)
  • NIC-activation => Xlib: connection to ":0.0" refused by server
    ... I am running RedHat 9.0, default kernel. ... samba (the smb server), and redhat-config-samba. ... # xhost ... Xlib: connection to ":0.0" refused by server ...
    (comp.os.linux.x)