In this editor you will need to find the line

Explore workouts, and achieving AB Data
Post Reply
Mitu100@
Posts: 1665
Joined: Tue Jan 07, 2025 4:28 am

In this editor you will need to find the line

Post by Mitu100@ »

Usermod -aG sudo username

After creating a user, we need to log in using this user. To log in remotely, you can use the Putty program.

After logging in to the account, go to the logs folder by entering

cd /var/log/

The following command will show us all attempts
to log in to the

sudo cat auth.log

There will be a lot of fax lists symbols in front of you, among which you will be able to see login attempts, from which addresses they were made and their status.
Next, exit the directory by entering CD

When we were back on the main page of the terminal using any convenient text editor, open the following item (I use the nano editor)


PermitRootLogin yes and change yes to No

After that, save the file and exit it
Now restart SSH protocols by entering

sudo systemctl restart sshd

After that, you can try to log in using the root user, but you will not succeed. An error will occur (An example can be seen in the video.)
Post Reply