C H A P T E R  3

Optical Disk Drive Test (cddvdtest)


cddvdtest Description

cddvdtest verifies the functionality of optical disk drives.The disktest probe detects the media type in the drive and shows the test options for the media found. If inserted media is not supported by the drive, the disktest probe shows an error and registers CD-ROM options as default.



Note - cddvdtest is a newly consolidated test which is used to test the optical media drives such as CD-ROM, DVD-ROM, DVD-RAM, and CD-DVD-RW drives.



Volume Management

cddvdtest tests the optical drive(s) even if the volume manager is not running. If the volume manager is running and no media is installed in the drive(s), SunVTS prompts you to install media in the drive before selecting the test. The test fails if you try to run it without media in the drive.



Note - When testing rewritable media, the media can be blank or can contain the SunVTS test data. When testing write-once media, the media (such as CD-R) must be blank before starting the write test. Such media could still run multiple passes of the test, because after the first write test, the subsequent tests treat the media as read only and perform the test accordingly.



For CD-ROM and DVD-ROM drives, the test checks the unit by reading either the CD or DVD. For CD-ROMs, each track is classified as follows:

For rewritable CD media, the test can write one or more tracks in one test pass. cddvdtest writes tracks on next available space on the media. If the media is full, cddvdtest automatically erases the whole and starts from the beginning of the media..

For rewritable DVD media, the test writes only one track in one test pass (because there is only one track in DVD format). cddvdtest blanks the media when starting the test, if the media is not already blank.

For rewritable media types, the test verifies write, read, and other supporting functions of CD and DVD RW drives. The supported media include the following:



Note - cddvdtest is not a scalable test.




cddvdtest Hardware and Software Requirements

Requirements for cddvdtest differ based on the media type.

CD-ROM and DVD-ROM

The drive must have the appropriate CD-ROM or the DVD-ROM media before performing the test.

When a CD-ROM is loaded in the drive, cddvdtest uses CD-ROM specific options to test the drive. When a DVD-ROM is loaded, the test uses DVD-ROM specific options. Whenever you change the media in the drive, you must perform a reprobe (refer to the SunVTS User's Guide for details) so that the SunVTS kernel associates the correct test options with the media.

CD-RW and DVD-RW

When testing rewritable media, reprobing is required if the media is changed. To prevent accidentally erasing useful data on a media used for testing, cddvdtest accepts the test media only if it is blank or it contains SunVTS test data (data that is written by cddvdtest itself). The test checks these conditions at probe time and at the start of the test.

In case of nonblank media or media with nonSunVTS test data, the media must be blanked first by using the cdrw utility. Because -R or +R media can be written only once, only blank media should be used for write testing. Such media could still run multiple passes of the test because after the first write test, the subsequent tests treat the media as read only and perform the test accordingly.

To prevent media corruption, the test posts a Warning message if it stops druing the write, finalize, format, or erase phases and continues until the current operation is completed. Wait until the test completes before doing any operation on the drive.

Do not stop the test in the middle of a writing operation. Doing so may cause damage to the media in some cases. Set a limited number of passes for cddvdtest, set Max Passes=0 (unlimited) and stop the test manually. If a media is damaged, blank the media with cdrw command.



Note - DVD+RW media cannot be blanked.



The default delay between two passes for the read write media is three minutes. This setting enables the test to preserve the media by running fewer passes during long test runs. This setting also allows for stopping the test between passes.


cddvdtest Subtests

cddvdtest has different subtests for each media type.

CD-RW and DVD-RW


TABLE 3-1 cddvdtest Subtests for CD-RW and DVD-RW Media

Subtest

Description

Blank

Erases data on DVD-RW media and CD-RW media if not blank. This subtest does not apply to DVD+RW media because this media type can not be blanked. This subtest does not apply to DVD+RW media because this media type does not support blank and always starts from the beginning of the track by overwriting earlier data (sunvts data) on the track.

Simulation

Performs a write track with laser turned off. This mode tests writing function without data written to the media.

Write

Writes to media with predefined data patterns of 0..ff hex. For CD-RW media, track can be specified as data or audio track.

Read

Reads the written data.

Compare

Compares write/read data, reports failure if miscompared.

Read Disk/Track

Reads and shows Disk Table of Contents (TOC).

Eject

Ejects media.


 


cddvdtest Options

To reach the following dialog box, right-click on the test name in the System Map and select Test Parameter Options. If you do not see this test in the System Map, you might need to expand the collapsed groups, or your system may not include the device appropriate to this test. Refer to the SunVTS User's Guide for more details.

cddvdtest has different test options for each media type.

CD-ROM Test Options

This section describes the cddvdtest options for CD-ROMs.


FIGURE 3-1 cddvdtest Test Parameter Options Dialog Box for CD-ROM

Screenshot of the cddvdtest Test Parameter Options dialog box for CD-ROM


 


TABLE 3-2 cddvdtest Options for CD-ROM

Option

Description

CD Type

The CD Type menu lists the types of compact discs that can be tested. The choices are: Pdo, Multi-session, or Other the default CD type is Other). In Connection test mode, this option has a default value of Other.

Note - Your choice must correspond with the disc used for testing.

% Data/Track

Tests a percentage of data on each track. Type a value between 0 and 100 in this field to indicate the percentage. In the online and connection tests this option has a default value of 2%.

Read Mode

cddvdtest reads the CD either in Random or Sequential mode. In Random mode, data blocks are read from random track positions; in Sequential mode, data blocks are read in sequence. For both modes, the total number of blocks read is determined by the %_of_data option. In the online and Connection tests this option has a default value of random.

Audio Test

Enables or disables the audio test. You must connect headphones or a speaker to the audio jack on the CD player to hear audio output. In the Connection test, this option has a default value of disable.

Volume

Adjusts the volume. Type a value between 0 and 255 in this field. In the online and connection tests this option has a default value of 125.


DVD-ROM Test Options


This section describes the cddvdtest options for DVD-ROMs.
FIGURE 3-2 cddvdtest Test Parameter Dialog Box for DVD-ROM

Screenshot of the cddvdtest Test Parameter Options dialog box for DVD-ROM


 


TABLE 3-3 cddvdrwtest options for DVD-ROM

Option

Description

% Data/Track

Specifies a percentage of data to test for each track.

Use a number between 0 and 100.

Read Mode

Specifies either Random or Sequential mode. Random mode reads data blocks from random track positions. Sequential mode reads data blocks in sequence. For both modes, the total number of blocks read is determined by the % Data/Track value.


CD-RW Test Options


This section describes the test options for CD-RWs.
FIGURE 3-3 cddvdtest Test Parameter Options Dialog Box for CD-RW

Screenshot of the cddvdtest Test Parameter Options dialog box for CD-RW


 


TABLE 3-4 cddvdtest Options for CD-RW

Option

Description

SimulationWrite

Disables or enables simulation write.

WriteSpeed

Speed entered in terms of nX. Speed is set to closest approximation of nX allowed by the device.

WriteDataTrack

Writes a data track in one test loop.

WriteAudioTrack

Writes an audio track in one test loop.

NumberOfLoop

Number of loops in one test pass comprising data and audio track if enabled.

Close

Closes after writing. Cannot write more tracks on the media.

Erase None

Does not erase. The All option erases the whole disk.

Eject

Ejects the disk when the test is completed. Do not enable this option in a multiple pass test session.


DVD-RW Test Options


This section describes the cddvdtestoptions for DVD-RWs.
FIGURE 3-4 cddvdtest Test Parameter Options Dialog Box for DVD-RW

Screenshot of the cddvdtest Test Parameter Options dialog box for DVD-RW


 


TABLE 3-5 cddvdtest Options for DVD-RW

Options

Description

SimulationWrite

Disables or enables simulation write.

WriteSpeed

Speed entered in terms of nX. Speed is set to closest approximation of nX allowed by the device.

ImageSize

Specifies track size, how much data is written: 2 MB, 10 MB, 2 GB, 4 GB.

Erase None

Do not erase the media.

Fast

Erases with Fast option. Only the Table of Contents is erased.

All

Erases with All option. Erases whole disk surface.

Eject

Ejects the disk when the test is completed. Do not enable this option in a multiple pass test session.


DVD-RAM Test Options


This section describes the cddvdtestoptions for DVD-RAM.
FIGURE 3-5 cddvdtest Test Parameter Options Dialog Box for DVD-RAM

Screenshot of the cddvdtest Test Parameter Options dialog box for DVD-RAM


 


TABLE 3-6 cddvdtest Options for DVD-RAM

Options

Description

Media Transfer Size

Specifies the media test size in Kbytes.

Test Pattern

Specifies the test pattern: P0, P1, or P2 (Default P0).

The following options are supported:

  • P0 = 0000000000000000
  • P1 = ff00ff00ff00ff00
  • p2 = ffffffffffffffff

Media Coverage

Specifies the percentage of media coverage.

Write Read Mode

Specifies either Readonly or Writeread.



cddvdtest Test Modes

This test supports Connection and Functional test modes for all media types. The test behavior in each mode for the different media types is explained in the following tables.

CD-ROM Test Modes

TABLE 3-7 describes the test modes for CD-ROMs.


TABLE 3-7 Supported Test Modes for CD-ROM

Test Mode

Description

Connection

cddvdtest verifies that a CD-ROM drive is connected to and configured in the system.

Functional

The test registers a failure if the device is found to be busy. This is because SunVTS tests make the assumption that all the resources will be available for testing in the Functional test and the unavailability of a device is interpreted as an indication of a fault condition.


DVD-ROM Test Modes

TABLE 3-8 describes the test modes for DVD-ROMs.


TABLE 3-8 Supported Test Modes for DVD-ROM

Test Mode

Description

Connection

Requests and displays information from the drive and reads two blocks of data from the media to confirm connectivity. An error is reported if no media is loaded in the drive.

Functional

Requests and displays information from the drive, then reads data from the media based on the options that are set in the Test Parameter Options dialog box. An error is reported if no media is loaded in the drive.


CD-RW and DVD-RW Test Modes

TABLE 3-9 describes the test modes for DVD-RWs.


TABLE 3-9 Supported Test Modes for CD-RW and DVD-RW

Test Mode

Description

Connection

Shows basic drive information and supporting modes. Shows disk Table of Contents (TOC) .

Functional

The following subtests are done in sequence. Erase - Erases data if DVD-RW media is not blank, or CD-RW media if full.

  • Simulation (optional) - Performs a write track with Laser turned off. This mode tests writing function without data written to the media.
  • Write - Writes to media with predefined data patterns of 0..ff hex. For CD media track can be specified as data or audio track.
  • Read - Reads the written data.
  • Compare - Compares write/read data, reports failure if miscompared.
  • Blank media (optional).
  • Read Disk/Track - Reads and shows disk table of contents.
  • Ejects (optional).

DVD-RAM Test Modes

TABLE 3-10 describes the test modes for DVD-RAM.


TABLE 3-10 Supported Test Modes for DVD-RAM

Test Mode

Description

Connection

Requests and displays information from the drive and reads two blocks of data from the media to confirm connectivity. An error is reported if no media is loaded in the drive.

Functional

Requests and displays information from the drive, then reads data from the media based on the options that are set in the Test Parameter Options dialog box. An error is reported if no media is loaded in the drive.



cddvdtest Command-Line Syntax

cddvdtest has different command-line syntax for each media type.

CD-ROM Command-Line Syntax

/opt/SUNWvts/bin/cddvdtest standard_arguments -o dev=raw_device_name,mode=mode,read=random|sequential,data=%_of_data,vol=volume,audio=enable|disable,type=CD_type


TABLE 3-11 CD-ROM Command-Line Syntax

Argument

Description

dev=raw-device-name

Specifies the name of the raw device to be tested.

read=random|sequential

Indicates random or sequential read access.

data=%-of-data

Sets the percentage of data to be tested. You can specify 0 to 100 percent.

vol=volume

Controls the audio volume. You can specify 0 through 255. The default is 255.

audio=enable|disable

Enables or disables the audio test. You must connect headphones or a speaker to the audio jack on the CD player to hear audio output.

type=CD-type

Specifies the type of CD used for the test. The choices are pdo, multi-session, sunos and other. The default is other.


DVD-ROM Command-Line Syntax

/opt/SUNWvts/bin/cddvdtest standard_arguments -o dev=device_name,read=random|sequential,data=%_of_data


TABLE 3-12 DVD-ROM Command-Line Syntax

Argument

Description

dev=device_name

Specifies the name of the device to test, for example /dev/rdsk/cntndn.

read=random|sequential

Indicates random or sequential read access.

data=%_of_data

Sets the percentage of data to test. Use a number from 0 to 100.


CD-RW Command-Line Syntax

/opt/SUNWvts/bin/cddvdtest standard_arguments -o dev=cntndnsn,media=CD-RW,nosim,speed=n,nodata,noaudio,loop=n,close,erase={none,all},eject


TABLE 3-13 CD-RW Command-Line Syntax

Argument

Description

dev=cntndnsn

Specifies the device under test.

media=CD-RW

Specifies the media.

nosim

Disables simulation write.

speed=n

Specifies the speed. Entere the speed in terms of nX.

nodata

Disables data track test.

noaudio

Disables audio track test.

loop=n

Specifies 1 to 40, the number of loops in one test pass.

close

Closes track after the test, no track can be added.

erase={none, all}

none - Does not erase media after test complete.

all - Erases entire disk.

eject

Ejects disk after test completed.


DVD-RW Command-Line Syntax

/opt/SUNWvts/bin/cddvdtest standard_arguments -o dev=cntndnsn,media={DVD-RW,DVD+RW},nosim,speed=n,imagesize={2MB,10MB,2GB,4GB},erase={none, fast,all},eject


TABLE 3-14 DVD-RW Command-Line Syntax

Argument

Description

dev=cntndnsn

Specifies the device under test.

media={DVD-RW, DVD+RW}

Specifies the media.

nosim

Disables Simulation Write.

speed=n

Specifies the speed. Enter the speed in terms of nX.

imagesize={2MB,10MB,2GB,4GB}

Specifies the image size used in the write/read test.

erase={none, fast, all}

. none - Does not erase media after test complete.

fast - Erases the last track added.

all - Erases entire disk.

eject

Ejects the media.


DVD-RAM Command-Line Syntax

/opt/SUNWvts/bin/cddvdtest standard_arguments -o dev=cntndnsn, rawiosize={32K,64K,128K,256K,512K},rawpattern={P0,P1,P2},rawcover={1% - 100%},rawrw={Readonly,Writeread}


TABLE 3-15 DVD-RAM Command-Line Syntax

Argument

Description

dev=cntndnsn

Specifies the device under test.

rawiosize = 32K,64K,128K,256K,512K

Specifies the iosize for write and read operation. Default is 256K.

rawpattern = P0,P1,P2

The following options are supported. Default is P0.

P0 = 0000000000000000

P1 = ff00ff00ff00ff00

p2 = ffffffffffffffff

rawcover = 1-100

 

Specifies the media coverage in percent. Default is 30.

rawrw = Readonly, Writeread

Selects the Read and Write operations. Default is Readonly.