Alert Time Window Ignored

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Alert Time Window Ignored

  • Creator
    Topic
  • #54819
    Joe Grathoff
    Participant

      I have a alert with a condition to fire every 10 minutes during a time window.  Trouble is my time window of “NOT” 7:00-23:30 seems to be ignored and it fires all day long.  I want it to fire from 23:30 to 7:00.  Tried setting the opposite of NOT 7:00-23:30 by doing two ranges:  23:30 to 23:59 and 00:00 to 6:59 and this fired all the time too.  Why does this fire outside the time window?

      default.alrt:

      }

      {ALERT

         { NAME {Create HFHS result times} }

         { VALUE status }

         { SOURCE HFHS_rad_res_in }

         { WITH -1 }

         { COMP {!= down} }

         { FOR once }

         { REPEATING {

         { REPEATING {

             { MAX -1 }

             { TIME {nmin 10} }

         } }

         { WINDOW_NOT */7:00-23:30/*/* }

         { ACTION {

             { exec {tcl /quovadx/cis5.8/integrator/sbin/alert_HFHS_res3.tcl >>/quovadx/cis5.8/integrator/sbin/HFHS_alert.log} }

         } }

      }

      alerts.log

      [09/15/2015 07:57:45] :  Alert Fired Action

      : Alert: HFHS_rad_res_in | Create HFHS result times

      : Message: Thread status of HFHS_rad_res_in is not down

      : Notification #: 769

      : Action: tcl /quovadx/cis5.8/integrator/sbin/alert_HFHS_res3.tcl >>/quovadx/cis5.8/integrator/sbin/HFHS_alert.log

    Viewing 5 reply threads
    • Author
      Replies
      • #83113
        Russ Ross
        Participant

          I took a look at one of our alerts that will fire once an hour anytime from 7AM-7PM Mon-Fri:

          Code:

          {ALERT
             { NAME {ob_ml_adt_a Q2 (200) Mon-Fri (7AM-7PM)} }
             { GROUPS sms_super_adt }
             { VALUE opque }
             { SOURCE ob_ml_adt_a }
             { WITH 1 }
             { COMP {> 200} }
             { FOR {nmin 10} }
             { REPEATING {
                 { MAX 11 }
                 { TIME {nmin 60} }
             } }
             { WINDOW {* * 7,8,9,10,11,12,13,14,15,16,17,18 * * 1,2,3,4,5} }
             { ACTION {
                 { exec {recycle_thread_alert.ksh    “email_interface_help,page_hub_on_call,”     ‘HUB oncall have Cerner ML admin check their sms_super_adt listener interface; queue depth > 200 for thread p_ob_lab_1/ob_ml_adt_a’     ob_ml_adt_a     sms_super_adt} }
             } }

          Never used NOT time span so this example shows how to fire during desired time span only.

          The difference that jumps out at me is your setting for { MAX -1 } probably means indefinitely.

          In my case I set MAX to the time span in minutes dived by {nmin 60} for once an hour and subtracted 1 to get { MAX 11 } for my 12 hour period from 7AM-7PM.

          Then I have another alert defined for the night time hours to fill in the gap that doesn’t have repeating defined at all and will only fire once if triggered.

          Russ Ross
          RussRoss318@gmail.com

        • #83114
          Joe Grathoff
          Participant

            Thanks Russ!

            So the faulty logic is by having the alert always test true, it triggers unlimited repeats, even past the time range window.

            I deactivated the repeats and changed it from a time range to specific event times.  Let’s see how that works.

          • #83115
            Kevin Crist
            Participant

              Sorry to drudge up an old thread but i am also having issues with this. The below code shows us using the NOT part but this was changed. We did have it unchecked but that didn’t work either.

              We only want these to fire 8 am to 7 pm Monday – Friday and they go off all throughout the nights and even on the weekends. Is there any glaring weakness in what we have below? I have used this elsewhere and it works fine.

              Thanks.

              Code:

              {ALERT
                 { NAME {lccc IB Last Message Received Email} }
                 { VALUE lastr }
                 { SOURCE lccc_ib_rfl1 }
                 { WITH -1 }
                 { COMP {>= 1800} }
                 { FOR {nmin 1} }
                 { REPEATING {
                     { MAX 10 }
                     { TIME {nmin 30} }
                 } }
                 { WINDOW_NOT 1-5/0:00-8:00,19:00-23:59/*/* }
                 { ACTION {
                     { email {
                         { FROM cloverleaf@infor.com

            • #83116
              James Cobane
              Participant

                Rather than specifying the exclusion timeframes, why not just specify the actual timeframe you want the alert to fire?  I wonder if having the NOT with two different timeframes is causing the issue; that it treats it as OR vs AND.  i.e.

                0:00-8:00 is NOT 19:00-23:59, therefore this is TRUE and likewise,

                19:00-23:59 is NOT 0:00-8:00, therefore this is TRUE as well.  Does that make sense?

                Jim Cobane

                Henry Ford Health

              • #83117
                Kevin Crist
                Participant

                  we actually had it that way but it didn’t work. We were just grasping at straws by checking the Not part.

                  I will change one back.

                • #83118
                  Michael Hertel
                  Participant

                    Make sure you don’t have a maintenance script running somewhere that resets the statistics.

                    hcimsiutil -Z or zt

                Viewing 5 reply threads
                • The forum ‘Cloverleaf’ is closed to new topics and replies.