1

I'm trying to access my work computer from home. We are supposed to SSH into a server, say ssh.company.com and from there ssh into an xhost to to work, say xhost04.company.com. xhost04 is not directly accessible. How can I browse files on xhost04 from my home computer using nautilus (in ubuntu) with SSHFS.

To access the SSH host I would use:

ssh -t -X ssh.company.com ssh -X internalserver

How do I modify this for SSHFS? Without the double tunneling I have the following:

sshfs user@ssh.company.com: ~/far_projects
D W
  • 125
  • 1
  • 5
  • The issue with sshfs for achieving this is that sshfs uses the sftp subsystem and cannot execute any command. See my top-voted response on this question: http://serverfault.com/questions/158392?tab=votes#tab-top – Weboide Jul 20 '10 at 00:50
  • I have looked at the link you provided but I'm sorry I'm pretty new and I don't know how to use that for my needs. I'm not trying to sudo over ssh, I'm not sure how it applies to my situation. Could provide me with an example command line solution using the example servers ssh.company.com and xhost04.company.com? – D W Jul 20 '10 at 18:56

1 Answers1

3

Install nc on ssh.company.com, and set up a stanza in ~/.ssh/config as follows:

Host internalserver
    ProxyCommand ssh user@ssh.company.com nc internalserver 22

Then connect to internalserver with the user of your choice.

Ignacio Vazquez-Abrams
  • 45,019
  • 5
  • 78
  • 84
  • Sorry, I'm pretty new to some of this stuff. What is nc? I'm not sure that I have permission to install anything on ssh.company.com, is there a way to avoid this? – D W Jul 20 '10 at 18:49
  • Typically `nc` is pre-installed on many servers – Slava N May 20 '11 at 04:37