📄 readme.graft_dirs
字号:
# @(#)README.graft_dirs 1.1 00/01/12 joerg#This is from "Eduardo M. A. M. Mendes" <mendes@mgconecta.com.br>Creating multi-session CD's with dir=/ feature Micro HowtoThis mini-howto was written as guide to help me to create multi-session CD'swith the possibility of determining the location of files. I hopethat this guide helps you too.In order to use cdrecord it is first necessary to define to which scsi busthe cd-writer is connected. In my case the setup is dev=0,3,0. It is alsointeresting to have a separate directory in which all image files canbe dumped: /home/cdsource is the directory I chose for dumping the images.The best way to understand how to create multi-session cds is to readREADME.multi. Most of what is going to be said here is based on thatREADME file and on the help of several cdrecord users. This Micro Howto is divided into two parts as follows:Example a) A dir/=/dir1/dir2 exampleExample b) A dir1/dir2/=/dir3/dir4 and dir1/dir2a=/dir5/dir6 exampleWe are now ready to start.Example a) An dir/=/dir1/dir2 exampleA simple example will demonstrate that we can create multi-session cds with the dir_feature of the type dir/=/dir1/dir2Objetive: Saving root directories of Redhat 6.1 and Col 2.3 on a single CD.Observation: Redhat installation is mounted on COL 2.3 at /mnt/redhatFirst image - RedHat 6.1 - /mnt/redhat/rootmkisofs -D -l -r -f -m core -L -o image1.raw redhat/=/mnt/redhat/rootThis will create a redhat directory on the cd. The option -D should beused with care. The other options used in the above command are just to demonstrate the use of mkisofs. Pleaserefer to man mkisofs if you want to know more.To see if the image is created as expected, we need to mount image1.raw usingthe option -o loop (Linux only! for information on Solaris read README.verify)as follows:mount -t iso9660 image1.raw /mnt/image -o loopTo see the contents type:ls -l /mnt/image/redhatDoes it look ok? Great! Unmount /mnt/image. Now the burning process itself:cdrecord -v -dev=0,3,0 -multi -eject image1.raw To check the burned image we need to mount the cd; something likemount -t iso9660 /dev/scd0 /mnt/cdroms/mnt/cdroms is the device file for the cdrom I use.Second image - Caldera 2.3 - /rootTo create the second image on our cd, we need get informationabout sectors related to the first track. To do that, issue the commandcdrecord -v -dev=0,3,0 -msinfo Cdrecord returns the following number0,135563This number is the format XX,YY discussed on README.multi. XX would be usedfor testing the images as well as burning the new track.mkisofs -D -l -r -f -m core -L -C 0,135563 -M /dev/scd0 -o image2.raw caldera/=/rootNow we need to check of image2.raw is ok. The following command creates exactly what we need. Plese note that -C option. Only the first number changes in this case. The second oneis always zero. In our case the first number is zero due to cdrecord -msinfo. When more tracks are added to the cd this number will change.mkisofs -D -l -r -f -m core -L -C 0,0 -M /dev/scd0 -o image2_test.raw caldera/=/rootmount -t iso9660 image2_test.raw /mnt/image -o loopls -l /mnt/image shows that there are two directories: redhat and caldera, just the waywe wanted.Now let us burn image2.raw (not image2_test.raw)cdrecord -v -dev=0,3,0 -multi -eject image2.rawWe can mount the CD again to see that the two directories are there. We can carry ondoing this until we decide to close the CD. If this is the case, don't use -multi whenburning the last session.b) A dir1/dir2/=/dir3/dir4 and dir1/dir2a=/dir5/dir6 exampleThe above example seems a bit silly, one could argue. Why did I create a single directorycalled root and within two sub-directories: redhat and caldera? Using the procedure described above we would do as follows:mkisofs -D -l -r -f -m core -L -o image1.raw etc/redhat/=/mnt/redhat/etccdrecord -v -dev=0,3,0 -multi -eject image1.raw To check the burned image we need to mount the cd; something likemount -t iso9660 /dev/scd0 /mnt/cdromscdrecord -v -dev0,3,0 -msinfo Cdrecord returns the following number0,14391The second image can be created usingmkisofs -l -r -f -m core -L -C 0,14391 -M /dev/scd0 -o image2.raw etc/caldera/=/etc Creating a test image2mkisofs -l -r -f -m core -L -C 0,0 -M /dev/scd0 -o image2_test.raw etc/caldera/=/etc mount -t iso9660 image2_test.raw /mnt/image1 -o loopIt works!! That is great!!!Now the burning process itself.cdrecord -v -dev=0,3,0 -multi -eject image2.rawand we're done !!!!To add more tracks just do as indicated above.Good luxk!!!Eduardo Mendes - 11/23/99
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -