Multiple Session Question

2007-06-07 Thread Duane Ellis
Hello,

I've got cygwin working well via SSH to single host, single window. 
I connect via SSH, and run startkde - I get the KDE desktop in one 
single window. Works great!

How do I connect to a second machine at the same time.

See below for details.

-Duane.


For example:
I login as my self - with ssh  a remote session
And I login as another person to the same machine.
 In my case, I have two accounts:
A development account
And A Test account.

Likewise, I have this situation:
I login to Machine1 - and it works.
I login to Machine2 - and it works.

Problem:
I can only have 1 connection to 1 machine at a time.
Both should have separate window/display.

I have done this with commercial X11 packages, but not CygwinX.

This does not seem to work, and I can't seem to find in the user docs
any thing that reasonably describes some things.

(1) Yes, I have tried using a different display, ie:
127.0.0.1:0.0
And 127.0.0.1:1.0

  That does not work when I have 2 sessions.
  The two displays work - independent of each other

(2) I'm not sure what is going on with the /tmp/.X11-unix/dir
And can't find docs for it - I suspect it is part of the problem.
 
(3) I'm not sure what the --screen options do for the Xwin program.

The script I to start the session (via SSH and public keys) is below,

The difference between the two is WHO and DISPLAY.

The script below - deletes the old /tmp/.X11-dir, which I know is a bad
thing with 2 sessions. I have tried not deleting it - that does not seem to
help.


#!/bin/bash

TARGET=linxbox

WHO=duane
#WHO=testaccount

export DISPLAY=127.0.0.1:0.0
#export DISPLAY=127.0.0.1:1.0
export PATH=/usr/X11R6/bin:$PATH
export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults
export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt
export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
export XNLSPATH=/usr/X11R6/lib/X11/locale

rm -rf /tmp/.X11-unix

XWin -clipboard -silent-dup-error 

echo STARTING KDE REMOTEL
ssh -l $WHO $TARGET startkde 
echo DONE RUNNING KDE REMOTELY

exit


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Modal windows

2007-06-07 Thread Michel Bardiaux
We have a MOTIF app that works correctly when displayed on a debian 
sarge (that is, using xfree) or win2k+exceed8.0.


With cygwin-xfree on winxp, however, the modal windows do NOT stay on 
top of the main application window, the main comes up whenever one 
clicks in it.


In all 3 cases, the client libraries are linux/xfree, at exactly the 
same version.


Is that behavior

- by design?

- a known bug?

- due to a user error?

- a bug never reported yet?

TIA,
--
Michel Bardiaux
RD Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:[EMAIL PROTECTED]

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles
http://www.mediaxim.com/

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Multiple Session Question

2007-06-07 Thread Holger Krull
Duane Ellis schrieb:
 I've got cygwin working well via SSH to single host, single window. 
 I connect via SSH, and run startkde - I get the KDE desktop in one 
 single window. Works great!
 
 How do I connect to a second machine at the same time.

You will need Xwin :1 for the second and Xwin :2 for the third session
and so on.
But i wonder how your first connect works anyway, have you setup ssh
tunneling somewhere?

 (1) Yes, I have tried using a different display, ie:
 127.0.0.1:0.0
 And 127.0.0.1:1.0

You will need this

 (2) I'm not sure what is going on with the /tmp/.X11-unix/dir
 And can't find docs for it - I suspect it is part of the problem.

I don't think so.

 (3) I'm not sure what the --screen options do for the Xwin program.

not needed here

 The script below - deletes the old /tmp/.X11-dir, which I know is a bad

Don't

 #!/bin/bash
 
 TARGET=linxbox
 
 WHO=duane
 #WHO=testaccount
 
 export DISPLAY=127.0.0.1:0.0
 #export DISPLAY=127.0.0.1:1.0
 export PATH=/usr/X11R6/bin:$PATH
 export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults
 export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt
 export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
 export XNLSPATH=/usr/X11R6/lib/X11/locale
 
 rm -rf /tmp/.X11-unix
 
 XWin -clipboard -silent-dup-error 
 


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



RE: [Fwd: Re: Multiple Session Question]

2007-06-07 Thread Duane Ellis
No that does not work - session1 starts, 
then session2 - overwrites/destroys session1.
Then it gets really weird

Both are using the same display number (0.0)

Besides, this is problematic in another way.
I need to be able login/logout 
of the two accounts independently.
 
-Duane.


-Original Message-
From: Reid Thompson [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 07, 2007 11:10 AM
To: Duane Ellis
Subject: [Fwd: Re: Multiple Session Question]

failed to copy you on the reply to the list


try

#!/bin/bash

TARGET=linxbox
TARGETONE=linxbox1

WHO=duane
WHO1=testaccount

export DISPLAY=127.0.0.1:0.0
#export DISPLAY=127.0.0.1:1.0
export PATH=/usr/X11R6/bin:$PATH
export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults
export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt
export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
export XNLSPATH=/usr/X11R6/lib/X11/locale


XWin -clipboard -silent-dup-error 

echo STARTING KDE REMOTEL
ssh -l $WHO $TARGET startkde 
ssh -l $WHO1 $TARGETONE startkde 
echo DONE RUNNING KDE REMOTELY

exit

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Multiple Session Question

2007-06-07 Thread Reid Thompson
On Thu, 2007-06-07 at 10:50 -0400, Duane Ellis wrote:
 Hello,
 
 I've got cygwin working well via SSH to single host, single window. 
 I connect via SSH, and run startkde - I get the KDE desktop in one 
 single window. Works great!
 
 How do I connect to a second machine at the same time.
 
 See below for details.
 
 -Duane.
 
 
 For example:
 I login as my self - with ssh  a remote session
 And I login as another person to the same machine.
  In my case, I have two accounts:
   A development account
   And A Test account.
 
 Likewise, I have this situation:
   I login to Machine1 - and it works.
   I login to Machine2 - and it works.
 
 Problem:
   I can only have 1 connection to 1 machine at a time.
   Both should have separate window/display.
 
 I have done this with commercial X11 packages, but not CygwinX.
 
 This does not seem to work, and I can't seem to find in the user docs
 any thing that reasonably describes some things.
 
 (1) Yes, I have tried using a different display, ie:
 127.0.0.1:0.0
 And 127.0.0.1:1.0
 
   That does not work when I have 2 sessions.
   The two displays work - independent of each other
 
 (2) I'm not sure what is going on with the /tmp/.X11-unix/dir
 And can't find docs for it - I suspect it is part of the problem.
  
 (3) I'm not sure what the --screen options do for the Xwin program.
 
 The script I to start the session (via SSH and public keys) is below,
 
 The difference between the two is WHO and DISPLAY.
 
 The script below - deletes the old /tmp/.X11-dir, which I know is a bad
 thing with 2 sessions. I have tried not deleting it - that does not seem to
 help.
 
 
 #!/bin/bash
 
 TARGET=linxbox
 
 WHO=duane
 #WHO=testaccount
 
 export DISPLAY=127.0.0.1:0.0
 #export DISPLAY=127.0.0.1:1.0
 export PATH=/usr/X11R6/bin:$PATH
 export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults
 export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt
 export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
 export XNLSPATH=/usr/X11R6/lib/X11/locale
 
 rm -rf /tmp/.X11-unix
 
 XWin -clipboard -silent-dup-error 
 
 echo STARTING KDE REMOTEL
 ssh -l $WHO $TARGET startkde 
 echo DONE RUNNING KDE REMOTELY
 
 exit
 
 
 --
 Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
 Problem reports:   http://cygwin.com/problems.html
 Documentation: http://x.cygwin.com/docs/
 FAQ:   http://x.cygwin.com/docs/faq/


try

#!/bin/bash

TARGET=linxbox
TARGETONE=linxbox1

WHO=duane
WHO1=testaccount

export DISPLAY=127.0.0.1:0.0
#export DISPLAY=127.0.0.1:1.0
export PATH=/usr/X11R6/bin:$PATH
export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults
export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt
export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
export XNLSPATH=/usr/X11R6/lib/X11/locale


XWin -clipboard -silent-dup-error 

echo STARTING KDE REMOTEL
ssh -l $WHO $TARGET startkde 
ssh -l $WHO1 $TARGETONE startkde 
echo DONE RUNNING KDE REMOTELY

exit

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



RE: [Fwd: Re: Multiple Session Question]

2007-06-07 Thread Duane Ellis
=

Holger Krull You will need Xwin :1 for the second and 
Xwin :2 for the third session and so on.

That's the solution - I forgot - is the same way on linux.
Thank you very much, works *GREAT*

For those reading this (via a search engine), if it is not specified, the
default is :0 Which is Display 0, 

Below is a resulting template script that works very nicely, for me, with
some limitations.

I could - via additional shell tricks, do the following:

1)  In the directory: /tmp/.X11-unix/ are unix ?sockets? 
(visible only under CYGWIN not via windows). 

In my case, right now, I have these two files:

/tmp/.X11-unix/X0
And /tmp/.X11-unix/X2

   Thus right now, Display 0, and 2 are active, yours may be different.

2) I could write shellscript stuff that finds a free display number
   And uses that number - instead of hard coding the display number.
   I'll leave that as an exercise for you, the reader.

3) Also - one must deal with cleanup of stale files laying around.
   in some clean and graceful way.

=

Holger Krull But i wonder how your first connect works anyway, have you
setup ssh tunneling somewhere?

Yes, I have, via my ~/.ssh/config file - I have lots of things setup
Including X-11 forwarding, my identity file, etc. That way I do not have to
re-specify a zillion options everyplace I script SSH.

Again, for those reading this via a search engine, my ssh_config file looks
sort of like this I have many accounts, in this example I use R and X. Both
Accounts have different user names.

I could - specify -X, -L, -I, and -lots-of-options on every command line
everywhere I use SSH --yuck, and --double-yuck Or - I can use an SSH config
file (which hides/collects that sort of stuff in one nice little file.

Blow is an example short snippit of an ssh config file (maybe with typos), I
can type: 'ssh rrr' or 'ssh xxx' and it works just fine, see man
ssh_config for more details I could add other host entries - like: ssh
plant1 or ssh plant2 or ssh home and, if needed, with the cygwinX
shellscript (and a fat pipe) run X sessions from anywhere in the world. 


File: ~/.ssh/config

Host  rrr
  Hostname   rrr.someplace.special.com
  ForwardX11 yes
  ForwardX11Trusted yes
  IdentityFile id_rsa_rrr
  User dellis

[blank lines]

Host  xxx
  Hostname   xxx.other.place.com
  ForwardX11 yes
  ForwardX11Trusted yes
  IdentityFile id_rsa_xxx
  User duane

-- SCRIPT -- 


#---
#! /bin/sh
# Important variables are:
#   TARGET = hostname you want to connect to.
#   WHO = who (username) you want to connect as. 
#   D_NUM = display number to use for this session.

TARGET=myhostname
WHO=myusername
D_NUM=2

export DISPLAY=127.0.0.1:${D_NUM}.0
export PATH=/usr/X11R6/bin:$PATH
export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults
export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt
export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB
export XNLSPATH=/usr/X11R6/lib/X11/locale

XWin :${D_NUM} -clipboard -silent-dup-error 

ssh -l $WHO $TARGET startkde 

exit



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



RE: Modal windows

2007-06-07 Thread Phil Betts
Michel Bardiaux wrote on Thursday, June 07, 2007 4:01 PM::

 We have a MOTIF app that works correctly when displayed on a debian
 sarge (that is, using xfree) or win2k+exceed8.0.
 
 With cygwin-xfree on winxp, however, the modal windows do NOT stay on
 top of the main application window, the main comes up whenever one
 clicks in it.
 
 In all 3 cases, the client libraries are linux/xfree, at exactly the
 same version.
 
 Is that behavior
 
 - by design?
 
 - a known bug?
 
 - due to a user error?
 
 - a bug never reported yet?
 

Assuming you're using multiwindow mode, each X window is rendered in a
different Windows window.  Unfortunately, modality in X is not the same 
as in Windows.  In X, the display (server), window manager, and client 
are separate processes, and have clearly defined roles.  This is why 
it's possible to move the parent of a modal window, because the client 
is not responsible for its window's placement.  In Windows, the client
process is responsible for handling windows movement events, so the
entire parent window, including the frame is effectively iced.  I think 
the decision was taken that rather than inflict Windows' arguably 
broken concept of modality on an unsuspecting X process, all X windows 
are created as non-modal Windows windows.  The modality at the client
level is still maintained (i.e. you can't do anything in the parent),
but you will still be able to move the parent window about.

If you really need full X-style modality, you should be able to use
one of the other modes (rootless or fullscreen) and run an external
window manager.  The only problem with this IIRC, is that all X 
windows are really just images in a single Windows window, so 
clicking on any X window brings all X windows to the top.

Note that Windows' notion of stacking order is completely broken.
Always-on-top windows are frequently rendered on the bottom.  This
includes modal windows, which  is just great if they are rendered
completely beneath the now disabled parent window!


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



RH-EL-4 -vrs- RH-EL-5

2007-06-07 Thread Duane Ellis
Another problem has cropped up.

I use CygwinX with RH-EL-4, and other machines - been working great.

Now, New machine RedHat Enterprise Linux 5

Same connection method, works great with RH-EL-4 (ie: Refer to my earlier
multiple sessions email)

But when connecting to RH-EL-5 - provided I do nothing with the keyboard it
works perfectly.

If however, if I type anything on the keyboard - 1 letter, or 10 to 20
letters... within seconds of typing something, CygwinX totally hangs for
some period of time (10 to 20 seconds) - ie: Windows says it is not
responding - then it refreshes - catches up on what I type, then goes away
for 10 to 20 seconds... repeat for ever

Does not matter if I open an Xterm and type ls, or open FireFox and type
'http://something'

I suspect RH-EL-5 is provoking something in CygwinX - I do not know. The
CygwinX is very new (I got a new computer 1 month ago and did a fresh
install of cygwin)

The relevant X11 versions are below (grepped from /etc/setup/install.db)

Looking bash/cygwin window where I started the session, I do not see
anything important etc - ie: timeout messages, just the 'normal bunch of
warnings' same on all machines - including RHEL5

Any suggestions?

-Duane.


xorg-x11-base xorg-x11-base-6.8.99.901-1.tar.bz2 0
xorg-x11-bin xorg-x11-bin-6.8.99.901-1.tar.bz2 0
xorg-x11-bin-dlls xorg-x11-bin-dlls-6.8.99.901-1.tar.bz2 0
xorg-x11-bin-lndir xorg-x11-bin-lndir-6.8.99.901-1.tar.bz2 0
xorg-x11-devel xorg-x11-devel-6.8.99.901-1.tar.bz2 0
xorg-x11-etc xorg-x11-etc-6.8.99.901-1.tar.bz2 0
xorg-x11-f100 xorg-x11-f100-6.8.99.901-1.tar.bz2 0
xorg-x11-fcyr xorg-x11-fcyr-6.8.99.901-1.tar.bz2 0
xorg-x11-fenc xorg-x11-fenc-6.8.99.901-1.tar.bz2 0
xorg-x11-fnts xorg-x11-fnts-6.8.99.901-1.tar.bz2 0
xorg-x11-fscl xorg-x11-fscl-6.8.99.901-1.tar.bz2 0
xorg-x11-fsrv xorg-x11-fsrv-6.8.99.901-1.tar.bz2 0
xorg-x11-libs-data xorg-x11-libs-data-6.8.99.901-1.tar.bz2 0
xorg-x11-man-pages xorg-x11-man-pages-6.8.99.901-1.tar.bz2 0
xorg-x11-man-pages-html xorg-x11-man-pages-html-6.8.99.901-1.tar.bz2 0
xorg-x11-nest xorg-x11-nest-6.8.99.901-1.tar.bz2 0
xorg-x11-vfb xorg-x11-vfb-6.8.99.901-1.tar.bz2 0
xorg-x11-xwin xorg-x11-xwin-6.8.99.901-1.tar.bz2 0
xorg-x11-xwin-gl xorg-x11-xwin-gl-6.8.99.901-1.tar.bz2 0


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: RH-EL-4 -vrs- RH-EL-5

2007-06-07 Thread Holger Krull
Duane Ellis schrieb:
 Now, New machine RedHat Enterprise Linux 5
 
 But when connecting to RH-EL-5 - provided I do nothing with the keyboard it
 works perfectly.
 
 I suspect RH-EL-5 is provoking something in CygwinX - I do not know. The

Still starting a complete kde? Try starting netscape alone to see if it
suffers from the same effect.
Create a new user on rh-el-5 to get a fresh profile.
Not sure if it helps but worth a try.



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/