Category Archives: ssh

ssh local port forwarding for testing LinkedIn

The Problem Production cluster: machines has different external IP address. This can be verified by running “curl http://ipecho.net/plain;echo” script. https://api.linkedin.com works for some machine while blocking for others. How to reproduce the issue from a dev machine that has SSH … Continue reading

Posted in ssh | Leave a comment

ssh local and remote port forwarding for TCP

http://www.symantec.com/connect/articles/ssh-port-forwarding Remote forwarding example: http://www.saltycrane.com/blog/2013/02/how-expose-flask-local-development-server-public-using-ssh-remote-port-forwarding/

Posted in ssh | Tagged | Leave a comment

ssh tricks

ssh allocate a pseudo tty: ssh -t <ssh_alias>  htop ssh with sudo password:  http://www.cyberciti.biz/faq/linux-unix-bsd-sudo-sorry-you-must-haveattytorun/  ssh -t ssh_alias ” echo secret | sudo -S dmidecode” ssh-keygen -lf /etc/ssh/ssh_host_rsa_key : print the SSH server fingerprint pssh (parallel-ssh) is good for non interactive … Continue reading

Posted in ssh | Tagged | Leave a comment

batch ssh-copy-id

aliases=”${1:-/dev/null}” while read -r alias do echo $alias sshpass -p ‘secret’ ssh-copy-id $alias done < $aliases

Posted in ssh | Tagged | Leave a comment