Showing results for events and monitoring - Scripting Blog [archived]

Nov 2, 2009
0
0

Hey, Scripting Guy! How Can I Write an Event-Driven Script?

ScriptingGuy1
ScriptingGuy1

  Hey, Scripting Guy! I have a problem at work. It is not with the pointy-headed boss, but I believe the problem is probably related to him anyway. There is this application that runs on a workstation in our computer room. It is not a client server application, and of course the workstation is not really a server—it is running...

Scripting Guy!Windows PowerShellscripting techniques
Jan 21, 2009
0
0

Hey, Scripting Guy! How Can I Back Up a Database’s Data Folder While the Database Is Running?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! I have a problem. I am trying to script the backup of a data folder used by our database application. The problem is that as long as the database service is running, the files that are used are locked, and I am unable to copy them. I have found the service that runs the database, and when I use WMI to stop the service, the scr...

Scripting Guy!Windows PowerShellscripting techniques
Jan 20, 2009
0
0

Hey, Scripting Guy! How Do I Display a Message and the Time a Process Was Terminated?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! We have this application that is supposed to run all the time. It is constantly giving us headaches and crashing. The applications vendor evidently expects it to crash all the time and has a thread that will restart it three times. After that, it is pretty much down for the count. The problem is that we never know when the app...

Scripting Guy!Windows PowerShellscripting techniques
Jan 19, 2009
0
0

Hey, Scripting Guy! How Can I Be Notified When a Process Begins?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! I need to be notified when a process begins. I would like to use Windows PowerShell to do this, but it does not seem to work. While I could do this in VBScript, I prefer to use Windows PowerShell. Can this be done?- NL Hi NL, Because we have access to the .NET Framework in Windows PowerShell, it can most certainly be done. In ...

Scripting Guy!Windows PowerShellscripting techniques
Jul 24, 2007
0
0

How Can I Check Every 30 Minutes to See If a File Has Been Modified?

ScriptingGuy1
ScriptingGuy1

Hey, Scripting Guy! How can I monitor an application’s log file and issue an alert if the timestamp on that file hasn’t changed in the last 30 minutes?-- JA Hey, JA. You know that’s a very interesting question, and one that – say, wait a second. You’re not JA from Stanwood, WA are you? Are you sure about that? Well, OK; we’ll take your word for...

Scripting Guy!scripting techniquesVBScript