Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Network Logon/logoff reports

Status
Not open for further replies.

criffle00

MIS
May 8, 2008
2
US
How can I view logon/logoff reports for network users? Are there reports in Microsoft Business Server 2003 which can track this activity?
 
Here's a pretty slick method:


Code:
Step 1: Create the following two files using Notepad or your favorite text editor:

------logon.cmd----
echo logon %username% %computername% %date% %time% >> \\sbs\share\logon.log

-----logoff.cmd-----
echo logoff %username% %computername% %date% %time% >> \\sbs\share\logon.log

Step 2: Update Group Policy to run the appropriate batch file. In Group Policy, go to:
User Configuration-> Windows Settings-> Scripts (Logon/Logoff)-> Logon

Step 3: As users log on and off, your log file should look something like this:

logon June VSXP Tue 22/02/2005 10:39:51.12
logoff June VSXP Tue 22/02/2005 10:41:08.45
logon MickM VSXP Tue 22/02/2005 10:42:01.07
logoff MickM VSXP Tue 22/02/2005 10:42:46.81

Tony

Users helping Users...
 
the method above will require a manual retention method for the log files; aka, be ready to copy the log files (or rename them) on a daily basis. This can be done via a scheduled task though pretty easily.
the method above is sound though...but prettier through vbscript :D

-Brandon Wilson
MCSE00/03, MCSA:Messaging00, MCSA03, A+

 
ADGod,
How would you do through vbscript? Can you provide example?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top