Date: Sun, 7 Mar 2004 14:52:49 +0000 From: Matthew Seaman <m.seaman@infracaninophile.co.uk> To: Dragoncrest <dragoncrest@voyager.net> Cc: questions@freebsd.org Subject: Re: starting xwindows apps from console? Message-ID: <20040307145249.GH52694@happy-idiot-talk.infracaninophile.co.uk> In-Reply-To: <200403071415.i27EF4Xd003436@mail4.mx.voyager.net> References: <200403071415.i27EF4Xd003436@mail4.mx.voyager.net>
next in thread | previous in thread | raw e-mail | index | archive | help
--X1xGqyAVbSpAWs5A Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Mar 07, 2004 at 09:15:04AM -0500, Dragoncrest wrote: > I know I saw something about how to do this at one time, but I can't > seem to find any information about it anymore. What I'm looking to do > is start several KDE gui based apps from a remote ssh session. I can do > it from the actual machine via the console because it knows how to find > the running Xserver and selected desktop. But if I'm remotedly shelled > in via SSH, it has no idea where Xwindows is or if there's an active > desktop or KDE session going. I do remember one time seeing an example > of how to do this that was something like "/path/to/app/appname :0 d1" > or something along those lines. This would then allow me to start a gui > app in KDE (provided it was running) via my remote shell. ssh has the ability to set up an encrypted tunnel fron the remote client machines you log into to the X Server on your local system. Try: % ssh -X otherhost.example.com then look at your environment in your remote session and see if the DISPLAY variable has been set: % echo $DISPLAY localhost:10.0 Be sure your shell initialization files on the remote client machine aren't overriding that setting. It might use the remote hostname, rather than localhost, but the display number will be 10 or above. If $DISPLAY is set automatically like that, then you can just start up X programs from the command line and have them display on your local desktop. To make that encrypted tunnel setup happen automatically every time you log into that box, create a file ~/.ssh/config and place in it: Host otherhost.example.com ForwardX11 yes The ssh_config(5) and sshd_config(5) man pages, as ever, have more information. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK --X1xGqyAVbSpAWs5A Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFASzdBdtESqEQa7a0RAlWxAJ0S3Wc5ecjf+yEMLwe0/YZu2WXMAwCfbkHN MJa6q7XVjyLWV1Of29bJFt8= =zEmM -----END PGP SIGNATURE----- --X1xGqyAVbSpAWs5A--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040307145249.GH52694>