Show differece of remote command output.
May be useful for server migration.
- Download release executable
- Place executable on /usr/local/bin or somewhere
- Set permission to
rwxr-xr-x
(755)
$ sshdiff server1 server2 ls
run ls
in server1 and server2 by ssh, then show difference of ls
output.
$ sshdiff yuriko@server1 yuriko@server2 ls
$ sshdiff yuriko@server1 yuriko@server2 'rpm -ql|sort'
If command has args, must quote it.
If ports(22) or keys(id_rsa, id_ecdsa, etc..) are different from default, please specify on your ~/.ssh/config like below
Host server1
HostName server1.example.com
Port 8022
IdentityFile ~/.ssh/id_ecdsa_server1
Host server2
HostName server2.example.com
Port 1022
IdentityFile ~/.ssh/id_ecdsa_server2