1CDRSKIN(1)                  General Commands Manual                 CDRSKIN(1)
2
3
4

NAME

6       cdrskin - burns preformatted data to CD-R or CD-RW via libburn.
7

SYNOPSIS

9       cdrskin [options|track_source_addresses]
10

DESCRIPTION

12       cdrskin is a program that provides some of cdrecord's options in a com‐
13       patible way.  You don't need to be root to use it.
14
15       Overview of features:
16       Blanking of CD-RW.
17       Burning of data or audio tracks to CD.
18       Either in versatile Track at Once mode (TAO)
19       or in Session at Once mode for seamless tracks.
20       Multi session (follow-up sessions in TAO only).
21       Bus scan, burnfree, speed  options,  retrieving  media  info,  padding,
22       fifo.
23       See section EXAMPLES at the end of this text.
24
25       Known deficiencies:
26       No DVD support yet.
27
28       Track recording model:
29       The  input-output  entities  which  get processed are called tracks.  A
30       track stores a stream of bytes.
31       Each track is initiated by one track source address argument, which may
32       either  be "-" for standard input or the address of a readable file. If
33       no write mode is given  explicitely  then  one  will  be  chosen  which
34       matches  the  peculiarities of track source and the state of the output
35       media.
36
37       There can be more than one track burned by a  single  run  of  cdrskin.
38       CDs  can  be  kept  appendable so that further tracks can be written to
39       them in subsequent runs of cdrskin (see option -multi).  Info about the
40       addresses of burned tracks is kept in a table of content (TOC) on media
41       and can be retrieved via cdrskin option -toc.  These  informations  are
42       also used by the operating systems' CD-ROM read drivers.
43
44       In  general  there are two types of tracks: data and audio. They differ
45       in sector size, throughput and  readability  via  the  systems'  CD-ROM
46       drivers resp. by music CD players.
47       If  not explicitely option -audio is given, then any track is burned as
48       data unless the track source is a file with suffix ".wav" or ".au"  and
49       has  a  header part which identifies it as MS-WAVE resp. SUN Audio with
50       suitable parameters. Such files are burned as audio tracks by default.
51
52       While audio tracks just contain a given time span  of  acoustic  vibra‐
53       tions, data tracks may have an arbitray meaning. Nevertheless, ISO-9660
54       filesystems are established as a format which can represent a  tree  of
55       directories  and  data  files  on  all  major  operating  systems. Such
56       filesystem images can be produced by programs mkisofs  or  genisoimage.
57       They can also be extended by follow-up tracks if prepared properly. See
58       the man pages of said programs.  cdrskin is able to fulfill  the  needs
59       about their option -C.
60       Another type of data track content are archive formats which originally
61       have been developed for magnetic  tapes.  Only  formats  which  mark  a
62       detectable  end-of-archive  in their data are suitable with CD, though.
63       Well tested are the archivers afio and star.  Not  suitable  seems  GNU
64       tar.
65
66       Recordable CD Media:
67       CD-R  can  be initially written only once and eventually extended until
68       they get closed (or are spoiled because they are  overly  full).  After
69       that they are read-only.
70       CD-RW  media can be blanked to make them re-usable for another round of
71       overwriting. Blanking damages the previous content but does not make it
72       completely unreadable. It is no effective privacy precaution.  Multiple
73       cycles of blanking and overwriting with random numbers might be.
74

OPTIONS

76       --help Show non-cdrecord compatible options.
77
78       -help  Show cdrecord compatible options.
79
80       -version
81              Print cdrskin id line, compatibility lure line, libburn version,
82              cdrskin  version,  version timestamp, build timestamp (if avail‐
83              able), and then exit.
84
85       Alphabetical list of options which are intended to be  compatible  with
86       original cdrecord by Joerg Schilling:
87
88       -atip  Retrieve  some  info  about  media  state.  With CD-RW print "Is
89              erasable".
90
91       -audio Announces that the subsequent tracks are to be burned as  audio.
92              The  source is supposed to be uncompressed headerless PCM, 44100
93              Hz, 16 bit, stereo. For little-endian byte order (which is usual
94              on PCs) use option -swab. Input files with suffix .wav are exam‐
95              ined wether they have a  header  in  MS-WAVE  format  confirming
96              those  parameters  and  eventually  raw audio data get extracted
97              automatically. Same is done for suffix .au and SUN Audio.
98
99       blank=type
100              Blank a CD-RW disc. This is combinable with burning in the  same
101              run of cdrskin.  The type given with blank= selects the particu‐
102              lar behavior:
103
104              help   Print this list of blanking types.
105
106              all    Blank the entire disk.
107
108              fast   Minimally blank the entire disk.
109
110       -checkdrive
111              Retrieve some info about the addressed drive.  Exits  with  non-
112              zero value if the drive cannot be found and opened.
113
114       -dao   Alias for option -sao. Write disk in Session at Once mode.
115
116       -data  Subsequent  tracks  are  data tracks. This option is default and
117              only needed to mark the end of the range of an  eventual  option
118              -audio.
119
120       dev=target
121              Sets the (pseudo-)SCSI address of the drive to use. Valid are at
122              least the X,Y,Z addresses listed with option -scanbus, ATA:X,Y,Z
123              addresses  listed with options dev=ATA -scanbus, the device file
124              addresses listed with option --devices , volatile libburn  drive
125              numbers  (numbering starts at "0").  Other device file addresses
126              which lead to the same drive might work too.
127              If no dev= is given, volatile address "dev=0" is  assumed.  That
128              is  the  first drive found being available. Better avoid this on
129              multi-drive systems.
130              The special target "help" lists hints about available addressing
131              formats.  Be aware that option --old_pseudo_scsi_adr changes the
132              meaning of Bus,Target,Lun addresses.
133
134       driveropts=opt
135              Set "driveropts=burnfree" to enable the drive's eventual protec‐
136              tion  mechanism against temporary lack of source data (i.e. buf‐
137              fer underrun).  It is not an error to do this with a drive  that
138              has no such capabilities.
139
140       -dummy Try  to  perform the drive operations without actually affecting
141              the inserted media. There is no guarantee that  this  will  work
142              with  a particular drive in a particular write mode. Blanking is
143              prevented reliably, though.
144
145       -eject Eject the disk after work is done.
146
147       -force Assume that the user knows better in situations when cdrskin  or
148              libburn  are  insecure about drive or media state. This includes
149              the attempt to blank media which are classified  as  unknown  or
150              unsuitable,  and  the  attempt  to use write modes which libburn
151              believes they are not supported by the drive.
152              Use this only when in urgent need.
153
154       fs=size
155              Set the fifo size  to  the  given  value.  The  value  may  have
156              appended letters which multiply the preceding number:
157              "k"  or  "K"  = 1024 , "m" or "M" = 1024k , "g" or "G" = 1024m ,
158              "s" or "S" = 2048
159              Set size to 0 in order to disable the fifo (default is "4m").
160              The fifo buffers an eventual temporary surplus of  track  source
161              data  in  order to provide the drive with a steady stream during
162              times of temporary lack of track source supply.  The larger  the
163              fifo,  the  longer  periods of poor source supply can be compen‐
164              sated.  But a large fifo needs substantial time to  fill  up  if
165              not curbed via option fifo_start_at=size.
166
167       gracetime=seconds
168              Set the grace time before starting to write. (Default is 0)
169
170       -msinfo
171              Retrieve multi-session info for preparing a follow-up session by
172              option -C of programs mkisofs or genisoimage.  Print  result  to
173              standard  output.   This  option redirects to stderr all message
174              output besides its own result string, which consists of two num‐
175              bers.   The result string shall be used as argument of option -C
176              with said programs.  It gives the  start  address  of  the  most
177              recent  session and the predicted start address of the next ses‐
178              sion to be appended. The string is empty if the most recent ses‐
179              sion was not written with option -multi.
180
181       -multi This  option  keeps  the CD appendable after the current session
182              has been written.  Without it the disk gets closed and  may  not
183              be  written  any  more   - unless it is a CD-RW and gets blanked
184              which causes loss of its content.
185              The following sessions can only be written in -tao mode.
186              In order to have all filesystem content accessible, the eventual
187              ISO-9660  filesystem of a follow-up session needs to be prepared
188              in a special way by the filesystem  formatter  program.  mkisofs
189              and genisoimage expect particular info about the situation which
190              can be retrieved by cdrskin option -msinfo.
191              To retrieve an archive file which was written as follow-up  ses‐
192              sion,  you  may  use option -toc to learn about the "lba" of the
193              desired track number.
194
195       -nopad Do not add trailing zeros  to  the  data  stream.  Nevertheless,
196              since  there seems to be no use for audio tracks with incomplete
197              last sector, this option applies only to data tracks.  There  it
198              is default.
199
200       -pad   Add  30  kB  of  trailing zeros to each data track. (This is not
201              sufficient to avoid problems with various CD-ROM read drivers.)
202
203       padsize=size
204              Add the given amount of trailing zeros to the next  data  track.
205              This  option  gets  reset  to padsize=0 after that next track is
206              written. It may be set again before  the  next  track  argument.
207              About size specifiers, see option fs=.
208
209       -raw96r
210              Write disk in RAW/RAW96R mode. This mode allows to put more pay‐
211              load bytes into a CD sector but obviously at the cost  of  error
212              correction.  It  can only be used for tracks of fixely predicted
213              size. Some drives allow this mode but  then  behave  strange  or
214              even  go bad for the next few attempts to burn a CD.  One should
215              use it only if inavoidable.
216
217       -sao   Write disk in Session At Once mode. This mode  is  able  to  put
218              several  audio  tracks  on  CD  without  producing  audible gaps
219              between them. It can only be used for tracks of fixely predicted
220              size.  This  implies  that track arguments which depict stdin or
221              named pipes need to be preceeded by option tsize= or  by  option
222              tao_to_sao_tsize=.
223
224       -scanbus
225              Scan  the  system for drives. On Linux the drives at /dev/s* and
226              at /dev/hd* are to be scanned by two separate runs. One  without
227              dev=  for  /dev/s*  and  one  with dev=ATA for /dev/hd* devices.
228              (Option --drives lists all available drives in a single run.)
229              Drives which are busy or which offer  no  rw-permission  to  the
230              user of cdrskin are not listed. Busy drives get reported in form
231              of warning messages.
232              The useful fields in a result line are:
233              Bus,Target,Lun Number) 'Vendor' 'Mode' 'Revision'
234
235       speed=number
236              Set speed of drive. With data CD,  1x  speed  corresponds  to  a
237              throughput of 150 kB/s. It is not an error to set a speed higher
238              than is suitable for drive and media. One should stay  within  a
239              realistic speed range, though.
240
241       -swab  Announce  that the raw audio data source of subsequent tracks is
242              byte swapped versus the expectations of cdrecord. This option is
243              suitable  for audio where the least significant byte of a 16 bit
244              word is first (little-endian, Intel).  Most raw audio data on PC
245              systems  are  available  in  this byte order.  Less guesswork is
246              needed if track sources are in format MS-WAVE  in  a  file  with
247              suffix ".wav".
248
249       -tao   Write  disk  in  Track At Once (TAO) mode. This mode can be used
250              with track sources of unpredictable size, like standard input or
251              named pipes. It is also the only mode that can be used for writ‐
252              ing to appendable CD which already hold data.
253
254       -toc   Print the table of content  (TOC)  which  describes  the  tracks
255              recorded  on CD.  The output contains all info from option -atip
256              plus lines which begin with "track:  "  followed  by  the  track
257              number,  the  word  "lba:"  and  a  number which gives the start
258              address of the track. Addresses are counted in CD sectors  which
259              with data tracks hold 2048 bytes each.
260
261              Example. Retrieve an afio archive from track number 2:
262                     tracknumber=2
263                     lba=$(cdrskin dev=/dev/cdrom -toc 2>&1 | \
264                     grep '^track:  [ 0-9][0-9]' | \
265                     tail +"$tracknumber" | head -1 | \
266                     awk '{ print $4}' )
267                     dd if=/dev/cdrom bs=2048 skip="$lba" | \
268                     afio -t - | less
269
270       tsize=size
271              Announces  the exact size of the next track source. This is nec‐
272              essary with any write mode other than -tao if the  track  source
273              is  not  a regular disk file, but e.g. "-" (standard input) or a
274              named pipe.  About size specifiers, see option fs=.
275              If the track source does not deliver  the  predicted  amount  of
276              bytes,  the remainder of the track is padded with zeros. This is
277              not considered an error.  If on the other hand the track  source
278              delivers more than the announced bytes then the track on CD gets
279              truncated to the predicted size and cdrskin exits with  non-zero
280              value.
281
282       -v     Increment  verbose  level  by one. Startlevel is 0 with only few
283              messages.  Level 1 prints  progress  report  with  long  running
284              operations  and  also causes some extra lines to be put out with
285              info retrieval options.   Level  2  additionally  reports  about
286              option settings derived from arguments or startup files. Level 3
287              is for debugging and useful mainly in conjunction with  somebody
288              who had a look into the program sourcecode.
289
290       Alphabetical  list of options which are genuine to cdrskin and intended
291       for normal use:
292
293       --allow_setuid
294              Disable the program abort triggered by an  insecure  discrepance
295              between  login  user and effective user which indicates applica‐
296              tion of chmod u+s to the program binary.  One should not do this
297              chmod u+s , but it is an old cdrecord tradition.
298
299       --any_track
300              Allow  source_addresses  to begin with "-" (plus further charac‐
301              ters) or to contain a "=" character.  By default such  arguments
302              are  seen as misspelled options. It is nevertheless not possible
303              to use one of the options of cdrecord-2.01.
304
305       --demand_a_drive
306              Exit with a nonzero value if no drive can be found during a  bus
307              scan.
308
309       --devices
310              List  the  device  file  addresses  of all accessible drives. In
311              order to get listed a drive has to offer rw-permission  for  the
312              cdrskin  user  and it may not be busy.  Busy drives are reported
313              as "SORRY" messages on standard error.
314              Each available drive gets listed by a line containing  the  fol‐
315              lowing fields:
316              Number dev='Devicefile' rw-Permissions : 'Vendor' 'Model'
317              Number  and  Devicefile  can  both be used with option dev=, but
318              number is volatile (numbering changes if  drives  become  busy).
319              Normal  users  might  not  see  all  drives unless the superuser
320              enabled access by chmod o+rw after using  cdrskin  --devices  to
321              get an overview of the situation.  That's why current rw-Permis‐
322              sions are listed.
323
324       fifo_start_at=size
325              Do not wait for full fifo but start burning as soon as the given
326              number of bytes is read. This option may be helpful to bring the
327              average throughput near to the maximum throughput of a drive.  A
328              large  fs= and a small fifo_start_at= combine a quick burn start
329              and a large savings buffer to compensate for temporary  lack  of
330              source  data.  At the beginning of burning, the software protec‐
331              tion  against  buffer  underun  is  as  weak  as  the  size   of
332              fifo_start_at= . So it is best if the drive offers hardware pro‐
333              tection which has to be enabled by driveropts=burnfree.
334
335       --no_rc
336              Only if used as first command line argument this option prevents
337              reading  and  interpretation of eventual startup files. See sec‐
338              tion FILES below.
339
340       --single_track
341              Accept only the last argument  of  the  command  line  as  track
342              source address.
343
344       Alphabetical  list  of options which are only intended for very special
345       situations and not for  normal use:
346
347       --abort_handler
348              Establish default signal handling not to leave a drive  in  busy
349              state  but rather to shut it down and to wait until it has ended
350              the final operations.  This option is only needed  for  revoking
351              eventual --ignore_signals or --no_abort_handler.
352
353       dev_translation=<sep><from><sep><to>
354              Set drive address alias. This was necessary before cdrskin-0.2.4
355              to manually translate cdrecord addresses into cdrskin addresses.
356              <sep> is a single character which may not occur in  the  address
357              string  <from>.  <from> is an address as expected to be given by
358              the user via option dev=. <to> is the address to be used instead
359              whenever <from> is given.  More than one translation instruction
360              can be given in one cdrskin run.
361              E.g.:      dev_translation=+ATA:1,0,0+/dev/sg1      dev_transla‐
362              tion=+ATA:1,1,0+/dev/sg2
363
364       --drive_abort_on_busy
365              Linux specific: Abort process if a busy drive is encountered.
366
367       --drive_blocking
368              Linux  specific:  Try  to  wait for a busy drive to become free.
369              This is not guaranteed to work with all drivers. Some need  non‐
370              blocking i/o.
371
372       --drive_not_exclusive
373              Linux specific: Do not ask the operating system to prevent open‐
374              ing busy drives.  Wether this leads to senseful behavior depends
375              on operating system and kernel.
376
377       --drive_scsi_exclusive
378              Linux   specific:   Try  to  exclusively  reserve  device  files
379              /dev/srN, /dev/scdM, /dev/stK of drive.  this would  be  helpful
380              to  protect  against collisions with program growisofs.  Regret‐
381              tably on Linux kernel 2.4 with ide-scsi emulation this seems not
382              to work. Wether it becomes helpful with new Linux systems has to
383              be evaluated.
384
385       --fifo_disable
386              Disable fifo despite any fs=.
387
388       --fifo_per_track
389              Use a separate fifo for each track.
390
391       grab_drive_and_wait=seconds
392              Open the addressed drive, wait  the  given  number  of  seconds,
393              release  the drive, and do normal work as indicated by the other
394              options used. This option helps to explore the program  behavior
395              when  faced  with  busy drives. Just start a second cdrskin with
396              option --devices while grab_drive_and_wait= is still active.
397
398       --ignore_signals
399              Try to ignore any signals rather than to abort the program. This
400              is  not  a  very good idea. You might end up waiting a very long
401              time for cdrskin to finish.
402
403       --no_abort_handler
404              On signals exit even if the drive is in busy state. This is  not
405              a  very  good  idea.  You  might  end up with a stuck drive that
406              refuses to hand out the media.
407
408       --no_blank_appendable
409              Refuse to blank appendable CD-RW. This is  a  feature  that  was
410              once builtin with libburn. No information available for what use
411              case it was needed.
412
413       --no_convert_fs_adr
414              Do only literal translations of dev=. This prevents cdrskin from
415              test-opening  device files in order to find one that matches the
416              given dev= specifier.
417              Partly Linux specific: Such opening is needed for Bus,Target,Lun
418              addresses  unless  option  --old_pseudo_scsi_adr is given. It is
419              also needed to resolve  device  file  addresses  which  are  not
420              listed with cdrskin --devices but nevertheless point to a usable
421              drive. (Like /dev/sr0 using the same SCSI address as /dev/sg0.)
422
423       --old_pseudo_scsi_adr
424              Linux specific: Use and report literal Bus,Target,Lun  addresses
425              rather  than  real SCSI and pseudo ATA addresses. This method is
426              outdated and was never compatible with original cdrecord.
427
428       tao_to_sao_tsize=size
429              Set an exact fixed size for the next track to be in effect  only
430              if  the  track  source  cannot  deliver a size prediction and no
431              tsize= was specified.  This is the fallback from bad  old  times
432              when cdrskin was unable to burn in mode -tao.
433

EXAMPLES

435   Get an overview of drives:
436       cdrskin -scanbus
437       cdrskin dev=ATA -scanbus
438       cdrskin --devices
439
440   Get info about a particular drive or loaded media:
441       cdrskin dev=0,1,0 -checkdrive
442       cdrskin dev=ATA:1,0,0 -atip
443       cdrskin dev=/dev/hdc -toc
444
445   Make used CD-RW writable again:
446       cdrskin -v dev=/dev/sg1 blank=all -eject
447       cdrskin -v dev=/dev/dvd blank=fast -eject
448
449   Write ISO-9660 filesystem image:
450       cdrskin -v dev=/dev/hdc speed=12 fs=8m \
451       driveropts=burnfree -sao -eject \
452       padsize=300k my_image.iso
453
454   Write compressed afio archive on-the-fly:
455       find . | afio -oZ - | \
456       cdrskin -v dev=0,1,0 fs=32m speed=8 driveropts=burnfree \
457       padsize=300k -tao -
458
459   Write several sessions to the same CD:
460       cdrskin dev=/dev/hdc padsize=300k -multi 1.iso
461       cdrskin dev=/dev/hdc padsize=300k -multi -tao 2.afio
462       cdrskin dev=/dev/hdc padsize=300k -multi -tao 3.afio
463       cdrskin dev=/dev/hdc padsize=300k -tao 4.afio
464
465   Get the multi-session info for option -C of program mkisofs:
466       c_values=$(cdrskin dev=/dev/sr0 -msinfo 2>/dev/null)
467       mkisofs ... -C "$c_values" ...
468
469   Write audio tracks:
470       cdrskin -v dev=ATA:1,0,0 speed=48 \
471       driveropts=burnfree -sao \
472       track1.wav track2.au -audio -swab track3.raw
473

FILES

475       If  not --no_rc is given as the first argument then cdrskin attempts on
476       startup to read the arguments from the following files:
477
478       /etc/default/cdrskin
479       /etc/opt/cdrskin/rc
480       $HOME/.cdrskinrc
481
482       The files are read in the sequence given above, but  none  of  them  is
483       required  for  cdrskin  to  function  properly.  Each  readable line is
484       treated as one single argument. No extra blanks.  A first character '#'
485       marks a comment, empty lines are ignored.
486
487   Example content of a startup file:
488       # This is the default device
489       dev=0,1,0
490       # To accomodate to remnant cdrskin-0.2.2 addresses
491       dev_translation=+1,0,0+0,1,0
492       # Some more options
493       fifo_start_at=0
494       fs=16m
495

SEE ALSO

497       Formatting track sources for cdrskin:
498              mkisofs(8), genisoimage(8), afio(1), star(1)
499
500       Other CD burn programs:
501              cdrecord(1), wodim(1)
502
503       For DVD burning:
504              growisofs(1)
505

AUTHOR

507       cdrskin was written by Thomas Schmitt <scdbackup@gmx.net>.
508
509       This  manual page was written by George Danchev <danchev@spnet.net> and
510       Thomas Schmitt, for the Debian project and for all others.
511
512
513
514
515                               December 13, 2006                    CDRSKIN(1)
Impressum