Let's stick with using the SSH login at the moment. Many users will only access the server via SSH, perhaps using the PuTTY SSH client on Windows. If we want to control access to system resources, then we can implement restrictions using PAM and pam_limits.so
. We should add the following line to the /etc/pam.d/sshd
file:
session required pam_limits.so
This will implement the module, however, we still have to set the restrictions in the /etc/security/limits.conf
file; the module reads from this file. The file's structure is set as follows with these elements making up a line in the limits file:
<domain> <type> <item> <value>