Pegasus (MVP)
Guest
|
Posted:
Sat Nov 12, 2005 8:20 am Post subject:
Re: Keeping Logs |
|
|
<djone.121@gmail.com> wrote in message
news:1131725492.736381.30390@g43g2000cwa.googlegroups.com...
| Quote: | I'm looking for a way to journal or keep logs of all the changes made
on my servers. I manage about 25 servers, and unfornately everyone has
there hands in the cookie jar. So I'm looking for a way for them to
just write or journal or something what they have done. Because about
the time I go in and start fixing things, I change what they have done
and vice versa. I would prefer a web based solution, but at this time
I don't care. I'm getting to the point where I might have to program
something in php and mysql unless a solution already exist.
|
I found that the following simple solution is adequate in most situations.
I started by placing the batch file "history.bat" into the logoff GPO of all
my servers. Here is what it looks like:
Line1 @echo off
Line2 if /i "%1"=="View" notepad \\SomeServer\Logs\%ComputerName%.log & exit
Line3 if "%1"=="" (set Name=%ComputerName%) else (set Name=%1)
Line4 echo %date% %time:~0,5% %UserName% >> \\SomeServer\Logs\%Name%.log
Line5 notepad \\SomeServer\Logs\%Name%.log
Furthermore, I place that same batch file into a path folder on every
server (in my case c:\Tools). And here is how it works:
- Admins are automatically prompted at logoff time to record their actions.
- Admins can add remarks retrospectively from anywhere by typing this
command:
history SomeServerName
- Admins can view the current log file by typing this command:
history View
- I make it a rule of employment that all support activities have to be
logged,
using this tool.
- I take appropriate action with those who ignore the rule. One warning
is usually enough. |
|