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

learn more… | top users | synonyms

1
vote
1answer
74 views

Allow the restricted rsync (rrsync) script for arbitrary directories with authorized_keys

Automating Backups I would like to implement a backup solution with copies data from various directories from a Web server (WebServer) to a local backup server (BackupServer). The backup should run ...
1
vote
2answers
71 views

How can a command in a pipe read from a keyboard? [duplicate]

I randomly tried to execute the following command in bash1 cat /some/file | ssh user@machine 'cat >/destination/file There are no keys installed on the remote machine, so the only way to ...
3
votes
1answer
35 views

Remove any ssh-keygen commands from init scripts

I'm running Ubuntu 14.04 64 bit server. I'm following this guide: Secure Secure Shell https://stribika.github.io/2015/01/04/secure-secure-shell.html It includes the instruction: remove any ssh-...
0
votes
0answers
13 views

Bash script not passing variable through ssh [duplicate]

I'm trying to write a script that will ssh into multiple servers and echo the line user_pref("plugin.state.java",2) into every user's firefox pref.js file. I keep getting the error bash: /home//....
0
votes
0answers
96 views

Running a batch script remotely using rdesktop

I have a setup that implies calling rdesktop on a remote machine which is accessed through ssh: user@192.168.1.110:~$ ssh user@192.168.1.120 -X and then running rdesktop as: user@192.168.1.120:~$ ...
1
vote
2answers
57 views

Execute inline command remote server with ssh

I'm trying to create a single script that connects to a remote server and executes an update, but I want to make sure no one is using the machine at the time so I execute a "ps" command to see the ...
0
votes
2answers
105 views

How to access server without IP-address

I have a centos server that was previously on my company's network using a static IP address, but it has since been blocked/firewalled on the network such that I'm not even able to ping it. I was told ...
0
votes
1answer
51 views

SSH into another VM via Perl / Sh script failing. Works manually

I want to run a Perl CGI script (a_web_page.cgi) from my dev box .1.20 that runs a bash script from the same folder (host_script.sh). This script then runs a SSH command to another server 1.10 that ...
0
votes
0answers
21 views

How do I add a vim configuration to a user who is restricted to a specific directory?

So basically, I have created a user that only has access to a specific folder with: useradd --home /some/dir username Now what I would like to do is add my vim configuration to this user's "home" ...
0
votes
1answer
47 views

Setting up aliases with interactive ssh session [duplicate]

I need to keep ssh'ing into many-different Linux boxes (Ubuntu mostly) and every time I miss my basic aliases. Is there a way to setup aliases etc while opening an interactive ssh a machine without ...
0
votes
0answers
17 views

How to FG a Background Process without jobs, fg, etc [duplicate]

I am SSH'ed into a Ubuntu Server. I started a process and closed the terminal window, reconnected to the server. Using TOP I can see the process is still running smoothly, but I did not assign a job ...
0
votes
1answer
43 views

How to execute a script on SSH Login or device bootup/shutdown? [duplicate]

I have a raspberry pi, which is online and connectable by SSH. What I want to do is create hooks for the following states: When the device starts Before the device shuts down When an SSH login ...
2
votes
1answer
59 views

Set ports for ssh to connect to remote Raspberry Pi

My Linux laptop is on Verizon HomeFusion internet service and I am trying to configure so that I can SSH to a remote Raspberry Pi (through its router) that is using the Virgin mobile service. Seems ...
0
votes
1answer
67 views

problem editing utf8 text file with vim

I have a problem editing a html file on a server via vim. The file is utf-8 encoded. While editing with vim (v7.3, no plugins active) I can see umlauts and editing and saving a line before the umlaut ...
3
votes
1answer
105 views

SSH connection through SSH tunnel keeps closing

I have a PI at home that creates an SSH tunnel to my VPS with autossh so I can access it from my VPS. When I log in to my PI from my VPS the connection keeps closing (which makes it unusable). For ...
4
votes
0answers
53 views

Why does connecting using an ssh key fail with one host name but work with others? [closed]

Trying to use an ssh key to a server which has different host names works with some host names, but not with others? Is there some reason why ssh would work that way? E.g. say hostname1.com and ...
0
votes
0answers
24 views

Unable to ssh to virtual machine, yet sshd running and firewall port is open

I'm testing a VM provider's service, and I'm unable to ssh to the VMs I created yesterday. I am able to get in via their web interface shell. The connection just times out: ssh: connect to host xx.xx....
1
vote
1answer
40 views

How to auto-unlock SSH keyring upon login

Situation: I am on Linux Mint 17.3 and have on the station auto-login enabled. I have an SSH key in gnome-keyring. Objective: I would like the SSH keyring not to ask me for password. I am aware it ...
0
votes
0answers
18 views

save state and detach from an xming session and attach to the same session later

Welcome to the Xming X Server Vendor: Colin Harrison Release: 6.9.0.31 FreeType2: 2.3.4 and Linux 3.8.13-118.4.2.el6uek.x86_64 #2 SMP Tue Mar 22 20:47:10 PDT 2016 x86_64 x86_64 x86_64 ...
0
votes
1answer
35 views

Invoke rsync with specific defaults for current folder?

I have a local folder which I want to synchronize with a remote folder through SSH, and I'd like to do it through rsync. I would always call rsync with the same arguments, and same source and ...
1
vote
2answers
85 views

Connect to Linux machine behind a firewall

I am looking for way to connect to Linux machine without connecting to it using SSH, Telnet or something similar. The Linux machine is behind a router and I don't have access to it. So opening / ...
0
votes
1answer
53 views

`ssh` fails to reach destination

I am trying to ssh to another machine in my lab using the IP address. The IP address is 137.84.4.211 and let's say the host name is MyName. My IP address is 137.82.81.10. I don't know if this mean two ...
1
vote
1answer
28 views

How to recover a process GUI after broken pipe

I started a process with GUI from the command line in a remote computer using ssh -X. Knowing it would take a long time to run it, I left it in the background and disowned. As I feared, I had ...
0
votes
1answer
65 views

SSH client does not offer public key to SSH server

I have two non-root users in one Linux server. If I make a SSH connection(key-based authentication) to one particular SSH server under first user, then it succeeds: /* debug messages removed for ...
1
vote
1answer
83 views

SSH publickey permission denied (Google Cloud Platform)

We run a small handful of Debian servers on Google Cloud Platform. New servers we setup, we're able to add SSH keys at the point of creation and access the machines via SSH without a problem. Older ...
0
votes
1answer
478 views

SFTP, SSH Couldn't read packet: Connection reset by peer [duplicate]

My sftp -v to host returns, Connecting to xxx.xx.xx.xx... OpenSSH_3.9p1, OpenSSL 0.9.7a Feb 19 2003 debug1: Reading configuration data /etc/ssh/ssh_config debug1: Applying options for * debug1: ...
0
votes
1answer
36 views

Conditions sent over ssh are performed locally, not remotely [duplicate]

So I am trying to do something like this: ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i \ /home/backupboy/.ssh/id_rsa user@server.com \ "[[ $(ls -1 /mnt/dir | wc -l) -gt 4 ]]...
1
vote
1answer
50 views

How to get `yum list` output to stay on one line when getting output via remote ssh command?

When I SSH to a machine with ssh machine and run yum list it outputs everything that's installed as expected, and importantly every item is on one line like so: xz-devel.i386 ...
2
votes
2answers
54 views

Add keys to ssh-agent

I have three SSH key pairs that I want to have added to the SSH agent every time I start a shell. After restarting I always have to manually add them again by using ssh-add <path_to_private_key>....
2
votes
1answer
40 views

Send my private key through the ssh session only

My scenario: localhost: contains my private key serverA: contains my public key serverB: contains my public key I login to serverA and perform some operations, which involve copying some files from ...
0
votes
1answer
61 views

How to run a command on remote host from a service?

I have a service in '/etc/init.d'. In that service, I run a command on a remote machine using ssh as a user. Currently I do this in the following way: sudo -u user bash -c "ssh user@172.21.6.70 '...
0
votes
1answer
65 views

Able to SSH from Windows, but not through Kali

I was trying to connect my Raspberry Pi 3 Model B over Ethernet to my netbook(running Kali from a bootable USB). After a lot of struggle that the RPi automatically assigned an IP to itself when ...
3
votes
1answer
38 views

Check presence of a hostname under custom port in known_hosts

I need to add a check if the hostname is already present in the known_hosts. Normally I would do something like that: ssh-keygen -H -F hostname However, that does not seem to work for me in this ...
0
votes
0answers
24 views

SSH Connection to a folder only [duplicate]

I want to provide SSH connection to my developers to connect to the server. But I want the connection to be limited a folder and its subfolders and files only. How can I do this?
0
votes
1answer
24 views

Proper way of creating new accounts in passwordless systems [closed]

What is the proper way of delivering credentials in passwordless ssh systems (linux)? By passwordless I mean login using only SSH keys. Should I generate pair of ssh keys and deliver it to new user, ...
1
vote
1answer
98 views

Specifying SSH KexAlgorithms works at CLI but not via ssh_config [duplicate]

By default, my SSH client disallows the use of the diffie-hellman-group-exchange-sha256 key exchange algorithm. However, I need to access a server on 10.0.0.1 that requires the use of that algorithm. ...
-1
votes
1answer
39 views

ssh throws bad host name and no output

I have script that goes in each server and gets output. EXCECUTE_CMD="$(find /tmp/customize -name 'customize.*.log' -mtime -1 -type f -print | wc -l)" for server in $SERVERS do ssh -o ...
5
votes
2answers
162 views

options override for openssh client configuration

Since I want to protect my ssh connections, I set some global cipher suite options to restrict set of used algorithms. But recently I've encountered a server which doesn't support some of those ...
2
votes
0answers
60 views

zsh theme doesn't work on a remote server [closed]

Here is a screenshot from the author of a theme: And this is what I have: What am I doing wrong?
0
votes
1answer
34 views

Is there a command-line application that combines SSH and SFTP? [duplicate]

When I'm working on some remote host via SSH, I often need to upload or download files. With my current setup, I need to switch to another terminal and conjure up rsync or sftp, which can be a pain ...
1
vote
1answer
61 views

Start a python script in `screen` on boot?

I want to be able to start a python script when I boot, but I want to be able to see lines which have been printed during the program. I have been able to put the line "sudo python /path/to/file.py" ...
1
vote
1answer
72 views

How to show and operate a remote Linux desktop when SSH or any other remote service is unavailable? [closed]

The situation is as follows. On Monday, I need to showcase a program that needs the set-up development environment and hardware on my home system, at the university. The ISP are misbehaving and won't ...
0
votes
2answers
45 views

Extracting a certain folder from a tarball - how do I tell it where to put the file once extracted?

I've looked around at multiple sources for this question and I know how to extract the file, but neither source told me how to state where to put the folder once it has been extracted. I tried this: ...
-1
votes
1answer
69 views

Redhat Linux Server : Plone installation

Unable to install any package using apt-get installer it shows sudo: apt-get: command not found -How to install apt-get package over server ? -I am trying to install Plone over my server so by ...
0
votes
1answer
30 views

Excluding files whilst using tar to zip site contents not working [closed]

I'm trying to zip the contents of a site using tar and exclude a bunch of folders and error_log files but it doesn't seem to be working, when it's processing I still see many of the excluded files ...
1
vote
2answers
62 views

Trying to run rsync between two remote servers via reverse port forwarding with ssh key

I'm trying to run an rsync between two servers. I'm basing things off of this post: How to rsync files between two remotes? What I find missing is how to facilitate the rsync (via ssh) when a key (...
1
vote
1answer
144 views

SSH access asking for password in local network but public

I have a problem when ssh to another server. I created ssh-key and copied it to other server. -bash-4.2$ whoami postgres -bash-4.2$ ssh-keygen Generating public/private rsa key pair. Enter file in ...
0
votes
0answers
121 views

SFTP connection using public key (without password) not working

I need to provide sftp access to a client to my ftp server and this is working fine. For them to access our server without using password - we have followed the below steps on our server. Created ...
0
votes
0answers
26 views

Email user temporary code access code when using ssh

I am looking for a way to create my own two factor authentication for ssh. After the user enters the correct login info I would like the terminal to send an email to the user that contains a code ...
3
votes
1answer
55 views

What configuration exists in CentOS but not in Ubuntu, which shows user@hostname for remote terminal sessions?

We have a standard "basic server" install of CentOS 6.7 for our servers, and Ubuntu 14.04 for our desktops. From my Ubuntu desktop, when I ssh into a remote server (ie: ssh into a CentOS instance), ...