+device=$(mount | grep "on ${mountdir%%/} " | awk '{print$1}')
+
+if [ -z "$device" ]; then
+ echo >&2 "Cannot determine cdrom device"
+ exit 1
+fi
+
+cp ${mountdir%%/}/backups.db ${mountdir%%/}/backup-status.txt $rundir
+dbfile=${rundir%%/}/backups.db
+
+dates=$(cat $dbfile | list-dates.sh)
+
+for date in $dates; do
+ success=false
+ while ! $success; do
+ eject $device
+ echo >&2 "Please insert backup disk: $date"
+ read bogus
+ eject -t $device
+
+ # Mount the media
+ mount -t ext2 $device ${mountdir%%/}