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).

To access the SSH host I would use:

sftp://ssh.company.com/
D W
  • 125
  • 1
  • 5
  • See this: http://serverfault.com/questions/91116/ssh-to-a-computer-that-will-then-ssh-to-another-computer Also check the ssh man page for ProxyCommand – Zoredache Jun 09 '10 at 22:05
  • @DW - You can use FileZilla with sftp and port forwarding. Check out: https://superuser.com/a/1286681/141314 – Noam Manos Jan 18 '18 at 07:22

2 Answers2

2

You should be able to tunnel the ssh connection through ssh.company.com to the internal server, using X forwarding and then launch nautilus on the remote machine.

This should work, although you will need to tweak things if you don't already have keys and user names already configured correctly.

ssh -t -X ssh.company.com ssh -X internalserver nautilus
Richard Holloway
  • 7,456
  • 2
  • 25
  • 30
  • Perfect thank you. One thing that is curious is that the layout of nautilus looks different than nautilus on my local machine. It is like the version of nautilus used comes is not the local one. Does that make sense? Is there a way to access the files with the local nautilus? – D W Jun 09 '10 at 23:40
  • That is because you are actually running nautilus on the remote machine but forwarding the GUI to your local machine. You can configure it to look how you like in Edit>Preferences as you would locally. – Richard Holloway Jun 10 '10 at 08:24
  • Another idea is to mount internalserver:/ onto ssh.company.com:~/internalserver using sshfs and then mount ssh.company.com:~/internalserver onto localmachine:~/internalserver so you then have the internalserver filesystem available as ~/internalserver. It will allow local file access to files on internalserver, so that copy and paste will work and applications will see the files as local files. Speed may be an issue though as sshfs is not very fast but if it is something you use all the time it may be worth setting this up. – Richard Holloway Jun 10 '10 at 08:38
  • I don't know really understand the last solution but it seems like it may be useful. I will go through this tutorial on that topic when I get a chance: http://embraceubuntu.com/2005/10/28/how-to-mount-a-remote-ssh-filesystem-using-sshfs/ – D W Jun 11 '10 at 08:25
  • That is an old resource and things are much easier now-a-days. Use https://help.ubuntu.com/community/SSHFS instead. Or post a new question. – Richard Holloway Jun 11 '10 at 21:29
  • New question: http://serverfault.com/questions/162033/access-remote-server-with-nautilus-through-double-ssh-tunnel-using-sshfs – D W Jul 20 '10 at 00:29
0

If you are able to connect to the server via SSH, you should be able to log directly connecting to the server with

sftp://user@hostname/path_to_connect

It is working absolutely fine for me.