SSH (Secure SHell) is a protocol for running commands on a remote computer.

learn more… | top users | synonyms

23
votes
4answers
13k views

Is it possible to find out the hosts in the known_hosts file?

I would like to see what hosts are in my known_hosts file but it doesn't appear to be human readable. Is it possible to read it? More specifically there is a host that I can connect to via several ...
6
votes
1answer
110 views

ssh from linux into mac - permission denied

I'm running a Oracle Linux VM on a Windows 7 host and I'm trying to ssh into my MacBook. I've already created the private/pub keys in my Mac. I have copied the id_rsa.pub contents into the ...
2
votes
1answer
35 views

How to change ssh log location from /var/log/secure to custom location in rhel 6?

By default in RHEL 6, SSH server logs are sent to /var/log/secure. I want to change this location to a custom one. Is it possible to do that? I have tried modifying the rsyslog.conf file, but it does ...
16
votes
2answers
217 views

What's the purpose of the randomart image for user (not host) SSH keys?

The ssh-keygen generates the following output: The key fingerprint is: dd:e7:25:b3:e2:5b:d9:f0:25:28:9d:50:a2:c9:44:97 user@machine The key's randomart image is: +--[ RSA 2048]----+ | .o o.. ...
2
votes
1answer
40 views

Ctrl-S doesn't work in rtorrent when accessed via screen. Can't start torrents

I run rtorrent remotely on a seedbox. When I log in with a web interface I'm able to start torrents, and when torrent files get dropped into my watched folder that works too. However, when I try to ...
3
votes
1answer
34 views

Restricted ssh remote execution with arguments

I need to enable remote execution of a shell script on a server, but deny all other access. The script is a toggle that accepts a single parameter (on/off/status). This comes close to answering my ...
1
vote
2answers
44 views

Copy ssh public key to multiple Linux hosts

I am trying to copy .ssh/id_rsa.pub from our central server to multiple servers. I have the following script which I usually use to push changes to the different servers. #!/bin/bash for ip in ...
0
votes
2answers
578 views

Script SFTP with password - HP-UX

I would like create a script in HP-UX to send in sftp with password. I have this command sftp -o PasswordAuthentication= but if I answer yes or no after, I have this issue "Host key verification ...
1
vote
0answers
46 views

ssh from an unix server to a windows server (running Sysax) fails

We are doing a sFTP from an Unix server to a Windows server and also a ssh, from the Unix server to the Windows server, to execute a file present on the Windows server. These 2 steps worked well. ...
1
vote
0answers
12 views

ajaxterm using proportional font

I have Ubuntu 14.04 LTS, Apache 2.4.7, Python 2.7.6 and Ajaxterm 0.10-12ubuntu1. Ajaxterm is proxied via Apache. Here's the apache.conf excerpt: # Suppresses the Via header ProxyVia Off # Do not ...
1
vote
0answers
77 views

Have tmux wait until I SSH in, to complete rest of Tmuxinator script

After recently discovering tmux and Tmuxinator, I've been trying to set up a development environment to use. Per protocol, we aren't allowed to store passwords/passphrases in scripts. So what I'm ...
1
vote
1answer
256 views

Remotely compile and run program using ssh and screen

I'm trying to compile and run a program remotely. However, I'd like to this within a screen and also I'd like to run this using grid engine on another node after I ssh. Currently I have: ssh ...
68
votes
9answers
40k views

SSH easily copy file to local system

If I'm logged in to a system via SSH, is there a way to copy a file back to my local system without firing up another terminal or screen session and doing scp or something similar or without doing SSH ...
2
votes
3answers
952 views

Limited SSH user on Ubuntu 12

I'm running Minecraft on a server. How can I give my friend SSH access just to the minecraft folder (a root folder), the screen command, and some ports?
1
vote
0answers
42 views

SSH Agent Forwarding on server

I'm struggling with the concept of SSH Agent Forwarding. This is what I've done so far: Create default identity local (ssh-keygen) Install the public key on bitbucket Now I want to connect to a ...
-4
votes
1answer
32 views

connect remote host without password in linux [duplicate]

Am trying to connect remote host by using ssh: ssh xxxx@hostname. It will connect by asking password. But I need to connect host with out password.
2
votes
1answer
32 views

vim: Use different colorscheme when connected over SSH

On my desktop I use the hbrid color scheme in vim, with the preferred colors set for my consoles 16-color palette (as described in the README). However, on my laptop, I use the solarized color ...
11
votes
4answers
14k views

How to delete a file on remote machine via SSH by using a Shell Script?

I am writing a Shell Script where I have to delete a file on a remote machine via a Shell Script. Flow manually: ssh username@domain.com .. then at domain: cd ./some/where rm some_file.war How ...
7
votes
3answers
454 views

Run a diff between local and remote file

I'm connected on a host via ssh and I'd like to compare (let's say with diff) a certain config file against its counterpart on another host, also accessible via ssh, without having to manually ...
1
vote
1answer
609 views

Transferring Files SSH SCP Error Message: 'Stdin: is not a tty'

I am using a Macbook SSH terminal and generated RSA key pairs and uploaded remote id_rsa.pub with approved permissions. I can connect with remote Apache web server. I can create, open, move, modify ...
2
votes
0answers
60 views

Can't figure out why ssh_exchange_identification: Connection closed by remote host appear

At home, I have setup a Raspberry Pi with the latest version of Raspbian and with ssh enabled. I also use a Mac Book Pro with OS X 10.9.3. I use ssh pi@192.168.0.22 to do some work on the Raspberry ...
1
vote
1answer
888 views

ssh_exchange_identification: Connection closed by remote host on vnx machine (linux)

I changed the password of my linux machine . I was able to login for sometime and after that I am not able to ssh. I am getting the following error: ssh es4042cs -v OpenSSH_5.1p1, OpenSSL ...
7
votes
4answers
4k views

How can I set up smart card SSH authentication?

I would like to be able to SSH to my machine using a Gemalto .NET Smart Card as the authentication method. How could this be done on a Fedora 13 (or generic Red Hat style) machine? These are the ...
2
votes
1answer
58 views

SSH config file + shell script help

Well, what I want to do seems a bit convoluted but its the only way I can think of to get the result I want. So here goes. I want to automate ssh to my Pi, in the following fashion: My Pi boots up ...
1
vote
2answers
75 views

Locked myself out of Amazon EC2 SSH - This service allows sftp connections only

Doh. Locked myself out of SSH on an Amazon EC2 box after fiddling with ForceCommand internal-sftp in /etc/ssh/sshd_config in order to allow root log-in via SFTP. SFTP still works fine, but PuTTY ...
1
vote
1answer
65 views

Password-Less SSH Login not working [closed]

I create a SSH Key file on Server A using RSA method ssh-keygen -t rsa Generating public/private rsa key pair. Enter file in which to save the key (/home/oracle/.ssh/id_rsa): Enter passphrase (empty ...
2
votes
2answers
29 views

Allow multiple remote connections to an ssh Dynamic forwarded port

Let us assume I have three machines A - Server to which I am sshing to B - Client from which I am sshing C - Another Client in B's subnet Now, I set up dynamic port forwarding for port 1235 by ...
3
votes
3answers
2k views

SSH: I have a *.pem private key. How to create a SSH connection using it?

I tried to use putty also. I select this pem key there and got this: Unable to use key file "key.pem" (not a private key). I read that it is possible to convert a pem to a pub key. I did it like ...
2
votes
1answer
310 views

SSH agent forwarding, multiple hop

I tested this setup with Linux origin machine - everything is the same - only the first hop can use keys from origin machine. Initial problem I'm trying to set up SSH agent forwarding with multiple ...
6
votes
3answers
2k views

Remote-Accesible Live-Distribution (aka Live CD)

I'm looking for a live distribution (Live CD or the likes) which comes - per default - with sshd running at startup. I want to check the components of my laptop whose graphics has died ...
1
vote
0answers
41 views

DROP all for port 22 if not geoip set of US for iptables and xtables

I want to simply block all ssh access from anywhere but with in the US. This is my whole iptables, and I have followed ...
0
votes
5answers
64 views

Downloading file through SSH with a “proxy” machine inbetween

I need to download a file from machine C to machine A. To do that, I need to login to machine B (I am doing this using scp), as I cannot access C directly from A. Would it be possible to download a ...
1
vote
1answer
23 views

SSH and certificates - how to connect?

My geeky friend has dropped me this message: Debian instance has been created for you with IP address of 10.5.0.95. Remember: To connect to it, you need the certificate: ssh -i xxx.xxx ...
3
votes
2answers
118 views

Logging SSH access attempts

I've configured an ubuntu server with openssh in order to connect to it and execute commands from a remote system like a phone or a laptop. The problem is... I'm probably not the only one. Is there ...
0
votes
3answers
26 views

Is there a log for sshd where I can see who has used ssh to access my PC? [duplicate]

I am running the OpenSSH daemon (sshd) on CrunchBang Linux, and I want to see a history of who (i.e. IP address) has logged in using SSH.
2
votes
3answers
5k views

What is pageant for Linux? Saving SSH private key passwords

I want the computer like pageant, to show a SSH password prompt during boot time. I have my private keys stored in a Dropbox between 3 computers of which 1 is now Ubuntu. I have googled for 2 hours ...
1
vote
1answer
13 views

CentOS 6.4: SSH RSA key issue, “[…]== rsa-key-20140711\n failed”

For some reason sshd is reading from my authorized_keys file a new line that does not exist. I generated the keys with puttygen, copied the public key text in as required, concatenated the key into ...
8
votes
3answers
5k views

How can I track who SSH'es into my linux machine?

I'm running Ubuntu 10.04. Is there a way I can get a daily report of who has logged onto the box, what time, and even - this may be asking too much - a report of the commands they used? This is a ...
3
votes
3answers
49 views

Monitor all login attempts

Few weeks ago I thought it would be a good idea to write a script to send me an email whenever some user logs in into my server. So I came with a perfectly working script notifyLogin.sh, then I ...
4
votes
4answers
4k views

Automated ssh-keygen without passphrase, how?

I would like to make an automated script that calls ssh-keygen and creates some pub/private keypairs that I will use later on. In principle everything works fine with.... ssh-keygen -b 2048 -t rsa -f ...
4
votes
2answers
534 views

SSH connection timing out

I am trying to connect to an external host that is living in the Internet. From my laptop I can ssh fine. From an Ubuntu 12.10 server, the connection times out. Since they're in the same network, ...
1
vote
1answer
4k views

Meaning of “Connection closed by xxx [preauth]” in sshd logs

We have a Windows batch script, which connects automatically to a linux server via PLINK (putty). There is NO public private key authentication, the user and the password are in the script. On our ...
1
vote
0answers
55 views

sudo -u git clone

I'm on Ubuntu server 14.04. I am using apache web server which runs as the www-data. I need to do git clone from a script (a web hook). This script will run with www-data user privilages. Running ...
1
vote
2answers
307 views

Different “history” command output after reconnecting via SSH

Why do I get different results for the "history" command for the same user after I reconnect a disconnected SSH session? I connect to a server using putty (SSH), say as root My network gets ...
2
votes
1answer
25 views

ssh -X foo@host then su bar then run X app with local display, while bar also logged in?

I want to ssh into another machine, using one user account, then su to another user and run X programs as that user, with the display on my computer. The case when the 2nd user is not logged in to X ...
0
votes
1answer
30 views

Locale not being set on initial login on Raspbian/Debian [SOLVED]

Solved http://serverfault.com/a/559935 When I log in to my headless Raspbian box using putty/ssh, the locale is not being set correctly. However, if I su to another user, then su back, the locales ...
1
vote
2answers
86 views

Shell Script - how to scp into remote server and download files and protect password

I have a remote server that I need to download Apache logs from. I can manually scp into the server and get the files, but I'd like to put this in crontab. The only way to automate it is to include ...
3
votes
0answers
75 views

Can't get SSH working anymore on Debian after upgrade

I have a vServer and can only login via SSH. After the latest apt-get upgrade command, I can't login anymore and get the following error message: "Network error: Connection refused". It seems that ...
1
vote
1answer
341 views

Dynamic port forwarding using socat

I'm trying to replicate the functionality of ssh -D <PORT> user@machineX to tunnel all my traffic from my current machine via machineX. I do not need the ssh shell open at all, I simply wish to ...
3
votes
5answers
62 views

Securely tunnel port through intermediate host

I'm looking to route a port for VNC back to my house here. I have to jump over a single host to then hop to my actual work machine. sittinghere will be my local home machine hopper will by the ...