home *** CD-ROM | disk | FTP | other *** search
/ BURKS 2 / BURKS_AUG97.ISO / BURKS / LINUX / HOWTO / mini / cdwrite.txt < prev    next >
Text File  |  1997-07-07  |  33KB  |  865 lines

  1.  
  2. CD-Writing mini-HOWTO                      Winfried Trⁿmper <winni@xpilot.org>
  3. ---------------------                      Version 1.8             18 Mar 1997
  4.  
  5.  
  6.  
  7.   I (Winfried Trⁿmper) DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
  8.   DOCUMENT, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
  9.   FITNESS FOR A CERTAIN PURPOSE; IN NO EVENT SHALL I BE LIABLE FOR ANY
  10.   SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
  11.   RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF
  12.   CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
  13.   CONNECTION WITH THE USE OF THIS DOCUMENT.
  14.  
  15.   Short: read and use at your own risk.
  16.  
  17.  
  18.  
  19.   1. Introduction
  20.  
  21.         My first experience with CD Writers was guided by the
  22.         "CD Writer mini-HOWTO" by Matt Cutts <cutts@ms.uky.edu>.
  23.         Thanks Matt!
  24.  
  25.         Although my intention was only to upgrade his document, I
  26.         rewrote it from the scratch after I realized how much changed
  27.         since 1994.
  28.  
  29.  
  30.   1.1. Suggested readings
  31.  
  32.         The "Linux CD-ROM HOWTO" explains everything one should know
  33.         about CD-ROM drives under Linux.
  34.         As a supplement, you may want to take a look at the
  35.         "Linux SCSI HOWTO" and the "Linux Kernel HOWTO".
  36.  
  37.  
  38.   1.2. Terminology ... lasers at maximum ... fire!
  39.  
  40.         "CD-ROM" stands for "Compact Disc Read Only Memory", a storage
  41.         medium utilizing an optical laser to sense microscopic pits on
  42.         a silver shimmering disk. (The silver shimmering comes from an
  43.         aluminized layer which is the carrier.) The pits represent the
  44.         bits of the information (in some way) and are so petite that
  45.         some billions of them fit on the disc. Thus a CD is a
  46.         mass-storage medium.
  47.  
  48.         The Term "CD-R" is a short form of "CD-ROM recordable" and refers
  49.         to a CD that doesn't have those "microscopic pits" on it's
  50.         surface ... thus it's empty.
  51.         Instead of the aluminium layer (silver) it has a special film
  52.         (colored) into which "microscopic pits" can be burned in. This is
  53.         done by giving the laser which normally only senses the pits a
  54.         little bit more power so he burns the pits. This action can only
  55.         be taken _once_ on a CD-R.
  56.  
  57.         This mini-HOWTO deals with the task of writing such a CD-R.
  58.         Welcome on board, captain.
  59.  
  60.  
  61.   1.3. Supported CD-Writers
  62.  
  63.         "Linux" supports CD-writers of the following manufacturers
  64.  
  65.                 Philips, IMS, Kodak, Yamaha, Hewlett-Packard
  66.  
  67.         or compatibles ...
  68.  
  69.         If your hardware isn't supported you can still use Linux
  70.         to create an image of the later CD but then you have to use
  71.         DOS-Software to write the image to the CD-R. [You may wish to
  72.         do so because most DOS-software cannot deal with long
  73.         filenames available in Linux.]
  74.         In this case you can skip all hardware-related sections (those
  75.         about "generic SCSI devices" and "cdwrite").
  76.  
  77.  
  78.   1.4. Supported "features"
  79.  
  80.         Currently the software for burning CDs under Linux does 
  81.         support the following main features:
  82.  
  83.           * RockRidge Extensions
  84.           * "Multisession" CDs and
  85.           * "El Torito" (bootable) CDs.
  86.  
  87.  
  88.   1.5. Mailinglists
  89.  
  90.         If you want to join the development team (with the intention
  91.         to actively _help_ them), send e-mail to
  92.  
  93.                 cdwrite-request@pixar.com
  94.  
  95.         and put the command "subscribe" in body of the message.
  96.  
  97.  
  98.  
  99.   2. Prepare your Linux-box for writing CD-ROMs
  100.  
  101.   2.1. Set up the hardware
  102.  
  103.     (a) Shut down your computer, switch it off and hook CD writer to the
  104.         SCSI-bus. Please note that CD-writers require a SCSI-controller,
  105.         the standard EIDE-Interface of your PC has no ability to drive
  106.         those writers.
  107.  
  108.     (b) Make sure the SCSI-bus is properly terminated and choose a free
  109.         SCSI-ID for the writer. Look at the Linux SCSI-HOWTO if you're
  110.         not sure. If you're completly clueless, ask an expert.
  111.  
  112.     (c) Switch the power on again and check the messages that the BIOS of
  113.         the SCSI-controller prints immediatly after switching the power
  114.         on.
  115.         If it doesn't recognize you writer, go back to step (b).
  116.         You should see a message like
  117.  
  118.  
  119.                 [missing picture; has anyone a screenshot of it?]
  120.  
  121.  
  122.   2.2. A note on writing CDs under Linux
  123.  
  124.         In contrast to other rumors, the Linux-kernel does _not_
  125.         require a patch in order to write to CDs. Although the
  126.         file "drivers/scsi/scsi.c" from the kernel-sources
  127.         contains the lines
  128.  
  129.                   case TYPE_WORM:
  130.                   case TYPE_ROM:
  131.                     SDpnt->writeable = 0;
  132.  
  133.         this does only mean that that CDs and WORMs are not writeable
  134.         through the standard-devices "/dev/sda"-"/dev/sdh" which is ok.
  135.  
  136.         Instead of using these devices the writing of CDs is done
  137.         through the so called "generic SCSI-devices" which permit
  138.         nearly everything - even writing to CDs.
  139.  
  140.  
  141.   2.3. Create "generic devices"
  142.  
  143.         The Linux SCSI-HOWTO says about generic SCSI-devices:
  144.  
  145.                 The Generic SCSI device driver provides an interface
  146.                 for sending SCSI commands to all SCSI devices - disks,
  147.                 tapes, CDROMs, media changer robots, etc.
  148.  
  149.  
  150.         Speaking of the generic devices as "interfaces" means that
  151.         they provide an alternate way of accessing SCSI-hardware than
  152.         through the standard devices.
  153.         It is necassary because Linux does not allow direct hardware access
  154.         through the standard SCSI-devices - everything must pass by the
  155.         kernel first. But the writing-software _requires_ direct access to
  156.         the CD-writer hardware - so there must be an alternate way.
  157.  
  158.         [Note: if there were a standard for driving CD-writers, the
  159.          kernel-developers would have programmed a kernel-module for
  160.          writing to CD-Rs and we wouldn't have to use generic devices.
  161.          But as every manufacturer needs an individual driver for its
  162.          hardware (argh!), this kernel-module would become unhandy and
  163.          bigger than everything you want to be in your kernel.]
  164.  
  165.         As everthing can be done to SCSI-hardware through the generic
  166.         devices they are not fixed to a certain purpose - therefore the
  167.         name "generic".
  168.  
  169.         Goto the "/dev"-directory and check for "generic scsi devices";
  170.         "ls"-command should show "sga"-"sgh":
  171.  
  172.                 bash> cd /dev
  173.                 bash> ls -l sg*
  174.                 crw-------   1 root   sys     21,   0 Jan  1  1970 sga
  175.                 crw-------   1 root   sys     21,   1 Jan  1  1970 sgb
  176.                 crw-------   1 root   sys     21,   2 Jan  1  1970 sgc
  177.                 crw-------   1 root   sys     21,   3 Jan  1  1970 sgd
  178.                 crw-------   1 root   sys     21,   4 Jan  1  1970 sge
  179.                 crw-------   1 root   sys     21,   5 Jan  1  1970 sgf
  180.                 crw-------   1 root   sys     21,   6 Jan  1  1970 sgg
  181.                 crw-------   1 root   sys     21,   7 Jan  1  1970 sgh
  182.  
  183.         If you don't have those device-files then create them by using
  184.         the "/dev/MAKEDEV"-script:
  185.  
  186.                 bash> cd /dev/
  187.                 bash> ./MAKEDEV sg
  188.  
  189.         Now the device-files should show up.
  190.  
  191.  
  192.   2.4. Enable usage of the "generic scsi" and "loopback" devices
  193.  
  194.         The Linux-kernel needs a module that lends it the ability to
  195.         deal with generic scsi devices.
  196.         If your running kernel has this feature, it should be listed
  197.         in the pseudo-file "/proc/devices":
  198.  
  199.                 bash> cat /proc/devices
  200.                 Character devices:
  201.                  1 mem
  202.                  2 pty
  203.                  3 ttyp
  204.                  4 ttyp
  205.                  5 cua
  206.                  7 vcs
  207.                 21 sg          <----- stands for "Scsi Generic device"
  208.                 
  209.                 30 socksys
  210.  
  211.                 Block devices:
  212.                  2 fd
  213.                  7 loop        <----- we even can use the loop-devices
  214.                  8 sd
  215.                 11 sr          <----- stands for "Scsi cd-Rom"
  216.  
  217.  
  218.         Maybe you have to issue the