How do diff over ssh?

You can do it with Bash’s process substitution: diff foo <(ssh myServer ‘cat foo’) Or, if both are on remote servers: diff <(ssh myServer1 ‘cat foo’) <(ssh myServer2 ‘cat foo’)

How do I change my private key passphrase?

To change the passphrase on your default key: $ ssh-keygen -p If you need to specify a key, pass the -f option: $ ssh-keygen -p -f ~/.ssh/id_dsa then provide your old and new passphrase (twice) at the prompts. (Use ~/.ssh/id_rsa if you have an RSA key.) More details from man ssh-keygen: […] SYNOPSIS ssh-keygen [-q] … Read more

ssh returns “Bad owner or permissions on ~/.ssh/config”

I needed to have rw for user only permissions on config. This fixed it. chmod 600 ~/.ssh/config As others have noted below, it could be the file owner. (upvote them!) chown $USER ~/.ssh/config If your whole folder has invalid permissions here’s a table of possible permissions: Path Permission .ssh directory (code) 0700 (drwx——) private keys … Read more

How to automate SSH login with password?

Don’t use a password. Generate a passphrase-less SSH key and push it to your VM. If you already have an SSH key, you can skip this step… Just hit Enter for the key and both passphrases: $ ssh-keygen -t rsa -b 2048 Generating public/private rsa key pair. Enter file in which to save the key … Read more

Public and Private Keys are Incorrect for user

I solved it! Finally after a lot of frustrating days. In the tutorial page, deep down in the comments, someone suggested removing/commenting the following line: define(‘FTP_PRIKEY’,’/home/wp-user/’); I did this and immediately the error message disappeared and things started getting updated.

Automating command/script execution using PuTTY

PuTTY has the -m switch, that you can use to provide a path to a file with a list of commands to execute: Where the commands.txt will, in your case, contain a path to your shell script, like: Though for automation, your better use the Plink command-line connection tool, instead of the GUI PuTTY application, as you have already found … Read more

How to use Sublime over SSH

There are three ways: Use SFTP plugin (commercial) http://wbond.net/sublime_packages/sftp – I personally recommend this, as after settings public SSH keys with passphrase it is safe, easy and worth every penny http://opensourcehacker.com/2012/10/24/ssh-key-and-passwordless-login-basics-for-developers/ Mount the remote as local file system using osxfuse and sshfs as mentioned in the comments. This might be little difficult, depending on OSX … Read more

SSH to Vagrant box in Windows?

I use PuTTY to connect to my Vagrant boxes on Windows7. Make sure you convert the %USERPROFILE%\.vagrant.d\insecure_private_key to .ppk using PuTTYGen use the .ppk key in your PuTTY session – configured in Connection > SSH > Auth > Private key file use host 127.0.0.1 use port 2222 instead of 22 you can set the default … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)