SUMMARY: CD Burner Recommendation

From: Jeff Hunter <jhunter_at_thegateway.net>
Date: Thu Jan 10 2002 - 14:50:48 EST
The Plextor models received the most recommendations, their external 
SCSI model (one specific model #PX-W1210TSE/SW was offered). Also 
recommended were the Yamaha's (6416 and CRW4416SX) and TEAC CDR56S. One 
writer suggested getting the new DVD-R/RW, which will work for CD's 
also. Most are using the cdrecord software. One person suggested HyCD 
Publisher for Unix (www.hycd.com) and one suggested x-roast. Several are 
using the SUNWcdrw pkg available with Solaris 8 (which includes 
mkisofs). This isn't an option as I'm on Sol7. Special thanks to Dave 
Foster who included the following howto info and his scripts:

Log of installation of CDRECORD 1.10

   2-26-01  DSFoster

Source:

     CDRecord:
 
http://www.fokus.gmd.de/research/cc/glone/employees/joerg.schilling/private/cdrecord.html

FBK/SCG Drivers:  ftp://ftp.fokus.gmd.de/pub/unix/kernel/scg/

Need Solaris 2.8 version of driver:  fbk.sparcv9.sol2.8


Installation on Ivem:

   Compiled CDRecord on Ivem using Sun Workshop C compiler 5.0
       and install in /usr/local.

          set path = ( /usr/ccs/bin $path )
          make

     * Edit DEFAULTS/Defaults.sunos5 file and change INS_BASE from 
/opt/schily
       to /usr/local, and change other references to /opt/schily.

          make install | tee -a Install.Solaris

     * Move setuid binaries from /usr/local/bin to /usr/bin:
          mv /usr/local/bin/cdrecord /usr/bin
          mv /usr/local/bin/mkhybrid /usr/bin
          mv /usr/local/bin/mkisofs  /usr/bin

   To use GCC and install in /opt/schily:

          make CCOM=gcc
          env CCOM=gcc make install

   Install SCG and FBK drivers:

     * Extract and install SCG package (copy the driver first):
          tar xvf SCHILYscg.sparc.tar
          cp SCHILYscg/root/kernel/drv/scg /kernel/drv/sparcv9/scg
          chmod 755 /kernel/drv/sparcv9/scg
          chgrp sys /kernel/drv/sparcv9/scg
          pkgadd -d .

     * Extract and install FBK package (copy the driver first):

       Note: copy the Solaris 2.8 sparcv9 version of the driver!

          tar xvf SCHILYfbk.sparc.tar
          # cp SCHILYfbk/root/kernel/drv/fbk /kernel/drv/sparcv9/fbk
          cp fbk.sparcv9.sol2.8 /kernel/drv/sparcv9/fbk
          chmod 755 /kernel/drv/sparcv9/fbk
          chgrp sys /kernel/drv/sparcv9/fbk
          pkgadd -d .

       Now attach the driver:
          drvconfig
          devlinks

       Edit /etc/devlink.tab (Solaris 8 only):

          replace "fbk\N0" and "rfbk\N0" by "fbk\A0" and  "rfbk\A0" 
respectively.

       Re-run 'devlinks'

       To mount a ISO 9660 filesystem:

          mount -F fbk -o ro,type=hsfs /dev/fbk0:file_to_mount /mnt


   Install scripts and enable:

     * Install scripts in /usr/bin:  {archive_image cdburn make_image 
mount_image}
     * chmod 4711 on all these scripts (suid)



Installation on IRIX
====================

Needed to install 'smake':

    ftp://ftp.fokus.gmd.de/pub/unix/smake/alpha/

Follow instructions in BOOTSTRAP to make smake, then
    copy binary 'smake' to /usr/local/bin

Compile and install CDRecord:

    /usr/local/bin/smake CCOM=gcc

    /usr/local/bin/smake install

Installed in /opt/schily, moved to /opt/CDRecord
(gave many errors, but seemed to install binaries).

Change mode/ownership of binaries:

	chown root /opt/CDRecord/bin/*
	chmod 4711 /opt/CDRecord/bin/*

Copy scripts to /usr/local/bin:

	archive_image
	make_image
	cdburn
	mount_cd
	mount_cdrom





#!/usr/local/bin/perl -T
#
#   CDBURN   4-05-01  DSFoster
#
# Script to create an image file for an ISO 9660 filesystem
# with Rock Ridge extensions and burn to CD-ROM through a
# pipe. Note that currently several arguments have been added
# which make the resulting CDs NOT ISO 9660 compliant; this was
# done to relax filename requirements so files don't get renamed
# and so file/dir names are consistent between UNIX/PC/Mac systems.
#
# May require environment variable CDR_DEVICE be set according to
# man page for 'cdrecord', eg. "setenv CDR_DEVICE 1,4,0"
# (scsi-bus,target,lun). Use 'cdrecord -scanbus' to determine
# the device. If this variable is not set, be sure the dev= option
# to the 'cdrecord' command is included in this script.
#
# All local configuration is done within the "CONFIGURATION" section.
#
# This script uses no outside "tainted" data, and is therefore
# secure to use as a setuid script. ["Programming PERL", O'Reilly...]
#
# Usage:
#
#  cdburn <directory>
#
#      Where <directory> is directory to be burned.
#
#
# This script uses system() to perform a command similar to
# the following:
#
#   mkisofs -R <directory-to-burn> | cdrecord dev=1,4,0 -v fs=6m speed=8 -
#
#
# NOTE: On older systems you must wrap this script within a C
#   program, and make *this* C program setuid. This is because of
#   a kernel bug which creates a "race condition" when a setuid
#   root shell is fired up, creating a security hole. Perl scripts
#   will not run setuid when this kernel bug is apparent.
#   ["Programming PERL", O'Reilly..., pg. 360]
#
# Modifications:
#
# 01-31-01 DSF Created, using bourne shell version at template.
# 02-21-01 DSF Modified for new host and device. Add undocumented
#              -test argument.
# 04-05-01 DSF Add arguments to relax filename requirements:
#                 -iso-level 3 -allow-lowercase -allow-multidot
#                 -l -L -relaxed-filenames -no-iso-translate
#


#--- CONFIGURATION ---------------------------------------------------

# For security reasons use absolute paths for all programs, devices and
# mount points!

$prog_name   = "cdburn";                     # Name of program
$bin_dir = "/usr/bin";                       # Location of mkisofs and 
cdrecord

@local_hosts = qw( ivem );                   # Valid hostnames
$device = "1,4,0";                           # Device (bus,target,lun)

# ISO9660 with Rock Ridge Extensions, but with relaxed filenames
#   so they will be consistent between UNIX and Mac/Windows systems.
#   See man page for mkisofs for details of arguments.

$burn_cmd = "${bin_dir}/mkisofs -iso-level 3 -allow-lowercase 
-allow-multidot -l -L -relaxed-filenames -no-iso-translate -R DIRECTORY 
| ${bin_dir}/cdrecord dev=${device} -v fs=6m speed=12 -";

# For pure ISO9660 with Rock Ridge Extensions. Enforces 8.3 filenames
# and renames files so as to be unique. Filenames may be inconsistent
# on Windows and Mac systems.

$burn_cmd_iso9660 = "${bin_dir}/mkisofs -R DIRECTORY | 
${bin_dir}/cdrecord dev=${device} -v fs=6m speed=12 -";

#----- End Configuration ---------------------------------------------


# Clean up the path for secure operation in setuid mode

$ENV{PATH} = '/bin:/usr/bin';

# Make sure the local host is correct!!

chop($host = `hostname`);
$host_index = -1;
for ($i = 0; $i <= $#local_hosts; $i++) {
	if ($host eq $local_hosts[$i]) {
		$host_index = $i;
		$file_system = $file_systems[$i];
	}
}
if ($host_index == -1) {
	print "  This program can only be run on hosts ( @local_hosts )\n";
	exit 1;
}

# Check arguments and set flags

$debug_mode = 0;
$test_mode = 0;

for ($inc = 0; $inc <= $#ARGV; $inc++) {
	if ($ARGV[$inc] eq "-h") {
		shift(@ARGV);
		help_msg();
		exit 0;
	}
	elsif ($ARGV[inc] eq "-d") {
		shift(@ARGV);
		$debug_mode = 1;
	}
	elsif ($ARGV[inc] eq "-test") {
		shift(@ARGV);
		$test_mode = 1;
	}
	elsif ($ARGV[inc] eq "-iso9660") {       # Pure ISO9660 format
		shift(@ARGV);
		print "\n  Warning: Using pure ISO9660 format.";
		print "\n     (filenames may be inconsistent between UNIX and Mac/Windows 
systems).\n";
		$burn_cmd = $burn_cmd_iso9660;
	}
}

if ($#ARGV < 0) { help_msg(); exit 0; }


# Make sure the directory specified exists

$dir = $ARGV[0];

unless (-d $dir) {
	print "\n\nDirectory not found: $dir\n";
	help_msg();
	exit 1;
}
unless (-r $dir) {
	print "\n\nCannot read directory: $dir\n";
	help_msg();
	exit 1;
}

# Generate command to burn the data

	$ind = index($burn_cmd, "DIRECTORY");
	substr($burn_cmd, $ind, 9) = $dir;

# Adjust cdrecord command if just testing (-test)

if ($test_mode == 1) {
	$ind = index($burn_cmd, "cdrecord");
	substr($burn_cmd, $ind, 8) = "cdrecord -dummy";
}


# Burn the CD
#   Burn CD by piping output of mkisofs directly to cdrecord.
#   Use priocntl to raise priority of mkisofs process.
#   Note: use of priocntl doesn't seem to work.
#
# priocntl -e -c RT -p 59 mkisofs -R $DIR | cdrecord -v fs=6m speed=2 -
# mkisofs -R $DIR | cdrecord -v fs=6m speed=2 -

print "\n  Ready to transfer data in directory $dir to CDROM...";
print "\n  Press Return to continue: ";
$ans = <STDIN>;

if ($debug_mode == 1) { print "\n$burn_cmd\n"; }

$status = system( $burn_cmd );

if ($status != 0) {
	die "\n   Error transferring data...command failed\n";
}

exit 0;


#---------------------------------------------------------------------
# Print an array of strings with freakin spaces between the elements!

sub pretty_print {
	for ($i = 0; $i <= $#_; $i++) { print "$_[$i] "; }
	print "\n";
}


#---------------------------------------------------------------------
# Display help info

sub help_msg {

	print "\n  Usage:  $prog_name [-d] [-iso9660] <directory>\n";
	print "\n     <directory> : Directory to burn";
	print "\n     -iso9660 : Pure ISO9660 format (filenames may be inconsistent";
	print "\n          between UNIX and Mac/Windows systems).";
	print "\n     -d : Debug mode (display commands)";
	print "\n\n";
	$status = 0;
}



#!/usr/local/bin/perl -T
#
#   MAKE_IMAGE  2-26-01  DSFoster
#
# Script to create an image file for an ISO 9660 filesystem
# with Rock Ridge extensions, suitable for burning to CD
# using 'cdrecord'.
#
# All local configuration is done within the "CONFIGURATION" section.
#
# This script uses no outside "tainted" data, and is therefore
# secure to use as a setuid script. ["Programming PERL", O'Reilly...]
#
# Usage:
#
#  make_image <image-file> <directory>
#
#      Where <image-file> is image-file to be created and
#      <directory> is directory to archive.
#
#
# This script uses system() to perform the following command(s):
#
#   mkisofs -R -o <image-file> <directory>
#
#
# NOTE: On older systems you must wrap this script within a C
#   program, and make *this* C program setuid. This is because of
#   a kernel bug which creates a "race condition" when a setuid
#   root shell is fired up, creating a security hole. Perl scripts
#   will not run setuid when this kernel bug is apparent.
#   ["Programming PERL", O'Reilly..., pg. 360]
#
# Modifications:
#
# 02-02-01 DSF Created, using bourne shell version at template.
#


#--- CONFIGURATION ---------------------------------------------------

# For security reasons use absolute paths for all programs, devices and
# mount points!

$prog_name   = "make_image";                 # Name of program
@local_hosts = qw( ivem );                   # Valid hostnames
$bin_dir = "/usr/bin";                       # Location of binaries

$make_image_cmd = "${bin_dir}/mkisofs -iso-level 3 -allow-lowercase 
-allow-multidot -l -L -relaxed-filenames -no-iso-translate-R -o 
IMAGE_FILE DIRECTORY" ;

#----- End Configuration ---------------------------------------------


# Clean up the path for secure operation in setuid mode

$ENV{PATH} = '/bin:/usr/bin';

# Make sure the local host is correct!!

chop($host = `hostname`);
$host_index = -1;
for ($i = 0; $i <= $#local_hosts; $i++) {
	if ($host eq $local_hosts[$i]) {
		$host_index = $i;
		$file_system = $file_systems[$i];
	}
}
if ($host_index == -1) {
	print "  This program can only be run on hosts ( @local_hosts )\n";
	exit 1;
}

# Check arguments and set flags

$debug_mode = 0;

for ($inc = 0; $inc <= $#ARGV; $inc++) {
	if ($ARGV[$inc] eq "-h") {
		shift(@ARGV);
		help_msg();
		exit 0;
	}
	elsif ($ARGV[inc] eq "-d") {
		shift(@ARGV);
		$debug_mode = 1;
	}
}

if ($#ARGV < 1) { help_msg(); exit 0; }


# Make sure the directory specified exists

$image_file = $ARGV[0];
$directory = $ARGV[1];

unless (-d $directory) {
	print "\n\nDirectory not found: $directory\n"; help_msg(); exit 1;
}
unless (-r $directory) {
	print "\n\nCannot read directory: $directory\n"; help_msg(); exit 1;
}

# Generate command to archive the directory to the image-file

$ind = index($make_image_cmd, "DIRECTORY");
substr($make_image_cmd, $ind, 9) = $directory;

$ind = index($make_image_cmd, "IMAGE_FILE");
substr($make_image_cmd, $ind, 10) = $image_file;


# Create the image-file archive.
#     priocntl -e -c RT -p 59 mkisofs -R $DIR | cdrecord -v fs=6m speed=2 -
#     mkisofs -R $DIR | cdrecord -v fs=6m speed=2 -

print "\n  Ready to archive directory $directory to image-file 
$image_file ...";
print "\n  Press Return to continue: ";
$ans = <STDIN>;


if ($debug_mode == 1) { print "\n$make_image_cmd\n"; }

$status = system( $make_image_cmd );

if ($status != 0) {
	die "\n   Error transferring data...command failed\n";
}

exit 0;


#---------------------------------------------------------------------
# Print an array of strings with freakin spaces between the elements!

sub pretty_print {
	for ($i = 0; $i <= $#_; $i++) { print "$_[$i] "; }
	print "\n";
}


#---------------------------------------------------------------------
# Display help info

sub help_msg {

	print "\n  Usage:  $prog_name [-d] <image-file> <directory>";
	print "\n     -d : Debug mode (display commands)";
	print "\n     <image-file> : Image file to create";
	print "\n     <directory> : Directory to archive";
	print "\n\n";
	$status = 0;
}



#!/usr/local/bin/perl -T
#
#   ARCHIVE_IMAGE   2-26-01  DSFoster
#
# Script to burn an image file (ISO 9660 filesystem with Rock Ridge
# extensions) to CD using 'cdrecord'. Assumes the image file has
# been created using 'mkisofs'.
#
# May require environment variable CDR_DEVICE be set according to
# man page for 'cdrecord', eg. "setenv CDR_DEVICE 1,4,0"
# (scsi-bus,target,lun). Use 'cdrecord -scanbus' to determine
# the device. If this variable is not set then be sure the device
# is specified using the dev= option to 'cdrecord'.
#
# All local configuration is done within the "CONFIGURATION" section.
#
# This script uses no outside "tainted" data, and is therefore
# secure to use as a setuid script. ["Programming PERL", O'Reilly...]
#
# Usage:
#
#  archive_image <image-file>
#
#      Where <image-file> is the archive (created by mkisofs) to be burned.
#
#
# This script uses system() to perform the following command(s):
#
#   cdrecord dev=1,4,0 -v speed=8 fs=6m <image-file>
#
#
# NOTE: On older systems you must wrap this script within a C
#   program, and make *this* C program setuid. This is because of
#   a kernel bug which creates a "race condition" when a setuid
#   root shell is fired up, creating a security hole. Perl scripts
#   will not run setuid when this kernel bug is apparent.
#   ["Programming PERL", O'Reilly..., pg. 360]
#
# Modifications:
#
# 02-02-01 DSF Created, using bourne shell version at template.
#


#--- CONFIGURATION ---------------------------------------------------

# For security reasons use absolute paths for all programs, devices and
# mount points!

$prog_name   = "archive_image";              # Name of program
@local_hosts = qw( ivem );                   # Valid hostnames
$bin_dir = "/usr/bin";                       # Location of binaries

$archive_cmd = "${bin_dir}/cdrecord dev=1,4,0 -v fs=6m speed=12 IMAGE_FILE";

#----- End Configuration ---------------------------------------------


# Clean up the path for secure operation in setuid mode

$ENV{PATH} = '/bin:/usr/bin';

# Make sure the local host is correct!!

chop($host = `hostname`);
$host_index = -1;
for ($i = 0; $i <= $#local_hosts; $i++) {
	if ($host eq $local_hosts[$i]) {
		$host_index = $i;
		$file_system = $file_systems[$i];
	}
}
if ($host_index == -1) {
	print "  This program can only be run on hosts ( @local_hosts )\n";
	exit 1;
}

# Check arguments and set flags

$debug_mode = 0;

for ($inc = 0; $inc <= $#ARGV; $inc++) {
	if ($ARGV[$inc] eq "-h") {
		shift(@ARGV);
		help_msg();
		exit 0;
	}
	elsif ($ARGV[inc] eq "-d") {
		shift(@ARGV);
		$debug_mode = 1;
	}
}

if ($#ARGV < 0) { help_msg(); exit 0; }      # No image-file specified


# Make sure the image file specified exists and is readable

$image_file = $ARGV[0];

unless (-f $image_file) {
	print "\n\nImage file not found: $image_file\n";
	help_msg();
	exit 1;
}
unless (-r $image_file) {
	print "\n\nCannot read image-file: $image_file\n";
	help_msg();
	exit 1;
}

# Generate command to burn the data

$ind = index($archive_cmd, "IMAGE_FILE");
substr($archive_cmd, $ind, 10) = $image_file;


# Archive the image file to CD.
#   Burn CD using cdrecord.
#   Use priocntl to raise priority of mkisofs process (doesn't work)
#   Note: use of priocntl doesn't seem to work.
#
#     priocntl -e -c RT -p 59 mkisofs -R $DIR | cdrecord -v fs=6m speed=2 -
#     mkisofs -R $DIR | cdrecord -v fs=6m speed=2 -

print "\n  Ready to archive image-file $image_file to CD ...";
print "\n  Press Return to continue: ";
$ans = <STDIN>;

if ($debug_mode == 1) { print "\n$archive_cmd\n"; }

$status = system( $archive_cmd );

if ($status != 0) {
	die "\n   Error archiving image-file...command failed\n";
}

exit 0;


#---------------------------------------------------------------------
# Print an array of strings with freakin spaces between the elements!

sub pretty_print {
	for ($i = 0; $i <= $#_; $i++) { print "$_[$i] "; }
	print "\n";
}


#---------------------------------------------------------------------
# Display help info

sub help_msg {

	print "  \nUsage:  $prog_name [-d] <image-file>";
	print "\n     -d : Debug mode (display commands)";
	print "\n     <image-file> : Image-file to burn\n";
	print "\n\n     Example:  $prog_name cdimage.raw\n\n";
	$status = 0;
}



#!/usr/local/bin/perl -T
#
#   MOUNT_CD   2-21-01  DSFoster
#
# Perl script to mount/unmount external CD.
#
# All local configuration is done within the "CONFIGURATION" section.
#
# This script uses no outside "tainted" data, and is therefore
# secure to use as a setuid script. ["Programming PERL", O'Reilly...]
#
# Usage:
#
#  mount_cd [-u] [-s] [-d]
#      -u : unmount\n
#      -s : work silently
#      -d : debug mode (echo commands)
#
# This script uses system() to perform commands similar to the
# following:
#
#   mount -F hsfs -o ro /dev/dsk/c1t4d0s0 /mnt
#
# NOTE: On older systems you must wrap this script within a C
#   program, and make *this* C program setuid. This is because of
#   a kernel bug which creates a "race condition" when a setuid
#   root shell is fired up, creating a security hole. Perl scripts
#   will not run setuid when this kernel bug is apparent.
#   ["Programming PERL", O'Reilly..., pg. 360]
#
# Modifications:
#
#  2-02-01 DSF Created from bourne shell script.
#


#--- CONFIGURATION ---------------------------------------------------

# For security reasons use absolute paths for all programs, devices and
# mount points!

$local_host  = "ivem";                       # Local host
$mount_point = "/mnt";                       # Mount the disk here
$device = "/dev/dsk/c1t4d0s0";               # Device for CD

$prog_name   = "mount_cd";                   # Name of program
$mount_cmd   = "/etc/mount";                 # Command for mounting
$umount_cmd  = "/etc/umount";                # Command for unmounting

#---------------------------------------------------------------------


# Clean up the path for secure operation in setuid mode

$ENV{PATH} = '/bin:/usr/bin';

# Make sure the local host is correct!!

chop($host = `hostname`);
if ($host ne $local_host) {
	print "  This program can only be run on $local_host\n";
	exit 0;
}

# Check arguments and set flags

$debug_mode = 0;
$silent_mode = 0;
$unmount_flag = 0;

for ($inc = 0; $inc <= $#ARGV; $inc++) {
	if ($ARGV[$inc] eq "-h") {
		print "  \nUsage:  $prog_name [-u] [-s] [-d]\n";
		print "\n     -u : unmount";
		print "\n     -s : work silently";
		print "\n     -d : debug mode (echo commands)\n";
		print "\n   Mounts CD at $mount_point \n\n";
		exit 0;
	}
	elsif ($ARGV[$inc] eq "-d") {            # Debug mode (echo cmds)
		$debug_mode = 1;
	}
	elsif ($ARGV[$inc] eq "-s") {            # Work silently
		$silent_mode = 1;
	}
	elsif ($ARGV[$inc] eq "-u") {            # Unmount
		$unmount_flag = 1;
	}
}

# Mount/unmount the CD

if ($unmount_flag == 1) {
	if ($silent_mode == 0) {
		print "  Unmounting $mount_point \n";
	}
	@args = ( $umount_cmd, $mount_point );
	if ($debug_mode == 1) { pretty_print(@args) };

	$status = system( @args );         ### Unmount the disk

	if ($status != 0) {
		die "\n   Cannot unmount $mount_point: command failed:\n";
	}
}
else {
	if ($silent_mode == 0) {
		print "  Mounting CD at $mount_point \n";
	}

	@args = ( $mount_cmd, "-F", "hsfs", "-o", "ro" , $device, $mount_point );
	if ($debug_mode == 1) { pretty_print(@args) };

	$status = system( @args );             ### Mount the drive

	if ($status != 0) {
		die "\n   Cannot mount $mount_point: command failed:\n";
	}
}


#-------------------------------------------------------------------------
# Print an array of strings with freakin spaces between the elements!

sub pretty_print {
	for ($i = 0; $i <= $#_; $i++) { print "$_[$i] "; }
	print "\n";
}
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
Received on Thu Jan 10 13:52:12 2002

This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:42:31 EST