Running a script from WebWatchbot

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
gfandy
Newbie
Posts: 2
Joined: Fri Oct 26, 2007 7:00 pm

Running a script from WebWatchbot

Post by gfandy » Fri Oct 26, 2007 7:49 pm

I use WebWatchbot to monitor a remote web server. When it detects an outage it can execute a program, and/or load a URL. I have a macro script that logs into the remote server (using RAdmin) and restarts the web server process. Ideally, WebWatchbot would simply run this "Bounce Server" macro when it detected an outage.

Problem - WebWatchBot executes the program in the background, which does not work for the macro script. Is there any way I can
1) create a separate script that will run the Bounce Server macro in the foreground? e.g. WebWatchbot calls this script which then calls the Bounce script.
2) initiate the Bounce Server macro by loading a URL?

As a last resort, I could modify my script so that it checks an Exchange email account, and bounces the server when it receives an alert email from WebWatchBot.

Cheers

GarryP
Junior Coder
Posts: 27
Joined: Sat Feb 04, 2006 12:01 pm

Run script interactive

Post by GarryP » Sat Oct 27, 2007 2:37 am

You could you PStools PSexec by having WebWatchBot execute psexec -i \\pcname msched macroname

the -i switch makes the command to run interactive with the console session.

gfandy
Newbie
Posts: 2
Joined: Fri Oct 26, 2007 7:00 pm

Post by gfandy » Wed Feb 20, 2008 6:35 pm

Thanks for your suggestion. I wasn't able to get it to work -- the process would start, but wouldn't do anything (and once started, I couldn't kill it).

I decided to do it the less elegant way: Webwatchbot sends an email alert, and an Outlook rule initiates the macro.

Thanks again!

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts