- Find the size of your account: /usr/afsws/bin/fs lq
~
- Purchase one CD-R or CD-RW disc for every 650 MB of
data. You may want to purchase a second CD-R disc, in case
there are problems with the first disc you create.
- Find out how much free space is available in
/tmp:
df -k /tmp
- If the space available in /tmp is more than
the amount that you need you may proceed. If not, either wait,
or send mail to lab@cs.wisc.edu to report
the problem.
- Create an image of your home directory with the
mkisofs command (note that this should be one
line):
mkisofs -a -A Application-Description -f -J
-r -V USERNAME -o /tmp/USERNAME.iso PATH_TO_DIRECTORY
for example:
mkisofs -a -A joeuser_cs_account_spring_99 -f -J
-r -V joeuser -o /tmp/joeuser.iso ~joeuser
mkisofs has several options. Here are the
options we have tested, and a short explanation of each:
- -a
- includes all files in the
archive. Normally files that contain the charaters
~ or # will not be included
- -A Application_id
- Specifies a
text string that will be written into the volume
header. There is room for 128 characters. We recomend
putting your name and the date of the archive, for example
joeuser_cs_account_spring_98
- -f
- causes symbolic links to be
"followed" and replaced by hte contents of the file. Without
the -f flag, the symbolic link will be preserved,
but the contents of the actual file will not be archived if
it is not in your directory.
- -J
- uses the Joliet extensions,
so that long file names are visible on Windows NT and
Windows 95/98 systems.
- -r
- Use the Rock Ridge
extensions and change all file ownerships
and modes to be more useful:
- The uid and gid are set to zero,
because they are usually only useful on the original
computer system, and not useful on the computer where the
CD is mounted.
- All the file read bits are set to true, so that files
and directories are globally readable when the CD is
mounted on a new system.
- If any execute bit is et for a file, set all of the
execute bits, so that executables are globally executable
when the CD is mounted on a new system.
- If any search bit is set for a directory, set all of
the search bits, so that directories are globally
searchable on the CD.
- All write bits are cleared, because the CD-Rom will
be mounted read-only in any case.
- -V Volume-name
- Specifies a
volume name for the CD. We recommend your username.
- -o /tmp/USERNAME.iso
- specifies
the output file (cd image file). Use your username instead
of USERNAME.
- path_to_directory
- specifies the
directory to archive (your home directory)
for more information on the options and flags of the
mkisofs command type man mkisofs
- Wait for this command to complete. This is the most time
consuming step of the process, and takes approx. 20 minutes
for a 70MB directory
- Place the CD-R or CD-RW media in the CD-RW drive.
- Use the cdrecord command to write the iso image
to the CD-R or CD-RW media. The speed that you specify
is a function of both the maximum speed of the drive and the
maximum speed of the media. For CD-R media, you should be
able to specify a speed of 8. For CD-RW, you may not
be able to specify a speed in excess of 4:
cdrecord fs=12m speed=4 PATH_TO_ISO
For example, if you followed the suggestion above and used
mkisofs to create the iso in
/tmp/joeuser.iso, the command would be:
cdrecord fs=12m speed=4 /tmp/joeuser.iso
There are many other options to cdrecord. For
more information, please see the cdrecord man
page by typing man cdrecord.
- Test the CD:
% mount /mnt/cdrom
% ls -l /mnt/cdrom
% umount /mnt/cdrom
If the mount fails or the ls command doesn't return the
contents you expect, there may be a problem with the either
the disk, the ISO image, or the writing process.
- Remove the iso image you created with mkisofs, for example:
rm /tmp/joeuser.iso