Sun-microsystems MEDIACENTER 2.1 Manual de usuario Pagina 88

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 184
  • Tabla de contenidos
  • SOLUCIÓN DE PROBLEMAS
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 87
5-16 Sun MediaCenter Server Administrator’s Guide December 1997
The following script locates a specified content title from a previously-created
SMCBackup.date file. It then prompts you to load the appropriate tape to restore the
archived title from the locally-mounted /dev/rmt/0 device.
#!/bin/ksh
# smc_restore: Script to restore an SMC backup
usage() {
echo "usage: smc_restore [-c ContentsFile] [title]+" >&2
}
printNumber() {
case $1 in
*1)echo "$1st";;
*2)echo "$1nd";;
*3)echo "$1rd";;
*) echo "$1th";;
esac
}
date=`date +%Y.%m.%d`
inputDevice="/dev/rmt/0"
contentsFile="SMCBackup.$date"
if set -- `getopt "c:" $*`; then
while [ $# -gt 0 ]; do
case "$1" in
-c) contentsFile=$2;
shift 2;;
--) shift;
break;;
-*) usage;
exit 1;;
*) break;
;;
esac
done
fi
for t in $*; do
found=false;
grep $t $contentsFile | while read date tape fileNumber title; do
echo "$t is the `printNumber $fileNumber` title on the `printNumber $tape`
tape created on $date"
Vista de pagina 87
1 2 ... 83 84 85 86 87 88 89 90 91 92 93 ... 183 184

Comentarios a estos manuales

Sin comentarios