#!/bin/bash # # Orignal File # ------------ # http://www.Linux-1U.net/OPTRW/scripts/cdrw.mkisofs.TEST.txt # # # Write some data to the test cdrom # --------------------------------- # # # 18-Nov-02 amo Date-of-Birth # # # For simplicity... copy some directories to the CDROM # ----------------- # # ignore large directories - /usr /home # # # be sure to have enough working area to hold the 650MB of data ( iso file ) # # # be sure cd_image.iso is in a DIFFERENT directory than the $DIRs being copied # # DIR="/boot /bin /dev /etc /lib /mnt /root /sbin /var" # # # Different directory than $DIR above # ----------------------------------- OPT=/opt # # # Make an ISO Image of the tontents to be writen to the cdrom # ----------------------------------------------------------- # --exclude /home --exclude /var/www --exclude other_big_directories # # cd $OPT mkisofs -r -f -allow-lowercase -L -V 'CDROM Test' --exclude /home --exclude /var/www \ -o $OPT/cd_image.iso $DIR # # # Now try to write the ISO image to the cdrom # -------------------------------------------- # cdrecord -scanbus # # cdrecord -v speed=4 dev=0,0,0 -data $OPT/cd_image.iso # # # Now mount and read your cdrom # ----------------------------- # mount -t iso9660 -o ro /dev/cdrom /mnt/cdrom # # # End of file