-
Notifications
You must be signed in to change notification settings - Fork 0
SSH into the host without Keyfile
Suraj Gupta Gudla edited this page Apr 7, 2022
·
1 revision
Reference: (https://www.cyberciti.biz/faq/ubuntu-linux-install-openssh-server/)
2. Add a new user <login_name> and assign a password to it. Also, add this user to the sudo group using the below commands
$ sudo adduser <login_name>
$ sudo passwd <login_name>
$ sudo usermod -aG sudo <login_name>
$ sudo visudo /etc/ssh/sshd_config
Set the parameters as below,
- PasswordAuthentication yes - For allowing a valid user to log in without the key
- PermitRootLogin yes - If you want to allow root login without a key as well
$ sudo systemctl restart sshd.service
$ ssh <login_name>@<public ip_address>
$ sudo visudo /etc/ssh/ssh_config
$ sudo systemctl restart ssh.service