The last logon time is stored independently on each DC. If you have more
than DC, then you would have to query each DC to determine the true last
logon time.

As an alternative you can check the password age of the computers account.
Unless you have altered the default behavior, NT4 computers change the
computer account password every seven days. W2K changes the password every
20 days if memory serves me correctly.

You can checkout MachAcctPWage.exe
(http://mywebpages.comcast.net/habullock/Perlutilities.htm) if you are so
inclined. It will report all non-DC computer accounts and the password age
in days. You can optionally delete account greater than 60 days old.



-----Original Message-----
From: John Deretich [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 19, 2002 7:22 AM
To: '[EMAIL PROTECTED]'
Subject: workstation logon


Hello,

does anybody no how to find out using perl,
when was the last time a workstation was logged
on to a domain. I am trying to get a figure of
45 to 90 days, since the last login?

thanks,

John
_______________________________________________
Perl-Win32-Admin mailing list [EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to