Windows Thread, Script - Logon Tracking in Technical; I have written a script which runs at user logon and logoff:
@ echo off
net use L: ...
20th March 2012, 03:02 PM #1
Script - Logon Tracking
I have written a script which runs at user logon and logoff:
net use L: \\yourservername\dir /U:username password
echo **User Logon** UserName: %USERNAME% ComputerName:%COMPUTERNAME% UserDomain:%USERDOMAIN% UserProfile:%USERPROFILE% System Time: %TIME% System Date: %DATE% Currently Attached to Server: %LOGONSERVER% >>L:\Logon.txt
net use L: /del /yes
It works very well and we now have a log file which logs all of our users logging onto machines and shows them logging off also with times and dates.
Primarily I hadn't made the script to map a network drive but I kept getting "Acess Denied" So it now maps to a drive creates the log and then the script disconnects the map drive and its like it never existed, but if you go to your server and look in the folder where the drive is mapped too you should see a log file.
Obviously you can customize the script to your needs.
I hope this helps you!
IDG Tech News
Last Post: 2nd August 2013, 11:44 AM
By mobybrick in forum Home Access Plus+
Last Post: 28th November 2011, 10:38 PM
By Samson in forum Windows
Last Post: 9th October 2008, 10:42 AM
By tarquel in forum Windows
Last Post: 14th June 2006, 10:07 AM
By british-wave in forum How do you do....it?
Last Post: 15th February 2006, 03:28 PM
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)