Hi Team,
I have disabled root login in /etc/passwd file. Please find attached image.
Is this not sufficient?
Hi Team,
I have disabled root login in /etc/passwd file. Please find attached image.
Is this not sufficient?
Hi,
You must manipulate the sshd_config file to do this so the root user can’t connect
Thanks Buddy, got it.
/etc/ssh/sshd_config
PermitRootLogin no
i did the same /sbin/nologin on all three app machines, but is shows task failed on app2 and app3 machine only (which means it succeded on app1) why is that?
You need to make required changes in sshd_config file. changing shell to /sbin/nologin
is incorrect as per requirements asked in the question.
For App 1 since you changed the root password itself which is bad to do since its not asked in the question so validation didn’t work for it at all.
I have done the modification in /etc/ssh/sshd_config file with PermitRootLogin = no
still i got the same error . as Task failed please check
attached screen shoot
what i have made wrong i have done the same on all three app servers any help would be appriciated
@kumarpuvvadi
You missed to restart sshd
service after making required changes hence tasks failed for you.
ssh tony@stapp01
ssh steve@stapp02
ssh banner@stapp03
sudo vi /etc/ssh/sshd_config
sudo systemctl restart sshd