Jump to content
Sign in to follow this  
JAlbright904

Offline Server + Offline Location condition check

Recommended Posts

Hello all,

 

Currently we have our LT - Offline Server monitor generating tickets when a server shows offline, the with a workflow within ConnectWise Manage we get sent text messages & emails alerting us.  This becomes very annoying when an entire location goes offline and we get roughly 20-30 server offline texts/emails.  

I've attempted to do some research in how to make the Offline Server Monitor check to see if the Offline Location monitor is triggered for that location and if so, not send out notifications for the offline servers.  With this I've seen some suggestions to add an "Additional Condition" to the LT - Offline Servers monitor; however no one has specifically mentioned what to add.

 

Unfortunately I am not a SQL export and do not know what Syntax to use for something like that.  Can someone point us in the right direction and give us an example of what they used to accomplish this?

Share this post


Link to post
Share on other sites

This monitor we use only sends an alert to the pager if the machine is offline for 20mins PLUS there still are other computes at the same location that _have_ checked in within the last 5 mins. This stops your 20-30 alerts scenario you describe as it singles out a machine. If everything is offline this monitor is silent (so you need a second monitor for Location offline)

image.png.abf73f37a94725539e602f7323c1ec22.png

 

The text on the query page reads:

Create Temporary Table Tcomp (INDEX (Computerid)) SELECT SubGroupwchildren.computerid,SubGroupwchildren.GroupID,Mastergroups.Priority FROM SubGroupwchildren JOIN Mastergroups USING(groupid) WHERE  FIND_IN_SET(SubGroupwchildren.groupid,'1095,1111') AND SubGroupwchildren.ComputerID NOT IN (Select ComputerID from AgentIgnore Where AgentID=17846);Select DISTINCT 'C',computers.computerid,computers.Name as ComputerName,Convert(CONCAT(clients.name,' ',locations.name) Using utf8) As Location, computers.`LastContact` as TestValue,computers.name FROM (computers LEFT JOIN  Locations ON Locations.LocationID=computers.Locationid) LEFT JOIN Clients ON Clients.ClientID=Computers.clientid  JOIN AgentComputerData on Computers.ComputerID=AgentComputerData.ComputerID WHERE computers.`LastContact` < date_add(now(),interval -20 minute) AND  ((Select Count(*) from Computers Where Computers.locationid=locations.locationid AND Computers.LastContact>Date_Add(Now(),Interval -5 minute))>0)  AND Computers.ComputerID IN (Select Distinct ComputerID From Tcomp); Drop TEMPORARY Table Tcomp;

 

Hope this helps :)

Share this post


Link to post
Share on other sites

Not effective for locations that have just a single 1 machine. You will want the location monitor triggered for those cases.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×