Monitor File or Directory Changes with PowerShell and Email Changes

I had a need to monitor a file/directory for changes, or more specifically entries into an error log by an application. I wanted a trigger on file change using a PowerShell or some other script, since the application didn’t have alerting capabilities built in. I wanted a script to check read the log file and send an email when the file changes containing what was changed, or in this case what the error was.

You can tweak the script to monitor a directory or specific file, and customize the email with the file name or more. Either way this is the basic script. Schedule a task in Task Scheduler (Windows 7) or Scheduled Tasks (Windows XP) to run at login for that specific user, and make sure it never terminates or times out. Set your application to run:
Continue reading Monitor File or Directory Changes with PowerShell and Email Changes

Virus scanning recommendations for Windows 7

I posted this on the old site, but it’s worth posting again due to the release of Windows 7. This Microsoft KB article outlines the recommended configuration for Anti-Virus programs on almost all versions of Windows. A must see for Administrators!

Starts out:

“This article contains recommendations that may help you protect a computer that is running Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Microsoft Windows 2000, Windows XP, Windows Vista, or Windows 7 from viruses. This article also contains information to help you minimize the effect of antivirus software on system and network performance.”