= Backup Problem = Scenario will be, full backup not working or control backup not working. __Few helpful tips:__ * Check if the media is faulty is faulty or there is lock in the media. * Check to see if the tape device is detected by the system. If not try to restart to detect it. Some time you need to reinstall the driver. * #ls –l /dev/st0 ( to check the drive) * tar ztvf /dev/st0 ( with the media inside the tape, if nothing shows then tape could be bad ) * If driver problem (#lsmod >># rmmod aci…. >># insmod ac….. ) * Run the backup script in test mode with tape inside the tape device but in test mode. (# /u/cc/binl/baksys –t) == Few cool commands == #mt –f /dev/st0 staus #mt –f /dev/st0 erase '''Normal backup error message ''' Tar:/dev/st0: cannot read: Input / output error '''Notification e-mail not sent or says something else other than "Backup Successful!"''' Tag check failed: Check the log file. (usually in /u/cc/LOG/bacint.out, but to make sure check root's cron). If it looks like the backup was successful, there is a bug in the old backup scripts, wherein the tag file appears more than once, causing the comparison to fail ("tag1 tag1" is not equal to "tag1"). If there is no customisation on their backup script, just copy the more recent version from sam. No notification e-mail sent: This is still being worked out. I will update this entry when the root cause is discovered. '''Automating using cron''' Sample line in root's cron: 0 23 * * * /cc/binl/bacint -s >/cc/LOG/bacint.out 2>&1The backup script takes the settings from Control's company details and determines how to back up. '''Backup command can take several values:''' zip - store on zip or external usb drive * Script will attempt to mount "backup device" to /mnt/zip as vfat. * Backup is tar'd to the destination drive and will overwrite the previous backup if it exists. There should be at least 2 disks. Preferably one for each day. And if there are more, these can be used as "weekly" disks. burn - burn on CD or DVD media * When using RW media, this has been tested to work only with DVD-RW media, for some unknown reason DVD+RW media does not get overwritten. It does go through the motions of writing to it, but this will fail verification as the old data remains. There is no problem with using blank (brand new or manually erased) media, both - and + work just fine. * An undocumented switch "-use-the-force-luke" is needed for growisofs to force the script to overwrite the disc if there is already a filesystem in it. Without this switch, growisofs will refuse to run non-interactively (in cron or at) if it finds an iso9660 filesystem already on the disc. cpio - use cpio and write to tape tar - use tar and write to tape '''DAT72/DDS tape info''' It is recommended that DAT72/DDS tapes are used up to 100 times (read, write) and then replaced. Since our backup script writes on the tapes and reads them back once a week, this translates to replacing the tapes once a year. The most common cause of the above error is dirty heads or bad media. Try a cleaning cartridge and then use new media as the old media may be contaminated. Retensioning the tape may also improve performance. The Heads should be cleaned with a Cleaning Tape when the drive light indicates (flashing amber light). Overusing cleaning tapes is bad for the drive heads as these are abrasive and would reduce the drive's lifetime. '''LTO/DLT tape info''' LTO and DLT tapes are more robust than DAT72/DDS tapes. Laboratory tests show that even after a million passes that they are still very usable (when stored in ideal conditions). It is recommended they be retired when the soft error rate begins to increase.