Re: {bb} Custom notification - possible bug
Zeev Fisher <[email protected]> Sun, 08 Jun 2003 10:19:35 +0159
| Newsgroups | gmane.network.bb4.general,gmane.network.bb4.devel |
|---|---|
| Message-ID | <[email protected]> |
Thanks for your advice. I've decided to use the sms option of the bbwarnsetup and i have problems with it. My SMS is working with through serial from Solaris to Nokia GSM modem. I think there's a bug in the SMS notification mechanizm. My assumption is that no matter what the notification is , the pagedelay is calculated according to the last time sms was sent and the file np_sms-number created. For example . the status of the host maras01 ( msgs service ) turned red from green on 09:46. The BB catched it on 09:50 You can see below the output after enabling the notification debug. Take a look on the bottom of this output. It says that delay hasn't expired and it disregard the sms message. The expiration was determined from the notification tag file which was updated from another host ( i did get SMS for this ) : cat /export/home/bbuser/bb19c/tmp/np_sms-054995402 2551511 hq001.msgs red sms-054995402 1) Any idea how to solve this issue or some workaround which will enable me to use the sms 2) Extra small issue : how do i configure groups for the sms like hg and pg ? Thanks ! argmsg: maras01.msgs red Sun Jun 08 09:50:53 JST 2003 [maras01.il.marvell.com] App: E 'Sun Jun 08 09:44:06 2003': ACECLIENT - " User I/O Timeout - - User took too long to respond. " Sys: E 'Sun Jun 08 09:44:06 2003': RemoteAccess - " The user connected to port COM2 has been disconnected because the following internal aut hentication error occurred in the third party security module: The specified port is not connected. " Sys: W 'Sun Jun 08 09:44:06 2003': RemoteAccess - " The user connected to port COM2 has been disconnected because the authentication process did not complete within the required amount of time. " msg: red Sun Jun 08 09:50:53 JST 2003 [maras01.il.marvell.com] App: E 'Sun Jun 08 09:44:06 2003': ACECLIENT - " User I/O Timeout - - User took too long to respond. " Sys: E 'Sun Jun 08 09:44:06 2003': RemoteAccess - " The user connected to port COM2 has been disconnected because the following internal aut hentication error occurred in the third party security module: The specified port is not connected. " Sys: W 'Sun Jun 08 09:44:06 2003': RemoteAccess - " The user connected to port COM2 has been disconnected because the authentication process did not complete within the required amount of time. " hostsvc: maras01.msgs 2nd word in message is: <red> color of msg: red bbwarn: TRUE pagedelay: 60 cfgdelim: ; svcerrlist: disk:100 cpu:200 procs:300 msgs:400 conn:500 http:600 dns:800 memory:900 ERR:999 pagehelpcode: 911 hostinfo: (hostsvc:maras01.msgs) (bbhostsvc:maras01.msgs) (redhost:maras01) (redsvc:msgs) ignforall: machip: 010002000247 - redsvc: msgs - svcerr: 400 rule line: hg-unixcore;;*;;*;*;pg-unixcore Column 1: hg-unixcore Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: pg-unixcore Substituting hg- tags in the rule line Original column 1: hg-unixcore Checking host definition: hg-unixcore Included hosts are: <galileo84 galileo111 galileo5 gravity1 gravity2 gravity7 galileo100 galileo101 galileo102 galileo104> Column 1 converted to a regex: <galileo84|galileo111|galileo5|gravity1|gravity2|gravity7|galileo100|galileo101|galileo102|galileo104> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: galileo84|galileo111|galileo5|gravity1|gravity2|gravity7|galileo100|galileo101|galileo102|gal ileo104 Ignore this rule as host <maras01> did not match this regex: galileo84|galileo111|galileo5|gravity1|gravity2|gravity7|galileo100|galileo101|ga lileo102|galileo104 rule line: hg-backup;;*;;*;*;pg-backup Column 1: hg-backup Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: pg-backup Substituting hg- tags in the rule line Original column 1: hg-backup Checking host definition: hg-backup Included hosts are: <manof-backup lod-backup yokneam-backup> Column 1 converted to a regex: <manof-backup|lod-backup|yokneam-backup> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: manof-backup|lod-backup|yokneam-backup Ignore this rule as host <maras01> did not match this regex: manof-backup|lod-backup|yokneam-backup rule line: hg-documentum;;*;;*;*;pg-documentum Column 1: hg-documentum Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: pg-documentum Substituting hg- tags in the rule line Original column 1: hg-documentum Checking host definition: hg-documentum Included hosts are: <doc-prod doc-dev gravity6> Column 1 converted to a regex: <doc-prod|doc-dev|gravity6> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: doc-prod|doc-dev|gravity6 Ignore this rule as host <maras01> did not match this regex: doc-prod|doc-dev|gravity6 rule line: hg-web;;*;;*;*;pg-web Column 1: hg-web Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: pg-web Substituting hg- tags in the rule line Original column 1: hg-web Checking host definition: hg-web Included hosts are: <intra-prod intra-dev galileo1> Column 1 converted to a regex: <intra-prod|intra-dev|galileo1> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: intra-prod|intra-dev|galileo1 Ignore this rule as host <maras01> did not match this regex: intra-prod|intra-dev|galileo1 rule line: intra-prod;;http conn;;*;*;[email protected] Column 1: intra-prod Column 2: Column 3: http conn Column 4: Column 5: * Column 6: * Column 7: [email protected] Substituting hg- tags in the rule line Original column 1: intra-prod Checking host definition: intra-prod Included hosts are: <intra-prod> Column 1 converted to a regex: <intra-prod> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: intra-prod Ignore this rule as host <maras01> did not match this regex: intra-prod rule line: hg-NT;;*;;*;*;pg-NT Column 1: hg-NT Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: pg-NT Substituting hg- tags in the rule line Original column 1: hg-NT Checking host definition: hg-NT Included hosts are: <hq001 maras01 galtis2> Column 1 converted to a regex: <hq001|maras01|galtis2> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: hq001|maras01|galtis2 Host <maras01> matched this regex: hq001|maras01|galtis2 Trying to match service <msgs> with svcs regex: Day definition in rule line matched all (*) Time definition in rule line matched all (*) Recipients column: <pg-NT> Validate recipient: <pg-NT> This recipient <pg-NT> is a page group The page group <pg-NT> is defined by <[email protected]> The list of recipients to notify is now: < [email protected]> The list of recipients to ignore is now: <> The final list of recipients is: <[email protected]> rule line: *;;*;;*;*;sms-054995402 Column 1: * Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: sms-054995402 Substituting hg- tags in the rule line Original column 1: * Checking host definition: * Included hosts are: <*> Column 1 converted to a regex: <*> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: * Host <maras01> matched this regex: * Trying to match service <msgs> with svcs regex: Day definition in rule line matched all (*) Time definition in rule line matched all (*) Recipients column: <sms-054995402> Validate recipient: <sms-054995402> The list of recipients to notify is now: <[email protected] sms-054995402> The list of recipients to ignore is now: <> The final list of recipients is: <[email protected] sms-054995402> rule line: unmatched-*;;*;;*;*;[email protected] Column 1: unmatched-* Column 2: Column 3: * Column 4: Column 5: * Column 6: * Column 7: [email protected] Substituting hg- tags in the rule line Original column 1: unmatched-* Checking host definition: unmatched-* Included hosts are: <unmatched-*> Column 1 converted to a regex: <unmatched-*> Original column 2: Excluded hosts are: <> Trying to match host <maras01> with hosts regex: unmatched-* Ignore this rule as host <maras01> did not match this regex: unmatched-* Preliminary recipients list <[email protected] sms-054995402> Keep only one recipient definition per recipient Our recipients list is <[email protected] sms-054995402 > Working on recipient <[email protected]> getdelay(): PAGE_BASIC:DEFAULT - initdelay = 0, delay = 60 Adding recipient <[email protected]> to recipient list Working on recipient <sms-054995402> getdelay(): PAGE_BASIC:DEFAULT - initdelay = 0, delay = 60 Adding recipient <sms-054995402> to recipient list Final recipients list <[email protected] sms-054995402> bbnumeric set to <400010002000247> The prefix is set to <T9> The suffix is set to <> The pagelevels is set to <red purple> The pagelevelsmail is set to <yellow> The pagetype is set to <RCPT> The pageaddhtmlpath is set to <TRUE> The briefrcpt token is set to <> The briefrcpt token after expansion <> BBLOGSTATUS: <STATIC> BBWEBHTMLLOGS: <http://gravity1/bb/html> CGIBINURL: </cgi-bin> BBWEBHOST: <http://gravity1> BBWEBHOSTURL: <http://gravity1/bb> Notifying <[email protected]> getdelay(): PAGE_BASIC:DEFAULT - initdelay = 0, delay = 60 Recipient <[email protected]> initdelay <0> delay <60> type <2> Notification tag file: </export/home/bbuser/bb19c/tmp/[email protected]> Last modification time: <1055060975>, time now: <1055058711> Delay hasn't expired, disregard <[email protected]> Notifying <sms-054995402> getdelay(): PAGE_BASIC:DEFAULT - initdelay = 0, delay = 60 Recipient <sms-054995402> initdelay <0> delay <60> type <2> Notification tag file: </export/home/bbuser/bb19c/tmp/np_sms-054995402> Last modification time: <1055060975>, time now: <1055058711> Delay hasn't expired, disregard <sms-054995402> Removing /export/home/bbuser/bb19c/tmp/pagemsg.24357 cat /export/home/bbuser/bb19c/tmp/np_sms-054995402 2551511 hq001.msgs red sms-054995402 Arsene Laurent wrote: > > Zeev, > > In you bbpager server $BBHOME/ext/pg directory, you will find > 3 example scripts (ex1, ex2 and ex3). Those scripts are called when a > certain bbwarnrule matches and a recipient has the syntax > ext-scriptname-recipient. For example, the script ex1 is called in a > bbwarnrule like this: > > test*;;*;;*;*;ext-ex1-zeev > > In your case, take one of the examples as a template and call your sms > script from it, passing it the necessary arguments to format the sms > message. > > I wrote a little script (sms.pl) to send sms using a web > interface that receives the pre-formatted BB message in $BBALPHAMSG > from STDIN and the sms subject as an argument and I call it from a > modified ex1 as follows: > > if [ "$BBTMP" = "" ] > then > echo "BB environment not set !!!" > exit 1 > fi > > SMS="/usr/local/bbrother/bb/ext/pg/sms.pl" > export SMS > # > # Send the equivalent mail message as in the basic notification > # > > echo "${BBALPHAMSG}" | $SMS "!BB - ${ACKCODE}! $BBHOSTSVC - $BBNUMERIC" > > exit 0 > > I do not use the recipient information in my script (zeev in > our example), but BB passes that information so you can use it in > yours for instance to determine to whom to send your sms. Simply pass > the $RCPT variable to your script the same way I pass the rest > ($ACKCODE, $BBHOSTSVC and $BBNUMERIC). > > Hopes this information helps you integrating your script in > the BB notification engine. > > Arsene > > > > > "Zeev Fisher" <[email protected]> > Sent by: [email protected] > > 06/04/2003 03:56 PM > Please respond to bb > > > To: <[email protected]> > cc: > Subject: {bb} Custom notification > > > > > Hi, > > First , I would like to thank all the brothers ( especially Sean & > Robert.. ) who contributed to this excellent product. > I implemented successfully ( and very happily ) in a very short period > working big brother for our critical IT servers with many specific > customizations including Larrd,oracle,memory... > > I need an advice regarding SMS notification. > > My requirement from the SMS notification is that it will be sent directly > from the Big Brother server ( Solaris ) without any Email gateway/any > network component. > > So , I succeeded to connect my GSM Nokia cellular with it's Data port > to the > serial port of the Solaris. > I used the instructions for Nokia AT commands from : > http://www.nokia.com/cda1/0,1080,1528,00.html > I created a Kermit script which connects through Solaris serial to the > Nokia > modem and use it to send SMS. > > My question : > > What is the best/easiet way to integrate this script to the BB > notification > system. I would like to be able to do paging groups like i have for emails > ( hg,pg ). > > > > Thanks a lot in advance ! > > > -- > Zeev Fisher - Unix System Administrator > Marvell Semiconductor Israel Ltd > Moshav Manof, D.N. Misgav 20184, ISRAEL > Email - [email protected] > Tel - + 972 4 9091402 > Cell - + 972 54 995402 > Fax - + 972 4 9091501 > WWW Page: http://www.marvell.com > > ------------------------------------------------------------------------ > This message may contain confidential, proprietary or legally privileged > information. The information is intended only for the use of the > individual > or entity named above. If the reader of this message is not the > intended recipient, you are hereby notified that any dissemination, > distribution > or copying of this communication is strictly prohibited. > If you have received this communication in error, please notify us > immediately by telephone, or by e-mail and delete the message from your > computer. > > > -- > =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-==-=-=-=-=-=-=-=-=-=-=-= > To unsubscribe from this list, or to subscribe to the bb-digest list > send e-mail to mailto:[email protected] with unsubscribe bb -and/or- > subscribe bb-digest in the BODY of the message. > > -- Zeev Fisher - Unix System Administrator Marvell Semiconductor Israel Ltd Moshav Manof, D.N. Misgav 20184, ISRAEL Email - [email protected] Tel - + 972 4 9091402 Cell - + 972 54 995402 Fax - + 972 4 9091501 WWW Page: http://www.marvell.com ------------------------------------------------------------------------ This message may contain confidential, proprietary or legally privileged information. The information is intended only for the use of the individual or entity named above. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by telephone, or by e-mail and delete the message from your computer.