-   Linux - Software (
-   -   Big Brother 1.9i help (

VeeDubbs 04-19-2006 02:29 PM

Big Brother 1.9i help
Hello all,

I just recently finished setting up a Big Brother server. The last thing I am trying to setup is the e-mail notifications; this part does not want to work for me! I have edited the bbwarnrules.cfg files to e-mail me when a device goes down. I have even brought devices down to see if BB would notice the event. BB does notice it (turns page red, red x, etc), but, I never get an e-mail notification (waited around 30 minutes before bring the device back up). My question is, is there something local to the machine (not even in the BB config) that must be setup for the machine to be able to send e-mails? I'm sort of a n00b, so be nice :). Hopefully someone here can help me!! Thanks!

EDIT: I am using Fedora Core 4.

VeeDubbs 04-19-2006 10:47 PM


haertig 04-19-2006 11:08 PM

Not sure about BB version 1.9 specifically, but the version I bought at work (I don't remember the version right no, I'm at home) logs notification attempts. From you bb directory go up one level and there (hopefully) will be a "bbvar" directory. Go there, and then to it's subdirectory "acks". Then a file named "notifications" from there. I believe that's it - not having my work system handy to verify at the moment. Messaging attempts should be logged to that notifications file. First verify that BB is trying to send a message in the first place, and then we can move on from there. BB only sends notifications on red conditions, not yellow, unless they've changed that in newer versions. The message sending mechanism is (was) very simple. Just a shell script in the bb/ext directory if I remember. I've somewhat forgotten the default BB behavior after this, because I totally rewrote the notification system myself. I seem to remember the default was extremely trivial shell scripts pulling info to send out of environmental variables.

If your BB logfile shows it tried to send a notification, it could be your bbwarnrules.cfg that is incorrect. Post the rule you're expecting to trigger (from bbwarnrules.cfg) and I'll give it a look-see for obvious problems. I also seem to remember you have to globally turn notifications on. Some other file I can't remember the name of, but it would be in that same etc directory and probably has "warn" included somewhere in the filename. It's been years since I set that part of BB up, so my memory is fuzzy, but I can refresh my memory tomorrow at work if you'd like.

VeeDubbs 04-20-2006 09:20 AM

Thank you for your response haertig! I took a look into /bbvar/acks and found my notifications.log filled with a lot of stuff such as:


Tue Apr 18 10:05:20 2006 Johnson3.conn (999999999999) 1145372720 500
Tue Apr 18 10:44:45 2006 Johnson-W4D.telnet (010016000017) 1145375085 723
Tue Apr 18 10:49:37 2006 Johnson-W2D.telnet (010016000011) 1145375377 723
Tue Apr 18 20:09:38 2006 Johnson-W2D.telnet (010016000011) 1145408978 723
Wed Apr 19 08:44:38 2006 Johnson-W2D.telnet (010016000011) 1145454278 723
Wed Apr 19 14:55:12 2006 Johnson-W1D.telnet (010016000009) 1145476512 723
Wed Apr 19 15:19:38 2006 Johnson-W2D.telnet (010016000011) 1145477978 723
Wed Apr 19 18:34:50 2006 Johnson-W1D.telnet (010016000009) 1145489690 723
Thu Apr 20 03:14:39 2006 Johnson-W2D.telnet (010016000011) 1145520879 723

That is only a portion of it - it had a lot more in it appears as if it is attempting to send something to me, however, it is not getting there (which is my problem!!!!). Also, here are the lines from bbwarnrules.cfg:



# notify-admin;;pagehelp;;*;*;

# unmatched-*;;*;;*;*;

I have the last two lines commented out, because I don't believe I need them. But there it all is. I hope this helps you, because I really need your help. Thanks again!

FYI: I'm sure you realize this, but that is not my real email addy. In the config files I do have my real addy, but it does not work. :)

haertig 04-20-2006 11:31 AM

That global "turn the notifications on" file I was thinking of is .../bb/etc/bbwarnsetup.cfg You need to have a line in there that says "bbwarn=true". You probably do, since you're getting entries in you notifications.log file. But it might be that notifications.log is updated even if this flag is turned off. It would be good to check.

If that part looks good for you, I'd next try to create a test notifications script. Go to the directory .../bb/ext/pg and create a file named "bbtest" and put the following in that file:

env > /tmp/bbtest.$$
Make the file executable. Then add the following to .../bb/etc/bbwarnrules.cfg:

If you had to add that "bbwarn=true" to the bbwarnsetup.cfg file, restart Big Brother (maybe this isn't required, but it won't hurt):

.../bb/ stop
.../bb/ start

Now start looking at your /tmp directory for creation of those "bbtest" files. Don't forget to turn this test off after you're done. You could fill up /tmp very rapidly! If you find those bbtest files, your problem is probably in the enviroment. That's why we put the "env" command in that test script. Edit one of those bbtest files and peruse the environment it displays. You should see things like BBTMP, BBSVCNAME, BBALPHAMSG, etc. And an all-important one ... MAIL ... this is the environment variable that BB will use to invoke the program that actually sends you the email.

Enough for now. Report back on your findings.

BTW, it looks like I'm using BB version 1.9 also. My install is four years old, but I guess 1.9 is still the current version. I've modified mine pretty significantly however, in the notifications and test scripts areas.

VeeDubbs 04-20-2006 12:31 PM

Still having problems..and am getting very frustrated! But thank you very much for all your help still. Okay, I went the
/bb/bb/ext/pg directory

[root@bigbrother pg]# pwd

[root@bigbrother pg]# ls -l
total 16
-rwxr-xr-x  1 root root  21 Apr 20 09:54 bbtest
-r-xr-xr-x  1 1062  515 1289 Dec 30 22:24 ex1
-r-xr-xr-x  1 1062  515 1258 Dec 30 22:24 ex2
-r-xr-xr-x  1 1062  515 1587 Dec 30 22:24 ex3

[root@bigbrother pg]# cat bbtest
env > /tmp/bbtest.$$

and made the bbtest file. I then went into the /tmp directory to see if anything happened...

[root@bigbrother ~]# cd /home/bb/bb/tmp

[root@bigbrother tmp]# ls
BB  np_myemail@domain.com_Johnson-W4A.conn

[root@bigbrother tmp]# cat BB

[root@bigbrother tmp]# cat np_myemail@domain.com_Johnson-W4A.conn
6924010 Johnson-W4A.conn red

I'm assuming I should be seeing more than just these two files...I have no clue what is going on. :( It doesn't even seem that the test files are getting through now. I did do ./bbtest while in the /ext directory. Is there anything else I should have done?

EDIT: I did have the "bbwarn=true" line in bbwarnsetup.cfg.
Thanks again!

haertig 04-20-2006 12:41 PM


# cat bbtest
env > /tmp/bbtest.$$
I then went into the /tmp directory to see if anything happened...
# cd /home/bb/bb/tmp
# ls

You code in that bbtest script is creating a file in the /tmp directory, but it appears you are looking for the file in the /home/bb/bb/tmp directory. These are two different places.

haertig 04-20-2006 12:57 PM


Originally Posted by VeeDubbs
...and made the bbtest file. I then went into the /tmp directory to see if anything happened...

Don't forget that you have to tell Big Brother to INVOKE you test script, by adding this to your bbwarnrules.cfg file:


haertig 04-20-2006 01:01 PM


I did do ./bbtest while in the /ext directory.
This should have created one of those /tmp/bbtest.* files. HOWEVER, the one this created would reflect the environment you had running at the command line, NOT the environment that Big Brother would be running under while trying to send you an email. I would suggest you manually remove any /tmp/bbtest.* files you find and start again from scratch, letting Big Brother automatically create the files. Otherwise you stand a good chance of confusing yourself if you view the wrong bbtest file. You may not be looking at the environment that you THINK you are looking at...

VeeDubbs 04-20-2006 01:03 PM

Alright, well that was retarded of me. But, an easy fix! Now, in the bbtest files it says MAIL=/var/spool/mail/root. But, from what I know, that is just the mail that the local root user gets, right? Are you saying this should be set to envoke sendmail somehow? How do I go about that? Should the MAIL variable be set to /usr/lib where there is a sendmail and a sendmail.sendmail? I think we may be getting somewhere?

EDIT: Ok, ignore most of what I wrote above. I have been doing
./bbtest which would result in one of those bbtest files showing up in the /tmp directory. However, now that I have not done that anymore; no bbtest* files are being created in the *correct* /tmp directory. I think I have more problems than BB on my hand...something with sendmail or some other config isnt right!

haertig 04-20-2006 01:29 PM


Originally Posted by VeeDubbs
Now, in the bbtest files it says MAIL=/var/spool/mail/root.

This is your problem. Normally, what you are seeing is exactly what you'd expect your MAIL environment variable to be set to (if you're running as root, that is!)

However, Big Brother usurps the normal setting for MAIL and sets it differently for it's own purposes. This is done in Big Brother's file .../bb/etc/ Search that file for "MAIL" and you'll see this being done. In my Big Brother environment, this is the setting:

MAIL="/usr/bin/mail -s
And here's a sample of Big Brother code that uses the MAIL variable. You can see based on how it's being used that it is NOT the standard setting for MAIL that normal users see. It's not the setting that YOU are seeing in your test. The following is a snippet of code from the .../bb/ext/pq/ex0 file:

if [ "$RECOVERED" = "1" ]
        echo "${DOWNSECSMSG}" | $MAIL "!BB! $BBSVCNAME recovered" "$RCPT"

What you're finding here tells me that your Big Brother environment is not correct. I doubt you can fix this by simply setting a different MAIL variable. Maybe ... but I expect your entire Big Brother enviroment is not correct. I would expect other problems besides just this MAIL thing. This may have been something you messed up when you installed it. You shouldn't have to be calling manually. There are other files that setup BB environment too, and you shouldn't need to call these manually either. Examples being .../bb/etc/ and .../bb/etc/

One thing to verify first ... this bbtest.* file you are looking at, it IS one that was created by Big Brother automatically, RIGHT??? It's not one that you might have created MANUALLY when you ran that ./bbtest script from the command line, RIGHT??? This confusion about what environment you are looking at is the point I was trying to make a post or two back, when I said to delete any /tmp/bbtest.* files and start again from scratch.

haertig 04-20-2006 01:54 PM


Originally Posted by VeeDubbs
no bbtest* files are being created in the *correct* /tmp directory. I think I have more problems than BB on my hand...something with sendmail or some other config isnt right!

The problem would not be in sendmail. The purpose of that bbtest script was to take sendmail out of the picture. This still could be an environment thing. BB's environment may not allow it to find this bbtest script OR the normal emailing scripts (ex0, ex1, etc.)

You appear to be running your investigation as root. Are you running Big Brother itself as root? If so, there may be additional requirements related to that that are causing your problems. I don't know about this, I'm just speculating. I do not run my BB daemons as root. Some specific tests I run require root privileges, but I handle that in the scripts themselves ... not by running the overall BB system as root.

VeeDubbs 04-20-2006 02:26 PM

Alright, thanks for all your help - but I think I've invested too much time on this already and am about ready to give up. Everything but e-mail is working, and although that would be nice to have - it's not a neccessity. FYI, in the file my MAIL was also set to /usr/bin/mail -s. I have not been running BB as root - i created a bb user account and it is running under that - it is set to not let it be run as root as well. I did go back as you say and deleted the bbtest.* files and no longer invoked it with ./bbtest - that is when no more bbtest.* files would show up in the /tmp directory. I think you are right - I think my install was kind of sloppy. Just curious - should this (or did it for you) e-mail notification "work out of the box" with little to no configurations?

Heres a thought - while going through all of this I have been starting and stopping the sendmail service...and at times I would be doing an Ethereal capture. And within like 11 seconds I would have easily 1000 UDP packet captures - mostly all going between my BB server and our internal DNS server.

Hopefully I can write this clear enough...originally in the install of my BB server i gave it a hostname of And by default in the /etc/resolv.conf file the first line is search So in Ethereal I am seeing DNS queries for That may be messing it up? So I changed my hostname to just bigbrother. I also put our internal DNS IP address as the second line in the /etc/resolv.conf. Anything wrong with any of that?

Also, I am seeing in my user bb's mail attempts to send the mail...but it looks as though it is failing. Here is a typical section:

From  Thu Apr 20 12:23:03 2006
Return-Path: <>
Received: from localhost (localhost)
        by (8.13.4/8.13.4) id k3KHN3Zu030905;
        Thu, 20 Apr 2006 12:23:03 -0500
Date: Thu, 20 Apr 2006 12:23:03 -0500
From: Mail Delivery Subsystem <>
Message-Id: <>
To: <>
MIME-Version: 1.0
Content-Type: multipart/report; report-type=delivery-status;
Subject: Returned mail: see transcript for details
Auto-Submitted: auto-generated (failure)

This is a MIME-encapsulated message


The original message was received at Thu, 20 Apr 2006 12:23:03 -0500
from localhost []

  ----- The following addresses had permanent fatal errors -----

  ----- Transcript of session follows -----
550 5.1.2 <>... Host unknown (Name server: host not found)

Content-Type: message/delivery-status

Reporting-MTA: dns;
Received-From-MTA: DNS; localhost
Arrival-Date: Thu, 20 Apr 2006 12:23:03 -0500

Final-Recipient: RFC822;
Action: failed
Status: 5.1.2
Remote-MTA: DNS;
Last-Attempt-Date: Thu, 20 Apr 2006 12:23:03 -0500

Content-Type: message/rfc822

Return-Path: <>
Received: from (localhost [])
        by (8.13.4/8.13.4) with ESMTP id k3KHMccA030684
        for <>; Thu, 20 Apr 2006 12:23:03 -0500
Received: (from bb@localhost)
        by (8.13.4/8.13.4/Submit) id k3HN5eEi028805
        for; Mon, 17 Apr 2006 18:05:40 -0500
Date: Mon, 17 Apr 2006 18:05:40 -0500
Message-Id: <>
Subject: !BB - 1547110! Denhart_Main.conn - 500999999999999

[1547110]  Denhart_Main.conn purple Mon Apr 17 13:54:47 CDT 2006 Connection OK
PING ( 56(84) bytes of data.
64 bytes from icmp_seq=0 ttl=254 time=0.817 ms

--- ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 0.817/0.817/0.817/0.000 ms, pipe 2

Please see:


Hopefully this gives a little more info...but like I said - I am more or less ready to give up. So, if you're sick of helping me...thanks for everything so far!

haertig 04-20-2006 03:31 PM

Here's a couple of thoughts.


while going through all of this I have been starting and stopping the sendmail service
This won't make any difference. You don't need the sendmail daemon running to send mail (kind of counterintuitive, huh?) You need the daemon running to receive or relay mail, but not to send it. Unless you have your app configured to directly run SMTP to localhost:25 This is assuming sendmail itself (not the daemon) was configured correctly in the first place. I am not an expert on sendmail.


Just curious - should this (or did it for you) e-mail notification "work out of the box" with little to no configurations?
It worked for me out of the box, but of course I had to configure those bbwarn* files. This is running on a large Solaris box, and I am not the one who configured sendmail however. But I can tell you positively that there is no sendmail daemon running - we killed this for security reasons - and BB can still send outgoing email just fine.

Earlier I said your problem wasn't sendmail. That comment was based on your report that the bbtest script did not work either (bbtest doesn't require sendmail). However, the email headers you quoted make my comment incorrect.

  ----- Transcript of session follows -----
550 5.1.2 <>... Host unknown (Name server: host not found)

Obviously BB is managing to get sendmail invoked in your case. The reason why bbtest did not work for you is probably due to some other error that we've overlooked. The point of bbtest was to see if we were getting somewhere, but not all the way to sendmail. Your email quote makes that bbtest script moot. We KNOW we're getting to sendmail, and it's failing after that. No more need for bbtest, and no need to try figuring out why it didn't work (that is irrelevent now).

Regarding your questions on DNS, I'm afraid I can't offer much help there. I do not have a local DNS setup on my home LAN (where I am the admin), and on our big servers at work we have professional sysadmins (meaning: "not me"). So while I know a little about DNS setup, I have no practical experience setting it up, so it's best if I shut up regarding DNS. I would surely lead you astray.

What I would do, to try to isolate a DNS problem in your case, is configure bbwarnrules.cfg to send notifications to your local address on the box. Not "". Just to plain old "myemail", assuming "myemail" is a valid userid on the local system. My troubleshooting thoughts being, "keep simplifying until it works, and then start backing up to see when it begins failing again". Sending stuff to "myemail" rather than "" simplifies things greatly, and may help isolate the specific problem spot that's getting you.

BTW, you give up too easily! ;)

All times are GMT -5. The time now is 02:15 PM.