Archive

Posts Tagged ‘sysadmin’

Weekly errata Report for YUM based machines

October 10th, 2009 1 comment

I had a request the other day at the Utah Open Source Conference to share a very small script that I have that checks for, and reports any available updates on a YUM based machine. This means CentOS, RHEL, Fedora, etc. I have been using this script at work for some time now and, by placing it in the /etc/cron.weekly/ directory, it reports to me on what packages are available for update. I find this to be a simpler solution than manually checking and trying to keep on top of all of my machines all the time.

I have outlined two revisions of this script below. The first one has properly formatted reports, the second one only reports if there are available updates. I would like to combine the functionality, but I’ve only briefly looked at doing so.. and I don’t feel like doing it now.

If anyone has any other solutions, or perhaps an official program with the same functionality I’d love to hear about it.

/etc/cron.weekly/check-update.sh – revision #1

#!/bin/bash
#
# Weekly check-update report
#
usr/bin/yum check-update > /tmp/.check-update
cat /tmp/.check-update | mail -s "Errata Report for $(hostname)" admin@example.com

/etc/cron.weekly/check-update.sh – revision #2

#!/bin/bash
#
# Weekly check-update report
#
MESSAGE=$(/usr/bin/yum check-update)
if [ $? -eq 100 ]; then
echo ${MESSAGE} | mail -s "Errata Report for $(hostname)" admin@example.com
fi

Presenting at the Utah Open Source Conference 2009

September 9th, 2009 No comments

I was just going over the schedule for the upcoming Utah Open Source Conference and I realized that I’ll be presenting one month from today! On Oct 9, 2009, the second day of the conference, I am scheduled for two presentations.

The first is a beginner / intermediate presentation regarding GNOME customization and making use of the gconf tool. You may want to see some of my previous posts here, here and here on the subject. I use the gconf tool anytime I setup a new machine to automate the user interface customization that I’ve grow accustomed to. I’ll be outlining how to find, document and script these customizations for future use.

The second (which happens to be directly after the first!) will introduce and demonstrate 10 of my favorite “required” sysadmin tools. These include tools like tcpdump, ssh and rsync, screen, vim, netstat and more. I imagine this one will be helpful for anyone doing system administration. Hopefully I’ll have a tip or two for everyone!

For more information about the conference, please visit the website. Registration is still open and we’d love to see you there!