# Backup to CD/DVD

• Bring a blank CD or DVD to the lab
• Follow all the instructions it gives you

You're Done!

While I make regular backups of the home directories on the Computer Science unix machines there are times when you want to have your own copy of your account. There are several relatively painless ways to accomplish this task. On this page I describe creating a CD or DVD image. If you need my help, please ask. If you know of a way I could describe this process better please let me know so I can share it.

The processes consists of making a cd image of your home directory and then either burning that image onto a CD or DVD in the lab or moving that file off our system to some other place where you can burn that image onto a CD or DVD.

The image we will create will be in iso9660 format with Joliet directory records in addition to iso9660 file names. This type of image can then be burned onto a CD or DVD or even mounted directly on a wide varity of operating systems including but not limited to MacOSX, Solaris, Linux, Win2k and WinXP.

For the remainder of this document I will be referring to the image file we are going to create as an iso image.

What commands you will use:

• our in-house isohome.script command script
• the ssh command
• if you are not burning your disk in the lab you will use scp to move the image to another system
• finally clean up with the rm command

Mkisofs (make iso file system) is a great command. It creates iso9660 images. However, it takes lots of options so I have simplified the process and written a wrapper for it. (Lucky you!) It is called isohome.script.

isohome.script expects to be run on the machine where your home directory actually resides as this saves mkisofs having to send your entire directory back and forth over the network. Log onto your CS account and issue the command isohome.script. If you are not on the true home of your files you will be told which machine to log on to and given the command you need by isohome.script.

Once you have ssh'ed to the correct machine enter the comand isohome.script at a command prompt:

isohome

The script will take it from there occasionally asking for confirmation to continue.

isohome.script makes a number of choices for you. For example it skips any file that it thinks is a backup file as indicated by ending in a tilde or a number sign, it also skips any file ending in '.iso' and any file or directory with the string 'cache' in its name.

If you are on campus the easiest way to make the image into a CD or DVD is to burn it in the Advanced Lab. This is because the file is already in your account so it does not have to be moved, you only have to put in blank media and issue the command to burn the image to that media.

• Press the button on the CD/DVD tray to open it (the real button on the actual tray).
• Put in your blank media. (You remembered to bring some didn't you?)
• Open a terminal.
• Find the name of your backup file. It will be in your home directory named YOUR_ACCOUNT_NAME-home-YEAR-MONTH-DAY.iso as in “tegorman-home-2004-05-10.iso”
• Issue the command “wodim” followed by your backup file, as in: “wodim tegorman-home-2004-05-10.iso”.
• The image of you files will be burned onto the media. If it is not, please email me and include any output from wodim.
• Continue with cleanup bellow, please don't forget this step.

If you can't get to the Advanced Lab you need to copy the iso image of your account to a system with a CD or DVD burner you can use. To do this you will be using scp, to copy it to another system. You will most likely want to do the copy from the other system. Please consult the documentation for scp on that system. For operating system specific help and links for scp software see http://www.cs.vassar.edu/SysNews/ssh. The file you are copying will be in your home directory named YOUR_ACCOUNT_NAME-home-DATE.iso as in “tegorman-home-2004-05-10.iso”

From there burn a CD/DVD following the instructions for doing so on that system (beyond the scope of this Document).

Once you have burned it in the lab or copied the iso to another location, please remove the file from the CS machines. We do not have space to to keep an image of each persons account on disk, that's why I do backups to tape! To remove the file, use the rm command:

rm /home/tegorman/tegorman-home-2004-05-10.iso

You can now sleep easier knowing that you have your own copy of all your files. Should the need arise, you can restore any or all of them on our or another system.

More information on mkisofs and it's replacement genisoimage is available in from the man page:

Man page for genisoimage Unix manual page format, genisoimage help.

This page was written using emacs and psgml mode with an HTML 2 DTD, then in 2008 it was converted with html2wiki into dokuwiki format and touched up in the dokuwiki editor. If you have any questions or comments about it, please write me. -Greg — Greg Priest-Dorman 2009/10/14 13:22