System Administration Guide, Volume 2

How to Save Failed Login Attempts

  1. Become superuser.

  2. Create the loginlog file in the /var/adm directory.


    # touch /var/adm/loginlog
    
  3. Set read and write permissions for root on the loginlog file.


    # chmod 600 /var/adm/loginlog
    
  4. Change group membership to sys on the loginlog file.


    # chgrp sys /var/adm/loginlog
    
  5. Make sure the log works by attempting to log into the system five times with the wrong password after the loginlog file is created. Then display the /var/adm/loginlog file.


    # more /var/adm/loginlog
    rimmer:/dev/pts/4:Mon Jul 12 13:52:15 1999
    rimmer:/dev/pts/4:Mon Jul 12 13:52:23 1999
    rimmer:/dev/pts/4:Mon Jul 12 13:52:31 1999
    rimmer:/dev/pts/4:Mon Jul 12 13:52:39 1999
    #