- PeterMoulding.com
- Author
- Trainer
- Speaker
- Business Coach
- How to write a How To book
- PHP Courses
- Speaking
- Web Architect
- Australia
- Books
- Authors
- Akkana Peck
- Alex Berenson
- Andrew Nugent
- Ben Sanders
- Brock Clarke
- Chris Simms
- David Mercer
- Dianna Mullet
- Don Winslow
- Dori Smith
- Harlan Coben
- Jack McDevitt
- James Wines
- Jerry Yudelson
- John Grisham
- Kevin Mullet
- L. E. Modesitt Jr.
- Laurell K. Hamilton
- Marshall Karp
- Martina Cole
- Michael Marshall Smith
- Michel Roux Jr
- Nadia Sawalha
- Philip Pullman
- Raymond Khoury
- Richard North Patterson
- Robert Masello
- Sally Roth
- Sarah Langan
- Stella Rimington
- Stephen Booth
- Stephen King
- Stephen Leather
- T.C. Boyle
- Tom Negrino
- Tony Hillerman
- Urban Waite
- Val McDermid
- Valerio Massimo Manfredi
- Beginning GIMP
- Beginning Visual C++
- Culturalism
- Fiction
- A Drink Before The War
- A Talent for War
- Bag of Bones
- Blood and Ice
- Burn
- Dark Lady
- Dead Line
- Eclipse
- Empress of Eternity
- Exley
- Flipping Out
- Just One Look
- Nightfall
- Pet Sematary
- Savage Moon
- Skinwalkers
- Starvation Lake
- The Fallen
- The Gardens of the Dead
- The Jump
- The Last Templar
- The Mermaids Singing
- The Midnight Mayor
- The Secret Soldier
- The Summons
- The Terror of Living
- The Testament
- The Tower
- Under the Dome
- Virus
- AJAX and PHP
- Aging with Grace
- Food books
- Green Architecture
- Life Is So Good
- SQL: The Complete Reference
- The Backyard Bird Lover's Ultimate How-to Guide
- The Garden Gurus
- Authors
- Sustainability
- -18 hours left to decide the future of Australia
- Campbells vegetable stock or Massel vegetable stock?
- Carbon Sequestration
- Carbon tax for Australia is a fraud
- Copenhagen will fail
- Cost of living in Australia
- Dick Smith jumps on the population bandwagon
- Dry Run: Preventing the Next Urban Water Crisis
- Energy Saving Lights
- Garlic
- How many people can live in Australia?
- Its obsolete, throw it out!
- Julia Gillard offers 9.9 billion dollars bribe to Rob Oakeshott
- Laundry detergent
- Petrol or Diesel?
- Reflective foil batts kill
- RoHS
- Sea level to rise 3mm due to climate change
- Solar power
- Spring again in Sydney
- Sustainable fuels
- The CRUD Tax is back
- The people who make building regulations do not own houses
- Water efficiency
- Which insulation is safer, foil or wool?
- Will Australia reduce greenhouse gas emissions?
- Technology
- Android or Blackberry or iPhone or a flip phone?
- Apple versus Google 2011
- Cameras
- Cars
- Colour
- Burgundy
- Colour Blindness
- Colour Names
- Dulux colours
- Pantone colours
- Safe Colours
- Seculine ProDisk Mini colour balance card
- What Causes Colour Blindness?
- Hardware
- Batteries for the Digital Age
- Cables
- Cases
- Computer reliability
- Computrace
- Disks
- Astone ISO Gear 481E
- Best SSD for your notebook computer
- Disk block size
- Hitachi disk HDS722020ALA330
- LaCie USB 2.0 250 GB mobile hard drive design by F.A. Porsche
- SMART disk
- Samsung 2 TB HD204UI quiet low power disk for mass storage
- Seagate and Samsung merge disk business
- Select the right disk for your RAID array
- USB disk speed
- Western Digital WD20EARX 2 GB SATA 3 disk
- How long should computer hardware last?
- Keyboards
- Mainframe
- Memory cards
- Monitors
- Netbooks, notebooks, tablets, and xPads
- Network Attached Storage
- OLED Displays
- PC's are a thing of the past
- Printers
- Quiet
- Samsung Galaxy S
- Speed
- Television
- Tools
- USB
- Worst computer movies
- Xserve is dead. What next?
- Your backup will not work
- Z68 motherboards
- iPad or Acer Aspire One?
- IQ
- LG Intello Washing Machine
- Lack of a challenge
- Networks
- 802.11n wireless networking
- D-Link DIR-655 wireless router
- D-Link DWA-160 Xtreme N dual band USB adapter
- D-Link DWA-556 Xtreme N PCI Express desktop adapter
- MIMO
- NBN spends another $12 billion of our tax money on nothing
- National Broadband Network
- Netgear wireless modem router DGND3300 with 300 Mbps 802.11n
- Refrigerator kills wireless broadband
- Small Wireless Network
- TP-LINK TL-SG10005D 5 port gigabit switch
- TP-Link TL-WR1043N wireless N gigabit router
- Telstra Pre-paid Mobile Wi-Fi
- Where are the router plus proxy server combinations?
- Open Source documentation
- Software
- 7-zip
- Accounting
- Asterisk
- Audacity
- Backup software
- Bloat only in Windows
- CAD
- CDex
- Disk imaging software for copying and backup
- Exact Audio Copy
- Filezilla
- Firefox
- Java
- LibreOffice or OpenOffice?
- Linux
- 1 in 5 servers will ship with Linux
- Android phones outsell iPhone
- Another Move to Linux
- CentOS 5.5 installation on SSD and RAID 5
- Debian
- Debian 5.0.5 AMD64 installation
- Debian 5.06 installation
- Fedora
- Fedora or Ubuntu?
- Gnome or KDE?
- K9copy
- Linux 2.6.38
- Linux Gnome login settings lost
- Linux Mint
- Linux RAID, a rant
- Linux Speed
- Linux Time
- Linux reliability as demonstrated by Ubuntu 10.10
- Linux reliability as demonstrated by Ubuntu 11.4
- Linux still a struggle in 2011
- Linux workstation disk RAID 1
- Linux, NT, Windows, and SETI
- Linux, three years of progress
- London Stock Exchange switches to Linux
- Mandrake Linux 9.2
- The partition is misaligned by 48128 bytes - warning from Linux RAID
- Ubuntu
- How to fix the scroll bars in Ubuntu 11.4 Gnome
- Kubuntu 10.10 alternate installation on desktop with RAID 1
- POWbuntu
- Ubuntu 10.10 after 6 months use
- Ubuntu 10.10 alternate installation
- Ubuntu 10.10 desktop RAID 1
- Ubuntu 10.10 desktop RAID 5
- Ubuntu 10.10 desktop install on a netbook
- Ubuntu 10.10 desktop installation
- Ubuntu 10.10 netbook install on a netbook
- Ubuntu 10.10 server AMD64
- Ubuntu 10.10 upgrade to version 11.4 beta 2
- Ubuntu 10.4
- Ubuntu 11.10
- Ubuntu 11.10 first upgrade
- Ubuntu 11.4 after one month use
- Ubuntu 12.04 beta1 desktop amd64
- Ubuntu One
- Ubuntu by Microsoft?
- Ubuntu desktop upgrade 10.4 to 10.10 failed because I did not check the media
- Ubuntu strikes again
- Upgrade Ubuntu to Linux Mint 12 LDXE for extra speed
- Yes, use Linux but not that distribution!
- Nero
- OpenOffice
- OpenOffice is now Apache Office
- Project management
- Scribus
- Software for Windows and Linux
- Text editors
- Time
- Todo applications
- Tomboy notes
- Top text editors
- Version control
- VideoLAN VLC media player
- Visio
- Webmin
- Webmin installation on CentOS for Web development
- Webmin installation on Ubuntu
- What is the most popular open source software today?
- Windows
- Another Windows person goes Linux
- BAD_POOL_CALLER
- Cygwin
- Microsoft Malicious Software Removal Tool cannot find a common virus
- One of the developers of Windows XP is criminally insane
- There are unused icons on your desktop
- W32time
- Which Windows version?
- Windows 7 Home Premium
- Windows XP Stop 0x0000007B during installation
- Windows XP is a disaster
- Windows processes
- XML
- Zip, bzip, gzip, or 7zip?
- configFree
- Technology Succession Planning
- VoIP
- Web Sites
- Drupal
- Do Drupal themes have to use the GPL?
- Drupal 7
- A better search facility for Drupal
- Drupal - performance or flexibility
- Drupal 7 Fields are hard to fix
- Drupal 7 new features
- Drupal 7 ships on January 5
- Drupal 7.14
- Drupal 7.4 hits PeterMoulding.com
- Drupal function sequence
- The evolution of a module
- Undefined index: headers in DefaultMailSystem->mail() (line 54 of /modules/system/system.mail.inc).
- Undefined index: to in DefaultMailSystem->mail() (line 83 of /modules/system/system.mail.inc).
- implode(): Invalid arguments passed in DefaultMailSystem->format() (line 23 of /modules/system/system.mail.inc).
- Drupal 8
- Drupal Code Load Cut
- Drupal How To
- Drupal Modules
- Backup and Migrate
- Browscap
- CKEditor with Drupal WYSIWYG
- Captcha
- Cel
- Colorbox
- Content Construction Kit
- Content type
- Devel module for Drupal
- Drupal Rules as an automation language
- Drupal Spam add-on module
- Form alter to node
- IMCE
- IMCE Wysiwyg bridge
- ImageAPI
- Jdog
- Lightbox2
- Module variable
- Node Gallery Access
- Node_Gallery
- Path
- Path redirect
- Pathauto
- Pet
- Search
- Service links
- Session Variable
- Statistics
- Taxonomy
- Token
- Token ex
- Transliteration
- Trigger
- Watch
- Other modules
- Drupal Training
- Drupal access controls need a major rewrite
- Drupal coding tricks
- Drupal performance
- Drupal themes for the future
- Drupal.org colours
- Import existing data into Drupal
- Multiple Web sites made easy using Drupal multisite and the right start
- drupal_lookup_path()
- Adobe PDF
- Apache
- Apache Mahout
- Audi.com
- Bleet
- CSS Strikes Again
- CSS or xCSS
- Can you believe Facebook or email?
- Content Management Systems
- Databases
- Facebook scam
- Font
- Fonts
- HTML
- Install Apache, MySQL, and PHP 5 in Ubuntu 11.4 using the Ubuntu Software Centre
- Language Codes
- Marketing
- Memcache
- Nginx
- Open source development hits another roadblock
- Oscars
- PHP
- SPDY
- Search software
- Techoni.com.au
- Theme themes
- Things to hate on Web sites
- U.S. Patent No. 6,985,875
- Virtual Private Server
- Visible Improvement
- Web 4.0
- Web browser usage
- Web browsers
- Web site development
- Bluefish
- Crying over spilt code
- Eclipse and PHP
- Getting a Git client, a story of ancient technology and pain
- HTTrack
- MVC
- Netbeans
- PHP or ..., CakePHP/Symfony/ZF versus ...
- Programming
- Superfish
- Web browser emulators for testing your Web site
- Web development frameworks
- Web site books
- Web site development on your own computer
- Webmin or phpMyAdmin or cPanel for creating databases?
- aiki framework
- jQuery
- Views development - Learn Fields first
- Views development - Learn Actions and Rules
- jQuery .each()
- jQuery .has()
- jQuery .is()
- jQuery and Firefox Firebug
- jQuery children
- jQuery for people not using Drupal - Installation and getting started
- jQuery hover
- jQuery hover de-duplication example
- jQuery or CSS?
- jQuery performance
- jQuery tests
- Web site hosting
- Westpac Web site still broken after two years and ten months
- Wordpress wins another CMS survey
- Drupal
Big Brother
Submitted by Peter on Tue, 2002-04-30 00:00
Big Brother, bb4.org, monitors computers and peripherals with a mixture of C based programs, shell scripts, Perl, HTML, and PHP. The PHP bit is the focus of this page. UpdateBig brother used to be a low cost way to monitor your computing infrastructure, especially Web sites and Web servers. Now all the useful features are in a commercial version and the free version is almost dead. Look at Web site monitoring for modern alternatives.
Download Big Brother from bb4.org.
Web sites
Web sites are built on layer after layer of software and hardware. Any layer can break for a dozen reasons. Big brother can detect when some of those layers are approaching some of those breaking points.
You can only monitor all the breaking points if you have Big brother running in a local network attached to your server. Big Brother is almost useless to you for hosted Web sites and Virtual Private servers because the hosting company have to run the monitoring program. They might run Big Brother, an open alternative, or software provided by their hardware or operating system supplier. Make sure they have some monitoring and find out how often they monitor.
Servers depend on power, cool air, and the engineer sent in to fix a hardware problem will need light. A backup power supply that keeps the computer going but not the air conditioning is useless. You do not have a way of fixing the problem and someone to fix the problem outside of normal operating hours. There is a distinct advantage of detecting things approaching a breaking point so you can repair the problem on your schedule. You set the monitor to disks running out of space then clean or replace the disks before they fill up. Smart air conditioners can tell you when filters are starting to clog up. Emergency power supplies can report failing batteries.
To get the maximum advantage of system monitoring, you have to work backward from your web site to the concrete foundations of your data centre looking for breaking points and ways to predict them. Life is far easier if you use a professional data centre with complete infrastructure monitoring for power, air conditioning, fire, and disk failures. You rent their servers or supply your own with them hooking their monitor in to monitor your server hardware.
Central monitor
The C based central monitor, named bbd, is supplied as source or binaries for various operating systems. The software is free for non commercial use. There is a client written in C and named bb. Bb talks to bbd across your network using network port 1984. The monitor scripts feed data in to bb and bb passes the data to bbd. bbd converts the data to HTML for display in your Web browser.
Setup is easy if you know your systems in great detail and are an expert at shell scripts. You cannot easily monitor application activity with shell scripts so it makes sense to reproduce some of the monitoring in other languages. I contributed some PHP code for people already using PHP.
PHP is used as a Web scripting language and a conventional programming language across many operating systems. I use PHP on NT, Solaris, Linux, Windows 2000, and several variations of Unix. PHP release 4 is as fast as the best of Perl and Java while remaining a lot easier to learn.
If you have not used PHP outside of a Web server, install the PHP CGI module, write a quick PHP script, then try
/php/php.exe -q smallpage.html
Change php.exe to the name of your PHP CGI module. Change /php/ to the path to the PHP CGI module. Use -q to remove the default HTTP headers. Change smallpage.html to the name of the file containing your PHP script. The script couple be as simple as
<?php print('hello'); ?>
The enclosed PHP scripts for Big Brother require the socket functions in PHP 4.1.2 or later. You probably already have at least release 4.1.2 as 4.1.2 has a useful security update.
The scripts also use POSIX commands available in most distributions of Unix and Linux. For NT and Windows 2000, just install the POSIX commands from Cygwin.
Install Big Brother on a server that contains a Web server. Get the basic Big Brother displaying the introductory screens then click on the information screens. There is a big page on configuration and writing your own monitors. The enclosed PHP code fits the requirements described in the help pages.
You will see that monitoring can be extended from the first server to other computers by installing a program named bb on the other computers. You then install or write shell scripts to feed data through bb to the central server. The enclosed PHP code replaces some of those shell scripts. The enclosed bbsend.class is a PHP class to replace the bb program so you can have a pure PHP based solution anywhere PHP is installed.
The BB example scripts cover hardware and system basics including disk space, CPU time, and service availability. The quickest way to collect that type of data is to run a system command then process the output of the system command through a script. The PHP performs the same work as a shell script, is easier to learn, does not require external programs to process the text, and in the later releases can write direct to the BB server without requiring the bb program. That means one less language to learn and less processing overheads.
If you do have a shell script writer handy, let them install the central BB monitor then deploy PHP on all the other machines.
Now for the brilliant part. Shell scripts are of no use when you are deep within a PHP application and you find a file has a problem. That is a good time to let PHP talk direct to BB. Take a PHP script that performs administration of passwords and has a master passwords that expire every week. You could write the password access code so it sends a message to BB saying the passwords are working. When the passwords are within days of expiring, send BB an alert warning that the passwords are close to expiring. BB will pop up a yellow screen and optionally send out email messages alerting people. When the passwords are within a few hours of expiring, send out a code red alert. BB responds to code red alerts with more email and steps up to SMS messages to wake people up.
You program or Web page can call your Help desk via BB. Your application problems become as important as any hardware problem. Do you wonder why the help desk people dive in to the computer room at the first sign of smoke rising from an over worked server but ignore your application problems for days? Watch them react when your application alert makes BB calls them on their mobile phone every five minutes all day and all night.
BB lacks historical charting of trends but there is software you can add on to produce the charts. There are a wide variety of extra shell scripts at deadcat.net.
Here are some PHP files you need. Download big_brother_bbsend.class (3.69 KB) to add the equivalent of the bb client to your PHP code. Download big_brother_df.zip (656 bytes) to get df.php, a PHP script that transforms the output from the df command then transmits the result via bbsend.class. df.php is a good example of using bbsend.class. Download big_brother_procs.zip (2.9 KB) to get procs.php, a PHP script that lists processes using ps then transmits the result via bbsend.class. There are options to highlight processes that are running or not running.
You will notice bbsend.class looks a lot like the PHP mail function. That was a design decision based on the fact that many applications currently send email to help desks but cannot perform escalation or create trouble tickets. I made bbsend.class an easy replacement for the email. BB escalates a problem if an alert receives no response so BB adds value to a straight email based alert system. BB could create a trouble ticket in a PHP based trouble ticket system. phpGroupWare has an easy to use trouble ticket system.
Send your questions about BB to the BB mailing lists mentioned at their site. Send questions about shell scripts to whoever wrote the shell scripts. You can send email about my PHP scripts via the following form. Note that I no longer work on a BB server project so will not be able to test scripts for a while.
Conclusion
Big Brother is the best value system monitor for mixed systems. If you all your servers are from IBM or from HP, you might want to use their monitoring systems. For everyone else, there is Big Brother.









Comments
What about Nagios? I've
What about Nagios? I've seen some ISP and others that use it quite effectively. Would you say that Big Brother is better? If so, why do you think so?
Good choice today
Nagios looks like a good choice today. I have not used it as it was not ready for production use when I needed a product and it did not support monitoring of Windows based computers from within those computers, which was a limitation in a mixed environment.