I have trouble setting xhost + localhost through telnet to a remote RedHat 5 machine.
I can manually log in to the machine and make this setting, but I need to do this through either a shell or a perl script (I need this for some automated testing).
I looked at some previous posts, and I tried some of the suggestions but they all seem to suppose that you will log in to the machine manually. But I only log in to the machine through a perl script using telnet, make some settings, like adding it to a grid, and then the grid will send out some applications to it. These applications won't see the xhost + localhost only if I do it manually on the machine.
If I manually log in to the machine, then all I need to do is to do xhost + localhost , and then export DISPLAY :0 from my script and it all works.
However I just can't set xhost + localhost from the script.
I tried setting it from $HOME/.Xclients and /etc/X0.hosts but it didn't work.
Please let me know if you have any suggestions.