rs@mirror.UUCP (Rich Salz) (07/22/86)
Last week, three sites I feed stopped calling for a couple of days. A queue listing showed between 300 jobs queued up for one notes site, 150 for another, and 2300 for a news site. We run the standard 4.2BSD UUCP, with has separate C., X. directories, but not separate directories for each site. Well, I really wanted to get those clogged sites out of my UUCP spool directory, so I wrote the following little script; others may find it useful, but will want to change the hardwired "mirror" below. #!/bin/sh ls C. | egrep C.${1?WHAT_SITE} > list.$1 mkdir ${1?WHAT_SITE} $1/C. $1/D.mirror $1/D.mirrorX cat list.$1 | while read FILE ; do awk ' \ NR % 2 == 0 { print "D.mirrorX/" $2 } NR % 2 == 1 { print "D.mirror/" $2 } ' <C./$FILE >>list$$ mv C./$FILE $1/C. done cat list$$ | while read FILE ; do mv $FILE $1 done exec rm list$$ -- ---- Rich $alz {mit-eddie, ihnp4, wjh12, cca, cbosgd, seismo}!mirror!rs Mirror Systems 2067 Massachusetts Avenue Cambridge, MA 02140 Telephone: 617-661-0777 "Hi, mom!"