Unit Testing and System Administration

Unit tests are a programmer’s best friend – they help the programmer to fix bugs and keep them fixed, by continually testing to make sure that the bug is fixed.

In administering a system, certain services must be available, and certain products must be installed and configured. Install processes like HP-UX Ignite or Solaris Jumpstart can help, as can products like cfengine.

However, a unit test environment can be of great use to make sure that all went according to plan. Nagios is the best known of these – yes, a unit tester. Consider: do you need NFS? Test for an NFS volume. Do you require a database to be up? Check via TCP that the server’s connection is available.

In addition, if you’ve bounced a server only to find that you forgot something: create a unit test for it (that is, create a check in Nagios). If an active check won’t work, use a passive check: a check that runs on the server and reports back to Nagios.

If you continue to add checks as you think of them or encounter trouble, eventually you will find that you are much more in tune with your servers. Don’t forget to add NagiosGrapher to get the benefit of performance history too. With both Nagios and NagiosGrapher, you’ll be all set.

Powered by ScribeFire.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: