startxwin.bat - how to use an .xinitrc file

2003-09-25 Thread Mike Campbell
I have several things that I like to have run when I start an xsession 
and normally I would put these into a ~/.xinitrc file to have them run 
at X startup time.

However, when I run startxwin.bat it does not appear to execute the 
.xinitrc file automatically. Therefore I have had to manually edit the 
startxwin.bat file and add my custom stuff.

Id like to find a way around editing startxwin.bat since after every 
xfree update I have to re-edit the file and re-add my custom lines.

Am I missing something here? Is there a way to get startxwin.bat to 
automatically find $HOME/.xinitrc or would this be a good enhancement 
request?

Thanks,
Mike Campbell


Re: Odd XDMCP problems (resolved)

2003-09-19 Thread Mike Campbell
Well I figured out what the problem was with my XDMCP connection.

I had edited the /etc/profile file to set the DISPLAY environment 
variable dynamically using the host I was connecting from. The entry in 
the /etc/profile was this:

export DISPLAY=${REMOTEHOST}:0.0

It seems that when an XDMCP is made the REMOTEHOST environment variable 
is not set and therefore the DISPLAY environment variable ends up 
getting set to :0.0 which points to the linux console instead of the 
remote Cygwin machine.

The fix was to edit the .bash_profile in the user's home directory and 
manually set the DISPLAY environment variable to point back to the 
remote machine running the Cygwin xserver. Now everything works perfectly.



Mike,

Mike Campbell wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
   Here is an odd one for you to try to help me figure out.

I have configured my RedHat Linux 9.0 system to allow XDCMP connections.
When I reboot the server the console comes up with the default kdm login
box.
~From my win2k machine I have installed all of the cygwin Xfree tools. I
used the startxdmcp.bat file (after editing it for the remote_address
parameter) and it successfully connects to the linux box and I see the
login dialog box. So far so good.
Initally when I would log in the cygwin screen would turn light blue and
then after 5 seconds or so the login box would reappear and a message
about my session lasting less than 10 seconds. I found on the linux
machine where I was logging in the following in the .xsession-errors file:
set:  unable to open display :0.0
xsetroot:  unable to open display ':0.0'
xrdb: Connection refused
xrdb: Can't open display ':0.0'
startkde: Starting up...
ksplash: cannot connect to X server :0.0
_KDE_IceTransmkdir: Owner of /tmp/.ICE-unix should be set to root
kded: cannot connect to X server :0.0
kdeinit: Can't connect to the X Server.
kdeinit: Might not terminate at end of session.
kcminit: cannot connect to X server :0.0
knotify: cannot connect to X server :0.0
ksmserver: cannot connect to X server :0.0
startkde: Shutting down...
startkde: Running shutdown scripts...
KLauncher: Exiting on signal 1
startkde: Done.


Looks like you might need the -from MY_IP_ADDRESS command-line parameter 
in startxdmcp.bat for XWin.exe. Although, this doesn't make a lot of 
sense because you probably wouldn't even get the login screen if the 
from address wasn't being set correctly.

I then edited the /etc/kde/kdm/Xstartup file on the linux machine and
added a line that said 'xhost +' and restart the X server on the linux
machine.


The xhost + is not the answer. Please remove that line or accept the 
security risks that it has, even though it is providing you with no benefit.

I think the real problem here is that XDM on your linux machine is not 
setting the DISPLAY variable correctly. The output from the log file 
shows this:

 xsetroot: unable to open display ':0.0'

:0.0 means to connect to the local machine on display 0, screen 0. That 
is typically the console. This is obviously incorrect, since you need 
all X Clients to connect to the X Server running on your Windows machine.

For some odd reason my DISPLAY from the xdmcp session seems incorrect.
It should set DISPLAY to point back to the cygwin xfree server instead
of the linux console. How do I fix this???
 

I have never, ever, heard of anyone reporting this problem before where 
the DISPLAY is not getting set correctly by the XDM server (again, 
unless you just need the -from parameter as mentioned above). Can we 
assume that this RedHat 9.0 installation is 100% non-modified or have 
people had their hands on it, customizing it? If the installation has 
been heavily customized, then I think that someone made a mistake in one 
of those customizations. If the installation has not been heavily 
customized, then perhaps you could do some searching to find out if this 
a generic problem for RedHat 9.0.

Hey, I have an idea... why don't you try opening an XDMCP session to 
your RedHat 9.0 machine from another *nix machine. That would help 
determine if Cygwin/XFree86 or the RedHat machine configuration is at fault.

Harold



Odd XDMCP problems

2003-09-18 Thread Mike Campbell
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Here is an odd one for you to try to help me figure out.

I have configured my RedHat Linux 9.0 system to allow XDCMP connections.
When I reboot the server the console comes up with the default kdm login
box.
~From my win2k machine I have installed all of the cygwin Xfree tools. I
used the startxdmcp.bat file (after editing it for the remote_address
parameter) and it successfully connects to the linux box and I see the
login dialog box. So far so good.
Initally when I would log in the cygwin screen would turn light blue and
then after 5 seconds or so the login box would reappear and a message
about my session lasting less than 10 seconds. I found on the linux
machine where I was logging in the following in the .xsession-errors file:
set:  unable to open display :0.0
xsetroot:  unable to open display ':0.0'
xrdb: Connection refused
xrdb: Can't open display ':0.0'
startkde: Starting up...
ksplash: cannot connect to X server :0.0
_KDE_IceTransmkdir: Owner of /tmp/.ICE-unix should be set to root
kded: cannot connect to X server :0.0
kdeinit: Can't connect to the X Server.
kdeinit: Might not terminate at end of session.
kcminit: cannot connect to X server :0.0
knotify: cannot connect to X server :0.0
ksmserver: cannot connect to X server :0.0
startkde: Shutting down...
startkde: Running shutdown scripts...
KLauncher: Exiting on signal 1
startkde: Done.
I then edited the /etc/kde/kdm/Xstartup file on the linux machine and
added a line that said 'xhost +' and restart the X server on the linux
machine.
Now when I use startxdmcp.bat file I enter my user/pass and get the
light blue screen on the cygwin side. However, nothing else shows up on
the cygwin side. Oddly though, on the linux console I see that I am
logged into kde as the user I entered on the cygwin side.
Once I log out of kde from the linux console the cygwin xfree session
displays the login dialog box again.
For some odd reason my DISPLAY from the xdmcp session seems incorrect.
It should set DISPLAY to point back to the cygwin xfree server instead
of the linux console. How do I fix this???


- --

___
Mike Campbell
Technical Specialist   Phone: 407.458.5688
Oracle Corporation Email: [EMAIL PROTECTED]
GPG Fingerprint 6C34 6C22 4760 A01F 7C83 11CE C117 CDF1 8241 7C64



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.3 (MingW32)
Comment: http://webpages.charter.net/mcampbell17/publickey.asc
iD8DBQE/agj4wRfN8YJBfGQRAi1DAKDqlNrP9joyndlXX8XRv4f0WKu3RwCcCE0y
BJtskfjkspsIEnKDP8kUhLk=
=9RUd
-END PGP SIGNATURE-