Install necessary packages:
Host:
sudo apt-get update
sudo apt-get install openssh-server
sudo ufw allow 22
Client:
sudo apt-get install openssh-client
Connect usage:
ssh username@host
Advanced:
On the client side, create the host alias for ssh. Edit ~/.ssh/config, then copy the below pattern to the config file
Then, we can simply the usage to connect to hostHost workstationHostName 10.70.70.44User darrenlPort 22
ssh workstation
Copy the public key to remote host using ssh-copy-id, thus, we didn't need to type password every timessh-copy-id -i ~/.ssh/id_rsa.pub remote-host
-