Just various scripts to make my life easier:
backup.sh.1.0.2.txt
Lots of updates...read the file headers for more info...
backup.sh
Does a backup of various files or directories into a specified system directory;
Organizes backups by hostname/date/filename.tbz
'/data/BU/$hostname/2008.02.11/2008.02.11.0104.06.etc.tbz'
Can specify maximum retention days of backup files
Can copy backup to another server/drive for just in case
:#/root/bin/backup.sh help
Sourcing local settings - /usr/local/etc/backup.conf
Usage:
'backup.sh' - Full backup from defaults,
or overridden by /usr/local/etc/backup.conf
'backup.sh now /path/to/dir/or/file' - Backup only that dir/file
'backup.sh test' - Show what would be done
'backup.sh make_config' - Make custom configuration file
/usr/local/etc/backup.conf
buildworld.sh
Make building world easier and less typing;
:#/root/bin/buildworld.sh help
Usage:
buildworld.sh [and one or more of the following options:]
rmobj
buildworld [does NOT rmobj]
buildkernel
installkernel
installworld
buildall [build world and kernel-does rmobj]
installall [install kernel and world]
If using more than one option, they should be in order
mail.clean_quarantine.sh-1.3.1.txt
fix daily stats to be emailed only at 0000
put the date IP was added to $pfspammers
code cleanup
mail.clean_quarantine.sh-1.2.4.1.txt
$pfspamexpired wasn't calculated correctly [was always 0]-fixed that
mail.clean_quarantine.sh-1.2.4.txt
fix qsquarexpired to be not a static day, but today [minus] keepdays
various other code cleanup
mail.clean_quarantine.sh-1.2.3.1.txt
very minor grep string fix - grep at beginning of line only.
mail.clean_quarantine.sh-1.2.3.txt
made $grepcmd variable for easy switching of grep options
mail.clean_quarantine.sh-1.2.2.txt
clean up some code parsing...
any lines with 'localhost' were ignored, thus
'helo localhost' by spammer was causing this to fail..
mail.clean_quarantine.sh-1.2.1.txt
if fails to add spam ip to 'pf' table,
will not delete quarantined spam
for later manual check of what failed
mail.clean_quarantine.sh-1.2.txt
now it bzips the qscand quarantine.log file
ability to store custom config in $conf file
ver. 1.0
added tracking file of servers with high spam scores
using that file for later blocking with pf/ipfw/spamd/etc....
mail.clean_quarantine.sh
Script to go through qmail-scanner quarantine directory
and delete any emails over X spamassasin score;
and any quarantined email over X days old
Keeps track of sending mail servers IPs for use in
firewall tables / filtering
mail.info.sh
Script that goes through vpopmail/domains directory
and prints info of email usage/last logins
also includes some statistics
stable.sh
Script to "automate" and log updating the source tree
ports.sh
Script to "automate" and log updating the ports tree
reset.sh
Resets your terminal titlebar after you accidentally
cat a binary file and get hieroglyphics
image_index.php 1.3
now shows filesize of image
split the index body into head,main,foot
various other cosmetic code cleanups/modularize
image_index.php 1.2.1
Code clean up - link to firefox rotate image plugin
image_index.php 1.2
Some improvements, able to skip[forward|back] and view
several images at once.
image_index.php
View images [or other files] in a directory with fancy indexing
Has a forward/reverse button to go through the files
thumb.php
Takes an image and dynamically resizes it, to browser
Usage: <img src=thumb.php?image=myphoto.jpg>
Goes great along with 'image_index.php'
dup.sh 0.9
cleaned up code, do checks if output files already exist
no more need to manually disable parts of this script
output files are left intact for manual removal/reuse
added in 'maxdepth' to $findcmd to prevent directory
traversal if not required - by default goes 999 dirs deep
dup.sh 0.5
Traverses './' directory recursively and 'cksum's each file
In the end gives a list of duplicate files in $cksumresults
events.sh-0.5.txt
added support for weekly, monthly, and yearly events
some cleanup and various other improvements/fixes
events.sh-0.1.txt
this will scan through file looking for upcoming/current dates/events
this was written to not have to put up tons of cronjobs for reminders
now getting all birthdays, special dates in one file/location
and just have this one script in cron to run nightly