Operating System - HP-UX
1748218 Members
4484 Online
108759 Solutions
New Discussion

Re: Login failure script for last one week

 
Ramasubramanian Krishna
Occasional Advisor

Login failure script for last one week

Hi

 

Looking for a script that will generate a report of unsuccessful logins for last one week for both linux and hp-ux env

3 REPLIES 3
Patrick Wallek
Honored Contributor

Re: Login failure script for last one week

You can see unsuccessful logins via the 'lastb' command.

Ramasubramanian Krishna
Occasional Advisor

Re: Login failure script for last one week

I needed a script to running on weekly basis and generate a failure report for that particular week only . using lastb i will be getting for the full month


@Patrick Wallek wrote:

You can see unsuccessful logins via the 'lastb' command.


 

 

Dennis Handly
Acclaimed Contributor

Re: Login failure script for last one week

>I needed a script to running on weekly basis and generate a failure report for that particular week only . Using lastb I will be getting for the full month

 

Using lastb(1) goes back as far as the last time the EOF was reset.

So either you need to reset it once a week.  Or you need to script a check for the current week using data arithmetic.