KS-Soft. Network Management Solutions
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister    ProfileProfile    Log inLog in 

Condition to perform dependant test

 
Post new topic   Reply to topic    KS-Soft Forum Index -> Other
View previous topic :: View next topic  
Author Message
govarlo



Joined: 16 Aug 2021
Posts: 5

PostPosted: Mon Aug 16, 2021 2:35 pm    Post subject: Condition to perform dependant test Reply with quote

Hi All,

First post on this blog. Just wondering if anyone knows how to create a Custom Monitoring condition for a test in the following scenario:

I have 2 servers which are Active-Standby configuration, both servers are configured the same way, currently I've monitor created to fetch info from each server with HTTP Test method by a GET Request and Checking specific Contents.

The Active server has 50 extensions registered and when tests are performed, all looks fine as the extensions are online, however on the Standby server, because it has no extensions registered, I get BAD Request status.

The servers could swap roles and then the previous Standby server will take over Active role and it will register 50 extensions to it, and to old Active one will un-register the extensions.

My goal is to create a Custom Condition test which allow me to check the Active server extensions status and for the Standby server, monitor it to check if Active server role and status are OK, and in case of failure of Active one, the Standby server becomes Active and start monitoring the extensions status for the new Active server.

Hope I express myself clearly enough!!!
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12792
Location: USA

PostPosted: Tue Aug 17, 2021 12:07 am    Post subject: Reply with quote

Not sure I understand.
How many tests have you set?
2 tests - one for each server?
Or 100 tests - 50 tests for each server?
Do you want to set 2 Master tests (one for each server) and 100 dependent tests (50 for each server)?

If you have just 2 tests, I assume you want to get some alerts when both tests returns "bad" status at the same time?
While "good"+"bad" test results should not trigger actions?

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
govarlo



Joined: 16 Aug 2021
Posts: 5

PostPosted: Tue Aug 17, 2021 6:59 am    Post subject: Reply with quote

I have 2 tests, one for each server. The test consist on an search for HTTP text string on a web page to confirm status of the 50 extensions. The Active server shows the 50 extensions registered, the standby server not, reason why I get BAD request.
My intention is to have alerts on Active server showing up, and alerts on Standby server on hold until it gets Active because failure of the other server.

I was thinking about to have 2 lines HTTP string search, but not sure how to make it to work as the files on "Text Method \ Advanced \ Check Contents has only one field to add text, reason why I was thinking on adding Custom Monitor to detect which server is active and only alert for the tests on active server and stays on-hold for Standby server until it gets online.

Thanks in advance for your help
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12792
Location: USA

PostPosted: Tue Aug 17, 2021 10:40 am    Post subject: Reply with quote

Sorry, still do not understand
How exactly HTTP response looks in both cases?
What text should be detected for "good" test status?
What text should be detected for "bad" test status?

Something like:
"active" should be present and "failed" should not be detected for "good" status?
"standby" detected - set "good" status regardless of "failed" text presence?
"active"+"failed" - "bad" status?

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
govarlo



Joined: 16 Aug 2021
Posts: 5

PostPosted: Tue Aug 17, 2021 7:48 pm    Post subject: Reply with quote

Sure, I understand is hard to get it as this is a very custom test.

The HTTP text that I'm currently searching is:
- Recording devices registered with DMCC - 50

But I need to add another extra search for:
- Recorder Role: Primary

In case both expressions match, that is the Active Server, so it basically confirms Registered extensions and Server role

My idea is something like this:

If "Server Role: Primary" and "Recording devices registered with DMCC - 50" then Status is: Host is Alive


If "Server Role: Backup" then Server Status "waiting for Primary"


The test should be smart enough to identify which server is primary and which one is backup in order to run the test for only Active server.

Does it makes more sense now?
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12792
Location: USA

PostPosted: Wed Aug 18, 2021 4:45 am    Post subject: Reply with quote

I think you don't need any master-dependant set of tests.

You may set 1 test (per server) with the following option
Check content: use expression "Server Role: Backup" or "Recording devices registered with DMCC - 50"

Test will set Bad status when (serverrole<>backup) and (DMCC<>50)
Otherwise HostMonitor will set Ok status.

Unless both servers may switch to "backup" mode and this should be detected as "bad" condition?

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
govarlo



Joined: 16 Aug 2021
Posts: 5

PostPosted: Wed Aug 18, 2021 6:58 am    Post subject: Reply with quote

That is correct, at the moment both tests are created searching for -Recording devices registered with DMCC - 50 - but the part of the Custom expression to make the test search for other conditions is the one I can't complete.

You are suggesting something like this: Test will set Bad status when (serverrole<>backup) and (DMCC<>50) which I believe is fine and I could start from there, however could you please show me some examples, or at least the structure that should contain the Custom Expression?

Thanks for your help.
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12792
Location: USA

PostPosted: Wed Aug 18, 2021 7:15 am    Post subject: Reply with quote

Quote:
however could you please show me some examples, or at least the structure that should contain the Custom Expression?

Please open window with URL test settings, find "Check content" option, set "use expression" mode.

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
govarlo



Joined: 16 Aug 2021
Posts: 5

PostPosted: Wed Aug 18, 2021 8:32 am    Post subject: Reply with quote

Hey Alex,

Sorry, I'm not getting you. You want me to open a web browser? or HostMonitor Test I've created? On the Test properties I can see This test depends on and I can set it up for Expression, which is the one I don't have the knowledge to create.

Regards,
Back to top
View user's profile Send private message
KS-Soft



Joined: 03 Apr 2002
Posts: 12792
Location: USA

PostPosted: Wed Aug 18, 2021 10:35 am    Post subject: Reply with quote

Please send e-mail to support, we will provide screen shots

Regards
Alex
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    KS-Soft Forum Index -> Other All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group

KS-Soft Forum Index