Linux

Get the current weather

I made a little Perl script that will get the current weather from the National Weather Service and display it in nice, readible form. It uses the Geo::WeatherNWS Perl package to do the dirty work, so you'll need to edit that. You can just supply it with an ICAO designation code. (Hint, they're 4 letters long, so prefix your local U.S. airport with "K" to make one.) To find a local ICAO code, go here:

http://weather.gov/tg/siteloc.shtml

This is still very much version 0.1, so hopefully I'll make some additions.


#!/usr/bin/perl

Backup scripts for MySQL

I just created a generic backup script to backup selected MySQL databases. It uses the mysqlhotcopy script that comes with MySQL. It's not all that great, but in case it's useful to SOMEBODY, I thought I'd post it here. This example just backs up the mysql database itself, but obviously you could just change the DBNAME to back up some other database.

You'll probably want to edit the ultimate destination of the backups. I put them in /usr/backup.

-----------------------------------------

#!/bin/sh

# Custom backup script by Ben
#
# This will back up the selected databases and gzip the results. It will then
Syndicate content