Linux (Probably Unix-Compatible) Projects
As the network administrator of a sizable home office (7
servers, 3 workstations, Cisco routing, LinkSys wireless, 3
subnets), you sometimes find that you create tools that just
might be generally useful, as in, by other people. William
shares his efforts here in the spirit of Free Open Source.
Please remember to give credit to William if you use or
redistribute any of this material!
William's collection of Linux projects:
- NIGHTLY BACKUP SCRIPT (v.1.4):
There are about as many solutions for automated nightly
server backups as there are people running servers. This is
just one more. William took this opportunity to learn Linux
shell scripting on RHEL4/CentOS4. He bought a book (ISBN: 0-
596-00595-4) and cranked this solution out after reading the
first hundred, or so, pages in just two days. The result is
an automation script which archives your system critical
files to an off-host share, while preserving the integrity
of those files by stopping and restarting system services
that may have those files open. William used to run very
primitive interdependent shell scripts to do this work in
the past (which did little more than copy files to
alternative directories, then compress the result) and he
decided to levy his professional programming experience to
the task in order to produce a more dynamic solution. There
are two files involved:
- The
ZZbackup script file which should live in
/etc/cron.daily/. This beastly script file is fed by
user preferences (edit within the head of the source)
and the following external list file.
- The backup
file and directory list which should live in
/etc/ (as /etc/backuplist and not
/etc/backuplist.txt). This is the bottle that feeds
the ZZbackup script. Whatever file and directory
names you put in this file will get backed up. This is
a sample file. You must tailor this file to your own
specific needs for this solution to provide maximum
benefit to you.
- SERVICE CONTROL SCRIPT (v.1.0):
This script
compliments ZZbackup.cron and (as of version 1.3) is
mentioned in the documentation for the RUN_*_BACKUP options.
If you have services that are not hooked by /sbin/service
(i.e.: you have to manually configure them to start at boot
by editing your /etc/rc.d/rc.local file), or you don't have
/sbin/service (Debian users) take a look at this sample
script. The version here illustrates how you might use it
for enabling service-like control over my popAuth3 or
Frank Denis'
pure-ftpd. Save this
script file as
/usr/local/sbin/service-control. Note that
the presense of this file does not negate the need to keep
those entries in your rc.local file, although you could
change those entries to call this script instead of the
deamons directly. :)
- MTA HARDENING AGENT,
popAuth3
(v.3.0.1): (the following text was copied from William's
http://popauth.kimballstuff.com/
) In summary, popAuth3 is a derivative of popauther -- a
simple POP-before-SMTP utility
adapted by William R. Thomas of a
concept by John Levine -- and an extension of your MTA
for a stronger anti-UCE stance. popAuth3 is a
complete rewrite of
Harlann Stenn's adaptation of
William R. Thomas' popauther source and it does MUCH
more than just POP-before-SMTP relay authentication. In
essence, popauther's core is a log watching utility that
triggers actions based on events identified in the real-time
maillog facility. From this vantage point, popauther takes
action based on any activity exposed in the maillog, which
could original from disparate sources (SMTP, POP3,
IMAP, etc).
Contributing Authors:
William Kimball
Problems with this page can be reported via e-mail to:
<wwweb at kimballstuff dot com>
Last modification date: $Date: 2007-02-14T17:00:12+07:00 $