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

learn more… | top users | synonyms

1
vote
3answers
435 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
0answers
1k views

How to run ssh -t user@remote 'sudo nohup bash -c “comand”' in background

I want to run a script on a remote host with sudo privilege, someone suggests that I should use nohup and ssh -t, like the following command: The script ls; sleep 10; echo finish is crafted here to ...
2
votes
1answer
221 views

Is it possible to x-forward windows apps to linux if windows PC running Xming?

I have been digging around looking for an answer to my question but have no been able to come up with anything. I know that xming server allows you to transparently run linux applications on windows ...
2
votes
3answers
232 views

Is there a way to maintain ssh-agent connectivity in different screens?

Whenever I use ssh-agent for passwordless logins it doesn't work across different logins and screen sessions, even if they are concurrent. I suspect it uses some shell variables that don't work ...
2
votes
3answers
304 views

Log in with specific shell at terminal login

If I log in to a system over ssh, I can use the default shell with a simple ssh user@host, or specify something like ssh user@host 'bash --norc --noprofile' or ssh user@host ksh. Is it possible to ...
2
votes
3answers
134 views

Can I bridge “backwards” from an ssh connection to my local emacs-server?

I'd very much like to log in to a remote machine with ssh and via the $EDITOR environment variable (or something similar) be able to edit in my local Emacs. In this case, specifically for when I log ...
1
vote
1answer
222 views

Why is sshd looking at a non-existent public key file?

In an effort to get SSH keys working I'm tailing the sshd authorization log and I see these lines: debug1: test whether pkalg/pkblob are acceptable debug1: temporarily_use_uid: 10144/10029 (e=0/0) ...
11
votes
2answers
8k views

What difference between openssh key and putty key?

I've found ssh-keygen ("ssh" package) comand produce another keys that puttygen command ("putty" package). If I create public and private keys with ssh-keygen some ssh-servers can not accept my keys. ...
2
votes
1answer
571 views

Cannot open GUI after ssh -X and chroot

I ssh ( with -X option ) to another computer then I I do a chroot. I then encounter problems running X11 apps. As one example, after the ssh I would run emacs and it would open a new window as a X11 ...
0
votes
1answer
128 views

Indirect SCP connection

I use ssh and scp to connect to a remote server. Due to a ip/proxy limitation on the remote server, I have to connect first to another server. For example, if I want to connect to "SERVER-A", I have ...
0
votes
0answers
70 views

PBX randomly loses network connectivity and restores itself

I'm using a QBX appliance, which is just a microATX desktop system with FreePBX connecting to asterisk and some other slapped together stuff running on CentOS 5.4. It's horribly out of date (which I ...
2
votes
4answers
8k views

SSH is suddenly not working anymore: “Write Failed:Broken Pipe”

I use a macbook pro at home and regularly ssh into the machines at my lab. For the past 3-4 days however, whenever I SSH into the machine in the lab, I get a Write Failed:Broken Pipe error, hardly ...
1
vote
3answers
252 views

Upgrade MySQL 5.0.88 to 5.1.69

I am upgrading my MySQL installation on a Fedora 10 (and 14) box (in test first.) I have made a system image (it is a VM) and have downloaded MySQL Server Community 5.1.69-1 from the MySQL site. Once ...
2
votes
1answer
89 views

How can I use ForwardAgent with keychain, or detect a new login?

My scenario: I have Server A at home, and Server B at my parents house. I also have Laptop A and Laptop B at home. I do all sorts of strange ssh hops - I might connect Laptop A -> Server A -> ...
0
votes
1answer
393 views

Counting files on a remote server with ssh and an expect script

Below is my script to take count for files which are present in remote server. But it is not working. Please help me. #!/usr/bin/expect spawn ssh sduser@172.0.0.2 expect "123" send "123" interact ...
2
votes
2answers
197 views

Automatically unlock keys on a remote host accessed via SSH

On my local PC my ssh keys are automatically unlocked on login. From there I access via ssh (with key authentication) a server that have stored the same keys I have in the client. I'd like to unlock ...
3
votes
1answer
302 views

How can I silence ssh-agent?

I have a script like this one at my .bashrc file at the mysuer home: eval `ssh-agent` ssh-add /path/to/my/key The problem is I have this output when I log with the user mysuer (su - myuser): Agent ...
3
votes
2answers
4k views

SSH login via IPv6 successfull while using IPv4 to the same host yields “Permission denied”

I'm currently stumped by a strange problem… I have a dual stack host to which I want to SSH. If I connect via IPv6 everything works like expected datenwolf@foo ~/ > ssh -6 bar.example.com ...
0
votes
0answers
32 views

SSH remote command execution: get output before execution ends [duplicate]

Consider the following simple C program test.c: #include <stdio.h> int main(void){ printf("foo\n"); sleep(5); printf("bar\n"); return 0; } The program prints ...
3
votes
2answers
77 views

Specify script to run with SSH upon login

I would like to know if there is a way to specify what script to run (on the remote machine) at login. I'm logging into a Debian box with key-pair authentiation (no password needed). The script ...
5
votes
1answer
2k views

How many users does Linux support being logged in at the same time via SSH?

I know Linux supports multiple users being logged in at the same time. But what's the maximum number of users that can be logged into Linux at the same time? I see there are there are 69 tty files ...
6
votes
2answers
588 views

Special character '#' in Perl SSH command

I try to send command using SSH in my perl script with # but it gets truncated right at # Example: Input text is : $message = "Product ID # STK000134" The SSH command is : $execute=`ssh -q ...
1
vote
1answer
137 views

Why does rsync look for DSA instead of RSA key when run from cron job?

I want to backup files from a server to my local computer using rsync. I can only log-in to the server with an RSA ssh key. I have stored the passphrase to the key in Seahorse Passwords and Keys, ...
0
votes
2answers
269 views

SSH connections not accepted after configuring NFS?

I have a couple of servers in a VPC in Amazon EC2. One of them acts as a NFS server, and one of them as a client. I recently noticed a problem in the client that after a reboot, it would reject all ...
1
vote
0answers
2k views

Using sshpass, return code (exit status) differs for reasons unknown using valid commands

There are a few things going on here but I think ultimately, either CLish or SSH is returning an exit code that is messing up my work flow. I'm attempting to connect to a remote machine (CLish shell) ...
2
votes
1answer
251 views

ssh-add -D doesn't erase stored keys from the ssh-agent

How come this happens?: stan@tcpc:~/.ssh$ ssh-add -l 8192 e0:45:5e:cc:45:3e:17:2b:a6:54:6f:8d:53:1b:j2:e3 github (RSA) 2048 25:41:53:a6:45:5d:ac:eb:5c:45:f8:ce:42:a9:he:aa BITBUCKET (RSA) ...
12
votes
5answers
690 views

what's the purpose of ssh-agent?

I've read the official definition: ssh-agent is a program to hold private keys used for public key authentication (RSA, DSA, ECDSA). The idea is that ssh-agent is started in the beginning of an ...
1
vote
1answer
279 views

Why ssh -nq -t can't see my environment variable?

I am executing a command on remote machine with -t flag ( to prevent the command from 'blocking' ) the prompt (somehow it works that way). So I am using ssh -nq -t root@ip but with this, the script ...
0
votes
1answer
177 views

I'm able to remotely ssh into Cygwin on XP, but it warns “Could not chdir to home directory” and my /bin is almost empty

I've made a firewall exception, opened ports 22 through 443 to the correct internal IP (I think), and am able to log in using my external IP, but it's like I have very limited view access to almost ...
2
votes
1answer
127 views

SSH lets me login with a password even though I set “PasswordAuthentication no”

I'm trying to turn off password authentication for SSH after setting up public key access. I have these set in my /etc/ssh/sshd_config file: PermitRootLogin without-password PasswordAuthentication no ...
7
votes
1answer
1k views

Forward all ports SSH

I have a question about SSH/Port forwarding. I haven't found the solution anywhere and don't know if there is any. I have a server behind my NAT box at home. I have port forwarding from my NAT box to ...
1
vote
1answer
274 views

Having the 'id_rsa.pub' file in my dotfiles public repo securely

So this is something that I'm wondering, how can I have this file in my dotfiles GitHub repo? I'm sick and tired of having to generate a new SSH key every time I'm on a new computer or re-install my ...
0
votes
1answer
78 views

ssh private key stops accepting my passphrase

When booting my laptop today I found that ssh (openssh) simply refuses to accept my passphrase when reading my private key. My only idea of how that could've happened is if the HDD has somehow ...
2
votes
1answer
1k views

Getting no tty present and no askpass program specified when using git over ssh

I'm trying to push a git commit from my laptop to my server but keep getting the following error message: remote: sudo: no tty present and no askpass program specified To ...
1
vote
2answers
505 views

How to troubleshoot failed X11 forwarding with ssh?

When I try to establish an X11-forwarding connection to myserver, I get the following error: % ssh -X myserver xlogo X11 connection rejected because of wrong authentication. X11 connection rejected ...
0
votes
2answers
65 views

ssh with identical machines

I have two identical beaglebones that I'm working with. They have the same hostname and originally had the same IP, though I changed one to see if that made a difference. They're going to be deployed ...
0
votes
2answers
39 views

can't update with this error messg

I got this message: not enough free disk space.... The upgrade needs a total of 31.8 M free space on disk '/boot'. Please free at least an additional 31.8 M of disk space on '/boot'. Empty ...
2
votes
3answers
4k views

Use socks proxy for commands in terminal

I connect to a remote ssh server by running this command: ssh -D 12345 bob@myserver.com This creates a socks proxy that I can use with Firefox to bypass censorship in my country. However, I can't ...
1
vote
1answer
1k views

Passwordless ssh on archlinux (after ssh-copy-id still prompts for password) [duplicate]

On ubuntu/mint, all I need to do for passwordless ssh login is: ssh-keygen -t rsa # on both pc ssh-copy-id targetpc ssh targetpc # does not prompt from password anymore and that's all.. I do the ...
2
votes
2answers
194 views

End process from another SSH window

I forgot to use screen and I have a task that has been running for quite some time, and I do not want to lose the saved data. Basically Ctrlc will end the task and save the data if I am on the same ...
3
votes
2answers
215 views

Grant ssh access for single session

I wonder if there is a tool/modified ssh-server/ssh option which enables me to grant ssh access for a single session to a given user. What I want to avoid is creating a user account and password for ...
0
votes
1answer
104 views

Keep the ssh session

I am using Macbook developing a client application. I want to access server logs, so I opened a shell terminal and established a ssh connection to the server and access the log file there by ...
0
votes
2answers
167 views

DenyHosts and no-ip.com

I recently installed DenyHosts and after a few remote logins I noticed that sshd: 8.23.224.110 had been added to the host.deny file after /var/log/auth.log showed a few sshd: Did not receive ...
0
votes
2answers
567 views

scp hangs on SSH2_MSG_SERVICE_ACCEPT received

I frequently scp my file to remote host. But suddenly it started taking more than 30 seconds to copy 20kb file.It used to take not more than half a second. After referring to some blog I appended ...
4
votes
1answer
283 views

preventing the screen from being cleared when exiting an ssh session

I have rdist set up to push out some of my dot files to all the remote machines that I need to ssh into. I also have zsh as my default shell on all of those machines. When I ssh into a machine and ...
1
vote
1answer
359 views

SSH disconnects when screen locked with vlock

I'm using tmux + PuTTY to get all the UNIX goodness I need when using Windows. I have the following settings in my .tmux.conf: set-option -g lock-command vlock set-option -g lock-after-time 1800 As ...
2
votes
1answer
245 views

Restrict two way SSH and Apache authentication to non-local networks

I am using Google's open-source PAM module for two-way authentication for SSH logins and certain Apache directives. It works great, however I would like to use this only when trying to log in from an ...
0
votes
1answer
1k views

Unable to login to my server using ssh

Yesterday I was migrating to my new server, needed to use rsync, I created a RSA key, so that rsync could connect, I saw an error that says add to trusted key in location x I didn't have that location ...
0
votes
2answers
104 views

Transfering files using ssh

I've found the following command pretty convenient for transferring files to servers I have ssh access to: cat myfile.txt | ssh my.host.edu "cat > myfile.txt" Is there a similarly convenient ...
0
votes
1answer
578 views

non root ssh keys help

I'm having issues setting up a different CentOS account with its own pair of SSH keys. I have created the required files but when connecting with Putty it says Connection refused, here's the putty ...