problem with alert

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf problem with alert

  • Creator
    Topic
  • #48204
    Ray Mullen
    Participant

    Hi I am having a problem setting up an alert.

    We have a FTP thread that intermittently goes into an error status. As a temporary fix, i am tryying to set up an alert that will stop and restart the thread depending on the status.

    I have tried lots of different combinations but just cant get an alert to fire.

    Here are the settings of my latest try (its only a test) i am checking if thread is “opening” just stop the thread , . I have stopped the daemon and restarted with the alert file in the paramater but still to no avail.i am probably leaving something simple out. Any help would be great .

    i have tried opening without the quotes also.

    Thanks in advance.

    VALUE status} {SOURCE lab_to_ocm} {MODE actual} {WITH -1} {COMP {== {“opening”}}} {FOR {nsec 10}} {WINDOW {* * * * * *}} {HOST {}} {ACTION {{exec {hcicmd  -p results -c “lab_to_ocm pstop”}}}}

Viewing 7 reply threads
  • Author
    Replies
    • #58002
      James Cobane
      Participant

      Ray,

      Based on what you stated, I would configure an alert based on the ‘protocol status’ == error, and then set the ‘Action’ to ‘exec hcicmd -p results -c “lab_to_ocm pstop”;hcicmd -p results -c “lab_to_ocm pstart” ‘

      This will run the stop, and then a start of the thread when the protocol status goes to ‘error’.

      Hope this helps.

      Jim Cobane

      Henry Ford Health

    • #58003
      Ray Mullen
      Participant

      Hi Jim,

      Thanks for the reply.

      I was going to put it as error when i got it to work, but to get the alert to fire and to check if it was working i was just trying it out with opening..e.g I bring the thread up and then pull the api connecting to the thread to make it go into an opening state. I then wait the amount of time but  unfortunately it never seems to want to fire up. Am I leaving something out in the alert. I have stopped the daemon and inserted the new alert file and it says its starts ok. Is there any other process i need to do.

      Thanks

    • #58004
      Julie Kimmel
      Participant

      try using this as your exec string:

      cmd.exe /c hcicmd  -p results -c “lab_to_ocm pstop”

    • #58005
      James Cobane
      Participant

      Ray,

      When you are configuring the alert, are you using the drop-downs to select the protocol status?  Based on your e-mail, it sounds like you may be keying-in the value ‘opening’.  Try selecting it from the drop-down via the ‘List’ button.  Also try changing the ‘Source Count’ from ‘all’ to ‘any’, just for laughs.

      Are you adding this to the default.alrt, or a different .alrt file that you are then invoking?

      Good Luck.

      Jim Cobane

      Henry Ford Health

    • #58006
      Ray Mullen
      Participant

      Hi Jim / Julie ,

      Thanks a million for both your help.  I had 2 things wrong , I had the alert setup as thread status rather than protocol and you were right jim I had typed in opening rather than selecting from list because the option didnt appear if alert type was thread. And thanks also to Julie the alert only fired when i put the cmd.exe /c in front of the hcicmd.  

      Thanks again for both of you for your help. Much appreciated.

      Ray

    • #58007
      Rentian Huang
      Participant

      Ray, can you post the final alert that works for you here?

      Thanks!

    • #58008
      Ray Mullen
      Participant

      Hi Rentian,

      Here is the alert that finally worked for me. I have only tested it with opening so far but that worked absolutely fine. Rather than stopping the thread , i stopped the process and restarted it because there are only 2 threads in this process and the threads are set to auto start.  I have replaced the command with a script but julies cmd.exe /c works fine also.

      {VALUE pstat} {SOURCE ae_to_pims} {MODE actual} {WITH -1} {COMP {== error}} {FOR {nmin 5}} {WINDOW {* * * * * *}} {HOST {}} {ACTION {{exec {y:\startup\restart_ftp.cmd}}}}

      and here is the script.

      :: Stop the FTP Process

      set ftplog=y:startupftplog.log

      echo.  1>>  %ftplog% 2>&1

      echo.  1>>  %ftplog% 2>&1

      call setroot y:quovadxqdx5.2integrator production  1>>  %ftplog% 2>&1

      call setsite production 1>>  %ftplog% 2>&1

      echo About to stop FTP Process  1>>  %ftplog% 2>&1

      hcienginestop -p ftp 1>>  %ftplog% 2>&1

      echo FTP Shutdown Completed  1>>  %ftplog% 2>&1

      Wait 8

      hcienginerun -p ftp 1>>  %ftplog% 2>&1

      echo “ftp startup completed” 1>> %ftplog% 2>&1

      I have just outputted to a simple log so i can see quickly if it has kicked in.

    • #58009
      Steven Siegfried
      Participant

      Would changing the Source Count to ‘at least’ 1 in a pstat alert help to determine if the alert is a false positive?  E.G. The outbound thread goes from up and green to opening but the the inbound thread wasn’t sending any messages.

      James Cobane wrote:

      Ray,

      When you are configuring the alert, are you using the drop-downs to select the protocol status?

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

Forum Statistics

Registered Users
5,117
Forums
28
Topics
9,293
Replies
34,435
Topic Tags
286
Empty Topic Tags
10