SSH (Secure SHell) is a protocol for running commands on a remote computer.
0
votes
1answer
14 views
Locale not being set on initial login on Raspbian/Debian
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
48 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 ...
2
votes
0answers
55 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
36 views
Bash Script Display Remote Screen Session to User
I'm kind of new to bash scripting and I'm having trouble figuring out how to accomplish this.
I'm working on a script that is designed to backup and manage a java application that runs within a ...
4
votes
1answer
58 views
Remotely turn off display output?
I'm using x11vnc and SSH to tunnel VNC remotely to my local machine.
One of the interesting side-effects of this is that as I use my work computer from home, my coworkers will see me moving around ...
3
votes
5answers
40 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 ...
0
votes
0answers
43 views
Cannot open GUI's via SSH connection? [duplicate]
I've just connected to a Linux terminal using an ssh client. I'm running Linux on both desktops, but cannot open PDFs, IDE, or other graphics from the ssh client.
How can I fix this?
1
vote
1answer
27 views
SSH slow after configuring TCP Wrappers
We have SSH open on one of our production servers leaving it prone to various brute force attacks to break in. I reduced the attempts by changing the default port from 22.
I want to further harden ...
8
votes
1answer
248 views
Using SSH to connect to a new server without storing the host keys in the $HOME/.ssh/known_host file
I get the following output if I run the following command:
-bash-3.2$ ssh -o "StrictHostKeyChecking no" 192.168.1.77
Warning: Permanently added '192.168.1.77' (RSA) to the list of known hosts.
Last ...
3
votes
0answers
47 views
SCP Lost Connection
I can successfully connect to my server via ssh but when trying to run the scp command I get a connection time out.
$ scp ~/.ssh/id_rsa.pub [email protected]:id_rsa.pub
ssh: connect to host ...
0
votes
1answer
31 views
Backup of data from Linux PC [duplicate]
I have Linux PC, for which monitor is not working. But I am able to log in through SSH. I want to take a backup of all the directories from this PC. Instead of changing directories one by one and ...
2
votes
3answers
47 views
force ssh to change dir after login based on config
Is there any way to force ssh to change it's working dir in ~/.ssh/config or by using other configuration files?
I have a lot of servers with different environments. Each environment is installed in ...
2
votes
1answer
41 views
SSH'd into a computer, uptime / who / users report 0 users?
I'm ssh'd into a server. Why doesn't the server report it?
# uptime
21:54:28 up 13 days, 3:47, 0 users, load average: 1.18, 1.11, 1.13
# users
# who
I'm not really sure I understand it ...
2
votes
0answers
37 views
SSH AuthorizedKeysCommand and SELinux
I'm trying to use the SSH AuthorizedKeysCommand in a CentOS 6.5 machine, but I'm encountering an SELinux error. When I switch SELinux to permissive mode - using setenforce 0 - it works, but when I ...
4
votes
1answer
48 views
Executing commands with ssh and shell script using variables on a remote machine
I'd like to execute a command and script located on a remote machine with a script on a local machine. I know it's possible to execute these kind of commands with ssh, so I made:
#!/bin/bash
ssh ...
5
votes
1answer
61 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 ...
4
votes
2answers
57 views
777'd some files. How do I repair SSH?
So I'm messing around on a test server and accidentally ran the following (which resulting in SSH breaking):
# chmod -R 777 /var
Because it's a test server, I'd rather not re-install right now, I ...
2
votes
1answer
25 views
What commands does git use when communicating via ssh?
Using command="" in authorized_keys, I can restrict the commands that can be run by a particular key.
What commands do I need to allow in order to have a functioning git remote?
From the Pro Git ...
3
votes
2answers
108 views
ssh-add in not persistent between reboots
I add a ssh key to the agent by
$ ssh-add ~/.ssh/id_rsa_mac
Identity added: /Users/alex/.ssh/id_rsa_mac (/Users/alex/.ssh/id_rsa_mac)
After reboot I don't have this key added anymore:
$ ssh-add -l
...
0
votes
0answers
30 views
Unable to SSH into Puppy Linux, even though SSHD is running
I installed OpenSSH client and server on my Puppy Linux computer. That computer is behind a router. I tried to ssh into it over the internet (outside the router) but it times out. Also doesn't work if ...
1
vote
0answers
13 views
xtightvnc through ssh gateway — connection refused
Following setup:
homepc -> gateway -> workpc
workpc:~$ tightvncserver :12
homepc:~$ ssh -N gatewayuser@gateway -L 1212:workpc:5912
Now I try to connect via
homepc:~$ xtightvncviewer ...
1
vote
1answer
74 views
SSH: Network is unreachable (caused by router)
I've searched solution in Google for 3 days, when I decided to write here. I have a router, so in my house is WLAN. I use laptop when I stay at home. In another city in my office I have a second ...
1
vote
2answers
38 views
Using exec in find over ssh from shell script
So, I am attempting to execute the following from within a shell script;
ssh -q $CUR_HOST "cd $LOGS_DIR; echo cd $LOGS_DIR; find . -name *.log -mmin +1440 -exec gzip {} \; exit"
When this runs, it ...
0
votes
2answers
57 views
Locked out of Ubuntu machine
I recently made changes to my EC2/Ubuntu instances by installing OpenSSH, before I was able to SSH just fine, however now I'm getting this error:
ssh: connect to host shopious.com port 22: Connection ...
1
vote
5answers
78 views
How to copy a file from a remote network to the local desktop
So I used SSH to remotely login to another computer on a network. I have many files that I would like to copy over to my local desktop.
I am trying to follow this How-to :
However, I think one ...
0
votes
0answers
33 views
SSH can't use internet when multiple interfaces present in route
I'm trying to make SSH tunnel connection on any possible interface (which has internet connection).
I'm currently using ppp0 and eth0 interfaces. ppp0 always has internet and reinitialized if ...
-3
votes
1answer
36 views
Authentication failed [closed]
You have no controlling tty and no DISPLAY. Cannot read passphrase.
warning: Authentication failed.
Disconnected (local); authentication cancelled by user (Authentication cancelled by user.).
...
8
votes
2answers
95 views
Weird SSH issue, ssh works with -t but freezes without it
When I ssh into one of my servers, it seems to log in, but then hangs before giving me the prompt (message debug2: shell request accepted on channel 0 is the last log entry).
Though the odd thing is ...
2
votes
1answer
73 views
Why do I need to insert the passphrase for an RSA key on a remote host after SSH?
From host B I can SSH various other hosts (C, D) without using any password as I put the public key in the correspondent authorized_keys files (in hosts C and D).
From host A I can SSH host B (via ...
2
votes
0answers
35 views
Remote script cleaning up
I run a remote script using ssh:
local script:
local_command
ssh -p 222 user@server 'sh -s' < ./remote_run.sh
remote script:
some_command &
sleep 10000
trap 'echo exiting' SIGINT SIGTERM ...
0
votes
0answers
29 views
Root able to login but non root users are denied - PAM
One of our servers is not letting non-root users login, but root can login without any issues.
The following are the messages from /var/log/secure:
Jun 24 18:08:43 jonnserver sshd[14470]: debug1: ...
1
vote
1answer
48 views
login scenario and root ssh access block
I'm kinda new to linux so bear with me. I followed a tutorial on how to grant root access to other users and what I did was, in /etc/passwd/ I changed the other users' uid/gid to 0:0.
The problem is ...
0
votes
2answers
63 views
why won't x11 display work through ssh login?
I have logged in to a remote server and am trying to display an x application(e.g. firefox). but an error message appears. the below are my attempts to open firefox
Black@Black-PC ~
$ ssh -X ...
1
vote
1answer
83 views
Linux can't recognize the right password when ssh'ing?
I've created a local port forwarding and I was trying to ssh into my own port.
During the process, I found that my own Linux won't recognize me even when I have the right password
...
1
vote
3answers
319 views
what does this ssh command mean?
Its an answer I got from questioning about port forwarding but I'm not sure what it means..
$ ssh lab_desktop -L 2200:lab_server:22 -vvv
my wild guess:
first get connect to lab_desktop
and then ...
2
votes
1answer
49 views
how to connect ssh 'with' specified port?
I know how to connect 'to' a certain port when ssh'ing.
ssh user@remotehostip -p XXX
but is there a way to establish a ssh 'with' a certain port?
I mean, is there a way to specify the port which ...
3
votes
2answers
68 views
Variable assigned inside ssh command doesn't return proper value
I'm executing the below command in the ssh part of my script. The command is meant to cut the file size from ls option and storing it to a variable. Then print the variable:
echo "Enter srouce file";
...
2
votes
1answer
23 views
how to 'forward' x display data?
this is my situation: there are three computers
lab server (CentOS)
lab personal computer(window s7)
personal laptop(ubuntu)
since the lab server only allowed ip address of my desktop at the lab, ...
0
votes
0answers
18 views
Running “gnome-session” or “gnome-panel” over SSH via X yields black bar
I can VNC fine to my machine. But VNC is slow, and to try something else, I wanted to use gnome-session or gnome-panel over SSH via X. But it simply gives me a black bar across the whole screen.
No ...
0
votes
2answers
27 views
How to perform a dry-run using rsync over ssh?
I got these errors while trying to perform a dry-run with option -n over ssh on a remote server:
# rsync --progress --delete -avhHen ssh /etc/yum [email protected]:/etc
rsync: Failed to exec n: No ...
1
vote
1answer
27 views
What is the correct form of the HostnameSuffixes SSH keyword?
I came across an SSH configuration setting that I've never seen before while following a discussion on an OpenSSH developers' mailing list archive. The particular setting is this:
Host *
...
1
vote
0answers
58 views
SSH & ForwardX11 vs ForwardX11Trusted --> beyond my grasp
I am on Ubuntu 14.04 and trying to get my head around ForwardX11 vs ForwardX11Trusted.
My default ssh_config contains the following lines:
# ForwardX11 no
# ForwardX11Trusted yes
Further, man ...
1
vote
2answers
31 views
Is it necessary to disown a process for it to continue running after disconnecting?
Would someone be kind enough to explain if & why disown is necessary if you wish to keep a job running even after you disconnect.
I ask because every site I have visited says to use disown and bg ...
7
votes
4answers
183 views
Stopping output from a program run in SSH session NOW
Problem
I execute command that outputs LOTS of information through SSH. For example, I foolishly add debug information inside a loop that executes million times, or just run cat /dev/urandom for ...
1
vote
1answer
15 views
How do I run a sock proxy via ssh on a non-standard port?
I am running into a bit of trouble accessing a web application running on port 9293 on a remote server only accessible via ssh on port 5634. I've configured FoxyProxy to route all traffic meeting the ...
0
votes
1answer
50 views
How do I log out/disconnect from SSH after starting a process with output to keep it running? [duplicate]
I ran a script from the command line today (php, not sure that matters) which has output I wanted to watch but I had to go home before it finished and I couldn't figure out how to exit without killing ...
2
votes
1answer
52 views
SSH Command behaves differently in Expect Script
I'm using this command on Server1
~# ssh root@Server2 /root/.ssh/id_rsa.pub >> /root/.ssh/authorized_keys
to append the contents of Server2's id_rsa.pub to the authorized_keys of Server1.
It ...
1
vote
1answer
54 views
ssh ubuntu to android : No route to host
I am trying to log into my android phone (running sshdroid), using my laptop (ubuntu 12.04). I am on a university sub-network (on wifi), and so is my phone.
I tried the following command:
ssh ...
3
votes
1answer
36 views
command line method or programtically add ssh key to github.com user account
Is there a way to identify with a username and password to github.com servers for the purpose of adding an ssh key to the github user account? So far everything I've read suggests that a users ssh key ...
1
vote
1answer
38 views
SELinux preventing ssh via public key
I have user $USER which is a system user account with an authorized users file. When I have SELinux enabled I am unable to ssh into the server using the public key. If I setenabled 0, $USER can now ...