tomclegg.net


Diary
Examples
Hire Tom
Mostly Mozart
Patches
School
Scrapbook
Software
  >allaboutme<
    byteswap
    checksocks
    djbdns-ipv6
    dsprec
    fresnel
    fresnel
    logger
    mail-transport-agent
    maildirpop3d
    mp3cat
    qmail-bmf-wildcard
    rawrms
    stationbreak
Telephones




colocation
comments
davidireland
edsgranola
faq
funsites
goodlooking
goodmovies
google-earth-saucy-amd64
houserules
liberating
resume
resume2
scratch
shopping
snacks
todo
university
warisbogus

allaboutme
Posted February 2, 2004

Display some critical configuration files. Keep a copy of this output, and refer to it later when building similar systems (or replacing the system after a hard disk disaster).

Feature

  • Replaces your domain name (everything following the first period in your hostname) with example.com

How to install

  1. Copy and paste the program (below) into /usr/local/bin/allaboutme.
  2. chmod +x /usr/local/bin/allaboutme

How to use

allaboutme | mail -s "`hostname`:allaboutme" your_email_address@example.com

The program

#!/bin/sh
date
echo
domain=`hostname | sed -e 's,[^\.]*\.,,'`
kernelname=`uname -v | sed -e 's,.*/,,'`
(
uname -i -s -r -p 2>/dev/null || uname -s -r -p
echo
ls /var/db/pkg
echo
ls -ld /service/* | sed -e 's,[^/]*,,'
echo
head -n 40000 \
 /boot.config \
 /etc/fstab \
 /etc/rc.conf \
 /etc/firewall \
 /usr/local/etc/firewall \
 /usr/local/etc/rc.d/*firewall.sh \
 /etc/hosts \
 /etc/*.local \
 /etc/ssh/ssh_config \
 /etc/ssh/sshd_config \
 /etc/mail/mailer.conf \
 /usr/local/etc/supfil*[^~] \
 /etc/dhclient.conf \
 /usr/local/etc/dhcpd.conf \
 /usr/local/etc/cvsup/config.sh \
 /var/service/*/run \
 /var/service/*/log/run \
 /var/qmail/control/*[^~] \
 /etc/passwd \
 /etc/group \
 /usr/local/etc/rc.d/md.sh \
 /usr/local/etc/rc.d/vn.sh \
 /usr/src/sys/i386/conf/$kernelname

) | sed -e "s,$domain,example.com,"