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

learn more… | top users | synonyms

0
votes
2answers
29 views

Script to SSH to multiple Linux Server and execute a find command [duplicate]

I need a script that can SSH to multiple servers and execute a find command to check when was the last time a file was created. I can get the fine command part, but I'm a little bit lost on how I can ...
9
votes
9answers
14k views

Automatically run commands over SSH on many servers

There is a list of IP addresses in a .txt file, ex.: 1.1.1.1 2.2.2.2 3.3.3.3 Behind every IP address there is a server, and on every server there is an sshd running on port 22. Not every server is ...
1
vote
0answers
15 views

killing tunnels for a user connected with ssh -N

I created a forward only ssh connection with the following: ssh -i id_rsa -o TCPKeepAlive=yes -o ServerAliveInterval=10 \ -N -n -R 127.0.0.12:8888:127.0.0.12:8888 fwduser@192.168.1.201 Mow, ...
0
votes
1answer
15 views

Looking for effective alternative to ssh-copy-id which fails if you do not have the private part of the key?

To my surprise, I discovered that ssh-copy-id fails if you do not have the private part of the key, making it not usable for deploying someone else key. I an looking for a reliable way to deploy ...
0
votes
0answers
10 views

When running some X prog. remotely with ssh -X, it says “libGL error: failed to load driver: r600”

OS: CentOS Linux release 7.0.1406 (Core) Kernel: 3.10.0-123.8.1.el7.x86_64 When I run xcrysden (http://www.xcrysden.org/) remotely through ssh -X, it crashes with error: "libGL error: failed to load ...
0
votes
0answers
18 views

Removed id_rsa unable to recreate passphrase

The other day I tried to make a new ssh key on my vps. For some stupid reason I removed the id_rsa file instead of just typing ssh-keygen -p When I now try to use that command it asks me for the old ...
40
votes
4answers
55k views

ssh-add complains: Could not open a connection to your authentication agent

I've been trying to get ssh-add working on a RaspberryPi running Raspbian. I can start ssh-agent, when I do it gives the following output into the terminal: ...
3
votes
3answers
473 views

How to install openssh in Crux Linux

In Crux Linux I already have installed SSH but when I use ssh-keygen, and try to use the command: ssh localhost to test SSH I get this error: # ssh localhost ssh: connect to host localhost port ...
1
vote
0answers
50 views

Can't use SSH anymore on my local machine

for some days now I'm experiencing some issues with SSH on my local machine. It's very problematic as I use the versioning software called Git to work on some projects. I'm 100 % sure the problem is ...
6
votes
3answers
18k views

X client forwarded over SSH “cannot open display: localhost:11.0”

I have enabled X forwarding on remote machine where SSH server is running: # grep -i forward /etc/ssh/sshd_config X11Forwarding yes # On local machine, I have started SSH client with -X flag ...
2
votes
2answers
43 views

Different ssh login directory from user home

So, I'm working on a remote server via ssh that I log in and out of dozens of times a day, and I'd like to have bash cd to a default directory I've chosen as soon as I login, but I don't actually want ...
1
vote
1answer
25 views

SSH message, source of a after-login greeting command

On a server previously adminstered by someone else i noticed non-standard after-login ssh message. It looks like this: In case of problems please send an email to ....@..... Disk quotas for user ...
0
votes
0answers
26 views

ssh into fedora inside virtual box over internet

I am running fedora server in a virtual box inside a windows 7 host. I can ssh into fedora from this windows 7 host. How ever, I stay out of my place most of the times with a laptop at my disposal, ...
3
votes
3answers
728 views

Get ssh server key fingerprint

Is there a way to programmatically obtain a SSH server key fingerprint without authenticating to it? I'm trying ssh -v user@host false 2>&1 | grep "Server host key", but this hangs waiting for ...
4
votes
3answers
1k views

Autocomplete server names for SSH and SCP

I have a few servers configured in ~/.ssh/config, such as alpha and beta. How might I configure Bash such that the commands ssh al<tab> and scp file.tgz al<tab> autocomplete the names of ...
0
votes
1answer
22 views

How to create user with only SSH permissions [duplicate]

I need to create a user which can SSH to a server, but can not run any commands or view anything, for the purposes of tunneling the connection without risk of revealing credentials. How do I do this? ...
4
votes
4answers
5k views

Bash Auto-Completion feature for SSHing into Different Hosts

I have big list of servers which I normally ssh to all the time. Is there any way using bash or zsh so that I can keep the list of hostname and bash auto-completion goes through the file and gives me ...
1
vote
1answer
28 views

How to install software on to multiple linux clients

Is there any free way or method for ssh that could be used to install and update linux clients for a ubuntu laptop. I do not have password less ssh but the admin password is the same for all of the ...
4
votes
3answers
10k views

Restrict FTP user to a directory

Sorry if this is an obvious question, but I don't have a lot of knowledge about this sort of thing, and I've googled for hours, nothing worked. So on a Ubuntu 11.04 server, I want to restrict a user ...
0
votes
1answer
20 views

Mosh to a specific remote shell

With ssh, I can do something like the following: ssh user@host -t /path/to/some/shell How can I automatically launch a shell on the server with mosh? I have tried with mosh user@host -ssh ...
0
votes
1answer
10 views

Connect to other devices under same AP isolated network

I am trying to debug my android application under a public wifi network. The network seemed to have AP isolation on so I can't connect to my android device using my notebook. However, both of my ...
2
votes
2answers
626 views

How can I set default settings for htop?

Occasionally, I need to check resources on several machines throughout our data-centers for consolidation recommendations and the like. I prefer htop, mostly because of the interactive feel and the ...
0
votes
3answers
968 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
12 views

How do I correctly configure Danted?

I have a debian droplet on digital ocean that I'm trying to get danted to work on. I know I have the right username and password and I want to set up a socks5 proxy with auth. Maxathon gives me a 130 ...
2
votes
1answer
1k 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 ...
0
votes
0answers
19 views

Authenticating a virtual machine against a git server

I have a CentOS 7 VM hosted on a Scientific Linux machine (Both branches are Red Hat). I'm using docker as the SW to emulate CentOS over SL. Communication between both is done through a bridge (a ...
1
vote
3answers
58 views

Send email if user accesses the server via ssh

I want to get notified if any person accesses my Debian server via ssh. So I want to send an email whenever a user logs in on my server via ssh, so I added this line at the end of /etc/profile: ...
1
vote
2answers
31 views

SSH via cert-authority

I'm trying to use SSH using signed certificates. I'm using ssh -i keys/client.key to connect to the target device. If I generate a public key from that private key (with ssh-keygen -y -f ...
1
vote
0answers
27 views

Using Rsync to SSH and Find files

Hello I am trying to use Rsync to SSH into a remote server and pull a certain type of file that has been modified within the last 24 hours. Here is what I am trying: rsync -avx --timeout=480 ...
2
votes
4answers
5k views

SSH XForwarding fails - xauth bad display name

I'm trying to setup XForwarding over ssh, but it fails. The same result happens whether I use the argument -X or -Y for ssh. The error I get. a@ASUS-N53SM:~$ ssh -X -p 6623 pinker@192.168.0.200 ...
13
votes
3answers
57k views

ssh_exchange_identification: Connection closed by remote host (not using hosts.deny)

I'm not using hosts.allow or hosts.deny, further more SSH works from my windows-machine (same laptop, different hard drive) but not my Linux machine. ssh -vvv root@host -p port gives: OpenSSH_6.6, ...
0
votes
1answer
449 views

Intermittent 'ssh_exchange_identification: Connection closed by remote host' error

While there are many questions on this site and others addressing this very issue, I haven't yet found one that seems to address what I'm experiencing. When trying to ssh a linux box from a MBpro ...
1
vote
3answers
50 views

Troubleshoot SSH connection problem

I am looking for tips on how to troubleshoot a problem with connecting to a new server via SSH. I am trying to connect using private-key authentication, where SSH uses my local private key to ...
1
vote
1answer
19 views

output log file from some time to some time via ssh

I have a access_log which size is neally 2GB. I want to analyze it from 2015:09:55 to 2015:09:57, but during this period, there have more than 500 items. So I want to output and download the ...
35
votes
3answers
12k views

How to force ssh client to use only password auth?

If I use pubkey auth from e.g.: an Ubuntu 11.04 how can I set the ssh client to use only password auth to a server? (just needed because of testing passwords on a server, where I default log in with ...
1
vote
1answer
54 views

Service network restart same as ifup and ifdown?

Can service network restart take place of ifdown and ifup? I was managing my server the other day using SSH and I changed my internal IP from DHCP to static. After editing the config file I had to ...
2
votes
1answer
958 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 ...
0
votes
1answer
32 views

UnixWare 7 fails to pass variable to Linux

I'm new to Bash and I have a problem that find difficult to solve, may be easy for some. I have a really old SCO UnixWare 7 system with no SSH only RSH available. SCO doesn't exist anymore , I ...
1
vote
1answer
414 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 ...
5
votes
2answers
197 views

Why does ssh -g say that address is already in use?

I setup an SSH connection with port forwarding that allows remote hosts to connect to the local forwarded ports like this: ssh -g -L 5115:localhost:5115 <server> The connection works fine ...
0
votes
0answers
69 views

How to give shell access within chroot environment having different home directories? [closed]

I want to give limited bash shell commands or we can say shell access to the chrooted users but after configuration users are able to do sftp only. I have also found that it is possible by providing ...
2
votes
0answers
15 views

Forwarding C-c to a remote tmux session

I have bind C-c new-window (and other similar bindings, but only C-c is giving me an issue) in my .tmux.conf. On a local tmux session, the binding works as expected, but in a remote tmux session(over ...
0
votes
1answer
381 views

ssh public key authentication not working

I had my keys set up so I can ssh between machines without having to enter a password and everything was working for a while but then, all of a sudden, I'm being prompted for a password on some ...
1
vote
3answers
161 views

Wrong number of logged in users using “w”

There was a temporary network glitch and all user terminal ssh sessions were broken. Upon logging in to the CentOS server again and running the "w" command lists a higher number of users logged in ...
0
votes
0answers
20 views

How to manually change “Host Access Control” settings?

I have a server I am managing. Is there a way to alter via SSH the settings made from WHM>Host Access Control. The reason being that after some changes to WHM, it now says "Your license could not be ...
13
votes
5answers
2k views

OS X: how to keep the computer from sleeping during a ssh session

When I ssh into a OS X computer on my network the session lasts until the OS X goes into sleep mode. Is there a way to prevent this from happening during my SSH session, apart from physically bumping ...
2
votes
1answer
416 views

Chroot gone wrong, can't ssh with user

Distribution: Scientific Linux 6.5 (Carbon), not exactly your typical brand of linux. Tried to chroot a user using these instructions for SSH and quite obviously failed, and now I can't even log in ...
5
votes
2answers
362 views

How to input a network file to ffmpeg

My problem is this. I have access to a server that hosts many video files, most of them are very large and not well compressed. I intend to make a reduced quality smaller size copy of these on my ...
0
votes
1answer
60 views

Run a command under sudo over SSH

I am accessing remote machine in Linux using Bash scripting.My code is as follows #!/bin/bash ssh -i manu_bp.pem ubuntu@54.68.67.68 <<EOF sudo -s cat ...
1
vote
1answer
31 views

How to remember ssh password with lsyncd?

I' m using lsyncd to sync a folder between local and remote machines with default.rsyncssh config. But it asks for password every time file changes. I found there' s an option password_file, but ...