Hi there,
I am trying to harden SSH logins on a CentOS dedicated server and noticed that:
1) when I set:
PermitRootLogin no
AllowUsers thatuser
in /etc/ssh/sshd_config
and
2) login SSH with that non-root user and su as root (I also check that I'm root with whoami and see that i am root)
I noticed that i.e. a command like service sshd restart gives:
service sshd restart
bash: service: command not found error,
but /etc/init.d/sshd restart works.. that's OK, but why on earth 'service sshd restart' doesn't work?
Anybody?