I can ssh into a remote machine. I can start X on that machine with startx How do I then start firefox on that machine (from the ssh prompt) and have it display on my machine in my office. So I want to be using firefox on the remote machine but displaying the screen output from firefox in my office. Both boxes are running centos 5. how is that done? Jerry
Jerry Geis wrote:> I can ssh into a remote machine. > I can start X on that machine with startx > > How do I then start firefox on that machine (from the ssh prompt) and > have it display on my machine in my office. > > So I want to be using firefox on the remote machine but displaying the > screen output from firefox in my office. > Both boxes are running centos 5. > > how is that done? > > > Jerry > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >Hi you dont need to start X on the remote system at all ssh -X <machine to connect to> firefox
Jerry Geis wrote:> I can ssh into a remote machine. > I can start X on that machine with startx > > How do I then start firefox on that machine (from the ssh prompt) and > have it display on my machine in my office. > > So I want to be using firefox on the remote machine but displaying the > screen output from firefox in my office. > Both boxes are running centos 5.don't startx on the REMOTE machine, have it running on the LOCAL machine. local$ ssh -X remote ...authenticate... remote$ firefox & and firefox should open on the local...
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Jerry Geis wrote:> > So I want to be using firefox on the remote machine but displaying the > screen output from firefox in my office. > Both boxes are running centos 5. > > how is that done?First, man ssh, so you can read the ssh manual. Second, make sure on the remote host that this line is in /etc/ssh/sshd_config. X11Forwarding yes Then run ssh while forwarding X [you at office ~]$ ssh -X user at host [you at remote ~]$ /usr/bin/firefox Regards, Max -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.6 (GNU/Linux) iD8DBQFHWK4oHoeeepPau2ERAprrAJ4xwyzkVAxaHfYibjnIQgbJR1EZAACglSuR Rj4AbSA13VW/64kbGzaOW8g=nZOy -----END PGP SIGNATURE-----
> I can ssh into a remote machine. > I can start X on that machine with startxNo need to start X on the remote machine. You need to do "ssh -X <remotemachine>" so that X is forwarded (back to the machine that you ssh'ed from). Make sure that "X11Forwarding yes" is set in the /etc/ ssh/sshd_config file (restart the sshd if it was not). Then you can simply type "firefox &" and it will appear on the machine you started the ssh from (assuming of course that a X server is running locally). This of course works for any X11 application, not just Firefox. Alfred
> > Jerry Geis wrote: > >/ I can ssh into a remote machine. > />/ I can start X on that machine with startx > />/ > />/ How do I then start firefox on that machine (from the ssh prompt) and > />/ have it display on my machine in my office. > />/ > />/ So I want to be using firefox on the remote machine but displaying the > />/ screen output from firefox in my office. > />/ Both boxes are running centos 5. > / > don't startx on the REMOTE machine, have it running on the LOCAL machine. > > local$ ssh -X remote > ...authenticate... > remote$ firefox & > > and firefox should open on the local...I tried the above (without the &) and firefox just returns. I looked at /etc/ssh/sshd_config and X11Forwarding is yes. Jerry -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/centos/attachments/20071206/f4d83a5e/attachment-0003.html>
> > >/ > />/ Jerry Geis wrote: > />/ >/ I can ssh into a remote machine. > />/ />/ I can start X on that machine with startx > />/ />/ > />/ />/ How do I then start firefox on that machine (from the ssh prompt) and > />/ />/ have it display on my machine in my office. > />/ />/ > />/ />/ So I want to be using firefox on the remote machine but displaying the > />/ />/ screen output from firefox in my office. > />/ />/ Both boxes are running centos 5. > />/ / > />/ don't startx on the REMOTE machine, have it running on the LOCAL machine. > />/ > />/ local$ ssh -X remote > />/ ...authenticate... > />/ remote$ firefox / > /& > />/ > />/ and firefox should open on the local... > / > I tried the above (without the &) and firefox just returns. > > I looked at /etc/ssh/sshd_config and X11Forwarding is yes. > >ssh -X remoteIP firefox It just took a really long time through the internet... Thanks, Jerry -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.centos.org/pipermail/centos/attachments/20071206/53c515ae/attachment-0003.html>
On 07/12/2007, Jerry Geis <geisj at pagestation.com> wrote:> > > Jerry Geis wrote: > > I can ssh into a remote machine. > > I can start X on that machine with startx > > > > How do I then start firefox on that machine (from the ssh prompt) and > > have it display on my machine in my office. > > > > So I want to be using firefox on the remote machine but displaying the > > screen output from firefox in my office. > > Both boxes are running centos 5. > > don't startx on the REMOTE machine, have it running on the LOCAL machine. > > local$ ssh -X remote > ...authenticate... > remote$ firefox & > > and firefox should open on the local... > > I tried the above (without the &) and firefox just returns. > > I looked at /etc/ssh/sshd_config and X11Forwarding is yes.First - make sure you have "xauth" installed on the remote machine. With CenttOS 5 it comes in xorg-x11-xauth. Ssh needs it to pass over the x11 authentication cookies (e.g. I don't install X environment on my servers so I have to remember to install this package separately). Secondly - when you login through SSH, type "echo $DISPLAY" and see if you get anything - if not then X11 isn't being forwarded yet. Also I hope you start ssh after having X11 environment started on your local machine and from a shell which has $DISPLAY set correctly *locally*. When all these tests are passed I usually try to run a basic X11 program like "xlogo" but you might not have it so just try to run firefox again and see what happens. --Amos
On 07/12/2007, Jerry Geis <geisj at pagestation.com> wrote:> > > > > > Jerry Geis wrote: > > >/ I can ssh into a remote machine. > > />/ I can start X on that machine with startx > > />/ > > />/ How do I then start firefox on that machine (from the ssh prompt) and > > />/ have it display on my machine in my office. > > />/ > > />/ So I want to be using firefox on the remote machine but displaying the > > />/ screen output from firefox in my office. > > />/ Both boxes are running centos 5. > > / > > don't startx on the REMOTE machine, have it running on the LOCAL machine. > > > > local$ ssh -X remote > > ...authenticate... > > remote$ firefox > > & > > > > and firefox should open on the local... > > I tried the above (without the &) and firefox just returns. > > I looked at /etc/ssh/sshd_config and X11Forwarding is yes. > > > ssh -X remoteIP firefox > > It just took a really long time through the internet...Then consider: 1. turning on maximum compression ("-C" switch to ssh). 2. If you can switch to VNC or NX then do it, apparently it works better than X11 over long distances (and from the docs I understand it's possible to have VNC/NX for one window, no need to setup an entire desktop for that). --Amos
Les Mikesell <lesmikesell at gmail.com> wrote:>>What's a 'trusted' forwarding mean as opposed to any other kind? << A trusted X11 client will bypass the security controls specified in the X11 Security Extension Specification (see http://refspecs.freestandards.org/X11/security.pdf). In general, you don't want to enable this unless you have to. Notice that "trusted forwarding" trusts the users to all be good guys. (In fact, if you're on a trusted network, you shouldn't need to use SSH at all, since you trust the devices (and their users) attached to the network not to do nasty things like network sniffing, MitM attacks, etc.). Best, --- Les Bell, RHCE, CISSP [http://www.lesbell.com.au] Tel: +61 2 9451 1144 FreeWorldDialup: 800909
Bill Campbell <centos at celestial.com> wrote:>>True enough, but ssh makes the X11 DISPLAY things so easy! One doesn't have to much with xhosts and such. << Absolutely - you might *want* to use SSH for the convenience, but you shouldn't *need* to. I preach "SSH Everywhere" as SOP, even on trusted networks. This is probably the case almost everywhere, now that telnet is pretty much dead. Best, --- Les Bell, RHCE, CISSP [http://www.lesbell.com.au] Tel: +61 2 9451 1144 FreeWorldDialup: 800909
Bill Campbell <centos at celestial.com> wrote:>> >(In fact, if you're on a trusted network, you shouldn't need to use SSH at >all, since you trust the devices (and their users) attached to the network >not to do nasty things like network sniffing, MitM attacks, etc.).True enough, but ssh makes the X11 DISPLAY things so easy! One doesn't have to much with xhosts and such. << Let me amplify (sorry for another post!): I was really making a point about the nature of trust, not the convenience of SSH. If you think you want to enabled trusted forwarding (-Y), ask yourself "Would I be happy telneting into this host?". If the answer is yes, then use trusted forwarding. If the answer is no, then don't. Best, --- Les Bell, RHCE, CISSP [http://www.lesbell.com.au] Tel: +61 2 9451 1144 FreeWorldDialup: 800909