Secure Shell or SSH is a network protocol that allows data to be exchanged using a secure channel between two networked devices.

learn more… | top users | synonyms

97
votes
10answers
53k views

How do I set up SSH so I don't have to type my password?

How do I set up SSH so I don't have to type my password when connecting to a host?
58
votes
4answers
16k views

Forward SSH traffic through a middle machine

SSH tunneling is very confusing to me. I am wondering if I can do this in Linux. I have 3 machines.. A. My local machine at home. B. Machine at work that I can SSH into (middle man). C. My desktop ...
85
votes
9answers
75k views

ssh tunnel via multiple hops

Tunneling data over ssh is pretty straight-forward: ssh -D9999 username@foreignhost.com sets up port 9999 on your localhost as a tunnel to foreignhost.com, but I have more specific need: I am ...
34
votes
2answers
33k views

Can I create an SSH user which can access only certain directory?

I have a Virtual Private Server which I can connect to using SSH with my root account, being able to execute any linux command and access all the disk area, obviously. I would like to create another ...
6
votes
6answers
7k views

Connect to Linux by name rather than IP

I'm new to Linux (currently running Ubuntu 10.04) and I have just finished setting up SSH access to my Linux Machine. Currently, I have to use ssh root@x.x.x.x to connect but would much rather be ...
9
votes
1answer
2k views

Leave bash script running on remote terminal while not logged in?

I have a bash script that takes several hours to run. While it's running, I would like to do other things, which may involve logging out or disconnecting from the internet (my script runs network ...
10
votes
3answers
15k views

How can I use ssh to run a command on a remote Unix machine and exit before the command completes?

How can I use ssh to run a command on a Unix machine and exit before the command completes? For instance, if I type ssh localhost 'sleep 60 &' ssh hangs on my terminal until sleep completes, ...
22
votes
3answers
8k views

Are GPG and SSH keys interchangable?

I want to generate an RSA key in GPG and use it in SSH login. Is this even possible? If so, how?
41
votes
8answers
58k views

How can I tunnel all of my network traffic through SSH?

Whenever I'm using the internet from an insecure location (such as public wifi) I like to use an ssh tunnel (ssh -D port host) to ensure my traffic can't be sniffed. Unfortunately, there seem to be ...
28
votes
4answers
30k views

UDP traffic through SSH tunnel

The title pretty much sums it up. I would like to send UDP traffic through a SSH tunnel. Specifically, I need to be able to send UDP packets through the tunnel and have the server be able to send ...
35
votes
6answers
38k views

How to use Mac OS X Keychain with SSH keys?

I understand that since Mac OS X Leopard the Keychain has supported storing SSH keys. Could someone please explain how this feature is supposed to work. I have some RSA keys that I've generated ...
25
votes
4answers
36k views

How do I make Bash my default shell on Ubuntu?

I have a .bash_profile in my home directory, but it isn't getting run on login. If I do the following, then things seem to be as I expect: ssh myhost bash source ~/.bash_profile But normally that ...
2
votes
2answers
1k views

Basic ssh tunneling through generic linux ssh server/client

I'm use my home pc to connect to the corporate server with ssh doing something like: ssh -p 2424 user@corporatehost.com Then I log in remotely once more to another server in the corporate ...
15
votes
1answer
83k views

Mounting SSH/SFTP shares on Windows 7 [duplicate]

Possible Duplicate: SFTP as a folder on Vista I'm fairly unfamiliar with Windows, especially Windows 7, but using it for a school project; essentially I have a directory accessible through ...
15
votes
5answers
10k views

SSH access to office host behind NAT router

I would like to access the ssh port of my office linux host from home. Unfortunately the host is located behind a NAT router. So, the IP address is not publicly available. There is however access to ...
12
votes
2answers
2k views

How, if at all, do SSH keys differ from asymmetric keys used for other purposes?

How, if at all, do SSH keys differ from asymmetric keys used for other purposes, e.g. email signing? I'm prompted to ask this, in part, because on OS X, there are apps available to manage SSH keys ...
2
votes
2answers
4k views

sshfs equivalent for windows? [closed]

At my university, I want to be able to set up a file-server in my room. The only allowed ports/protocols are SSH and RDP. All others are blocked. I can set up the server just fine, and connect to it ...
4
votes
2answers
3k views

On Linux can I keep a program running in background even after I disconnect?

If I'm logged into a remote Linux machine, I know I can suspend a process (cntr-z) and move it to the background (bg 1) but if I disconnect from the machine, the process stops. Is there a way I can ...
1
vote
1answer
250 views

How can I start a process over SSH such that it will continue to run after I disconnect?

XBMC occasionally crashes on my media server. It's a pain to bring down the media server because I have to manually restart a number of services each time. I'd like to be ablle to start XBMC from an ...
1
vote
1answer
587 views

ssh terminal session times out, how can this be changed

It seems after about 5 minutes an inactive ssh session is terminated. The server is Ubuntu. How can I change this?
70
votes
11answers
43k views

How to reliably keep an SSH tunnel open?

I use an SSH tunnel from work to go around various idotic firewalls (it's ok with my boss :)). The problem is, after a while the ssh connection usually hangs, and the tunnel is broken. If I could at ...
61
votes
2answers
66k views

How to convert .ppk key to OpenSSH key under Linux?

I know that is possible to convert .ppk under puttygen in Windows, but how to do that on Linux? Is this possible ?
15
votes
6answers
6k views

How can I get ssh-agent working over ssh and in tmux (on OS X)?

I have a private key set up for my github account, the passphrase to which is, I believe, stored in OS X's keychain. I certainly don't have to type it in when I open a terminal window and enter ssh ...
12
votes
7answers
13k views

Windows SSH Servers?

I was wondering what people use as an SSHd server on Windows? I've decided that I want to be able to log in using SSH on my Windows computers but I don't want to use Linux full-time. What are my ...
7
votes
3answers
2k views

Remote into Linux workstation behind a firewall

Let's say I have a Linux workstation at work, behind a firewall. So even though I may have a remote access server set up on it (such as the most excellent NoMachine NX Server), I can't access it from ...
10
votes
1answer
2k views

How do I make OS X set the terminal title back to the original title when coming back from ssh?

Starting on OS X, I ssh into foo (a Linux box). My terminal title changes to foo. I then ssh into bar (another Linux box). My terminal title changes to bar. I log out of bar. My terminal title ...
8
votes
8answers
4k views

Pushing my PS1 prompt over ssh

I use a specific PS1 prompt that I like. I share a few logins with other other people on a few different servers. I was wondering if there was a way to specify in my local bash profile a remote prompt ...
5
votes
5answers
6k views

How to edit known_hosts when several hosts share the same IP and DNS name?

I regularly ssh into a computer which is a dual-boot OS X / Linux computer. The two OS instance do not share the same host key, so they can be seen as two host sharing the same IP and DNS. Let's say ...
7
votes
2answers
2k views

How to make ssh log in as the right user?

I use ssh on a variety of machines, mainly linux. Accounts on these machines vary in naming scheme: if my name is First Last, then I have accounts: first, flast, last_f, lastf, and sometimes I need to ...
6
votes
2answers
5k views

Enable SSH on a Mac in single user mode

I have an iMac that I can access only in single user mode, because of serious hardware damage. I attached to it another computer with an Ethernet cable. I would like to login remotely to the iMac ...
5
votes
4answers
3k views

SSH to computer with shared public IP and no admin rights over the router

I live in a student dorm (off-campus) and all students of the dorm share the same WAN IP (Internet or public IP), which is fortunately static. I am not an admin and have no control over the router ...
4
votes
2answers
1k views

rsync over SSH with cron in osx-environment

I want to automatically download files and folders from a Linux server to which I have an SSH (and FTP) account. The files shall be downloaded on a regular basis (I suppose a cron is the right tool to ...
3
votes
5answers
8k views

Connection closed by remote host

I'm trying to connect to a server using a private key generated through cPanel and stored on my local machine, but I am getting the "Connection closed by remote host". Any ideas? XXXXX-computer-2:~ ...
2
votes
2answers
3k views

Can I clone a root file system of a running server via ssh?

I want to make a backup of a running server. Every config files and everything without turning it off. How can I accomplish this? Is it ok to try copying it all? Because I had problems with the root ...
6
votes
1answer
847 views

What exactly determines if a backgrounded job is killed when the shell is exited, or killed?

This question has come up quite a lot (really a lot), but I'm finding the answers to be generally incomplete. The general question is "Why does/doesn't my job get killed when I exit/kill ssh?", and ...
2
votes
4answers
2k views

Redhat Linux password fail on ssh

I am trying to ssh into my linux machine from my mac. If I am physically at the machine I can log in with my password just fine, but if I am sshing it refuses. I am getting: Permission denies ...
1
vote
4answers
4k views

Wake-on-LAN over internet is all but impossible

I have a new MacBook Pro that I want to be able to log into through ssh or vnc, but no matter what combination of things I try nothing seems to work. Even tried LogMeIn How do I set-up my MacBook so ...
0
votes
3answers
3k views

ssh still asking for password when trying to log into another pc

I recently constructed a small Beowulf cluster out of some old computers all running Linux Ubuntu 12.04 LTS and have been following the instructions on this page: ...
80
votes
4answers
50k views

Way to avoid ssh connection timeout & freezing of terminal tab

When I connect via ssh terminal to certain servers, it timeouts and "freezes" the terminal (doesn't accept, doesn't disconnect, can't Ctrl-C to kill the ssh process or anything). This is in Ubuntu's ...
97
votes
3answers
78k views

Tell git which private key to use

ssh has the -i option to tell it which private key file to use when authenticating: -i identity_file Selects a file from which the identity (private key) for RSA or DSA authentication is ...
177
votes
4answers
35k views

What is randomart produced by ssh-keygen?

When you generate a key, you get "randomart" from newer versions of OpenSSH. I am unable to find an explanation of why, and what I'm supposed to use it for. Generating public/private rsa key pair. ...
32
votes
7answers
11k views

Sharing the same `ssh-agent` among multiple login sessions

Is there a convenient way to ensure that all logins from a given user (ie me) use the same ssh-agent? I hacked out a script to make this work most of the time, but I suspected all along that there ...
37
votes
4answers
31k views

How can I avoid SSH's host verification for known hosts?

I get the following prompt everytime I try to connect a server using SSH. I type "yes", but is there a way to aovid this? The authenticity of host '111.222.333.444 (111.222.333.444)' can't be ...
30
votes
4answers
30k views

When ssh'ing, how can I set an environment variable on the server that changes from session to session?

When I ssh into a server, how can I pass an environment variable from the client to the server? This environment variable changes between different invocations of ssh so I don't want to overwrite ...
13
votes
2answers
35k views

How can I create an SSH user who only has permission to access specific folders in Ubuntu?

I installed SSH, but I found if I use my original account to login to Ubuntu, it has too many permissions. I want to constrain the user to only have permissions for specific folders in Ubuntu. How ...
23
votes
2answers
27k views

Where does Putty store known_hosts information on Windows?

How do I tell if Putty already knows about and has cached credentials for specific ssh servers?
6
votes
1answer
3k views

SSH as socks proxy through multiple hosts

Can the following be achieved with SSH. There are three machines involved: A. My local machine at home B. The SSH gateway server at school C. A workstation in a lab, only reachable through B I ...
36
votes
14answers
55k views

Map remote drive in Windows over SSH

Does anyone know of a good (hopefully free) tool that can be used to map a Linux server accessible over SSH/SCP as a Windows network drive? EDIT: SFTP not supported EDIT2: Windows File Sharing/Samba ...
8
votes
4answers
2k views

How can I set my computer up for remote SSH access?

I have a Linux machine that I can access by SSH from my laptop when I am inside my house, but when I am using another Internet connection, I can't connect. What do I need to do? I have Verizon DSL ...
11
votes
2answers
13k views

How to keep program running after SSH disconnection? [duplicate]

Possible Duplicates: Keep a program running after closing a console, after the program has started How can I use ssh to run a command on a remote Unix machine and exit before the command ...