Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
  Previous   Contents   Next 
   
 
Chapter 18

Accessing Removable Media (Tasks)

This chapter describes how to access removable media from the command line in the Solaris environment.

For information on the procedures associated with accessing removable media, see the following:

For background information on removable media, see Chapter 17, Managing Removable Media (Overview).

Accessing Removable Media (Task Map)

Task

Description

For Instructions

1. (Optional) Add the removable media drive

Add the removable media drive to your system, if necessary.

"How to Add a New Removable Media Drive"

2. (Optional) Decide whether you want to use removable media with or without volume management (vold)

Volume management (vold) runs by default. Decide whether you want to use removable media with or without volume management.

"How to Stop and Start Volume Management (vold)"

3. Access removable media

Access different kinds of removable media with or without volume management running.

"How to Access Information on Removable Media"

4. (Optional) Copy files or directories

Copy files or directories from the media as you would from any other location in the file system.

"How to Copy Information From Removable Media"

5. (Optional) Configure a system to play musical CDs or DVDs

You can configure a system to play musical CDs or DVDs, but you will need third-party software to play the media.

"How to Play a Musical CD or DVD"

6. Find out if the media still in use

Before ejecting the media, find out if it is still in use.

"How to Find Out If Removable Media Is Still in Use"

7. Eject the Media

When you finish, eject the media from the drive.

"How to Eject Removable Media"

Accessing Removable Media (Overview)

You can access information on removable media with or without using volume manager. For information on accessing information on removable media with CDE's File Manager, see "Using Removable Media with File Manager" in Solaris Common Desktop Environment: User's Guide.

Starting in the Solaris 8 6/00 release, volume manager (vold) actively manages all removable media devices. This means any attempt to access removable media with device names such as /dev/rdsk/cntndnsn or /dev/dsk/cntndnsn will be unsuccessful.

Using Removable Media Names

You can access all removable media with different names. The following table describes the different media names that can be accessed with or without volume management.

Table 18-1 Removable Media Names

Media

Volume Management Device Name

Volume Management Device Alias Name

Device Name

First diskette drive

/floppy

/vol/dev/aliases/floppy0

/dev/rdiskette

/vol/dev/rdiskette0/

volume-name

First, second, third CD-ROM or DVD-ROM drives

/cdrom0

/cdrom1

/cdrom2

/vol/dev/aliases/cdrom0

/vol/dev/aliases/cdrom1

/vol/dev/aliases/cdrom2

/vol/dev/rdsk/cntn[dn]/

volume-name

First, second, third Jaz drive

/rmdisk/jaz0

/rmdisk/jaz1

/rmdisk/jaz2

/vol/dev/aliases/jaz0

/vol/dev/aliases/jaz1

/vol/dev/aliases/jaz2

/vol/dev/rdsk/cntndn/

volume-name

First, second, third Zip drive

/rmdisk/zip0

/rmdisk/zip1

/rmdisk/zip2

/vol/dev/aliases/zip0

/vol/dev/aliases/zip1

/vol/dev/aliases/zip2

/vol/dev/rdsk/cntndn/

volume-name

First, second, third, PCMCIA drive

/pcmem/pcmem0

/pcmem/pcmem1

/pcmem/pcmem2

/vol/dev/aliases/pcmem0

/vol/dev/aliases/pcmem1

/vol/dev/aliases/pcmem2

/vol/dev/rdsk/cntndn/

volume-name

Use this table to identify which removable media name to use with specific Solaris commands.

Solaris Command

Device Name

Usage Examples

ls, more, vi

/floppy

/cdrom

/rmdisk/zip0

/rmdisk/jaz0

/pcmem/pcmem0

ls /floppy/myfiles/

more /cdrom/myfiles/filea

fsck, newfs, mkfs

/vol/dev/aliases/floppy0

/vol/dev/rdsk/cntndn

newfs /vol/dev/aliases/floppy0

mkfs -F udfs /vol/dev/rdsk/cntndn

Guidelines for Accessing Removable Media Data

Most CDs and DVDs are formatted to the ISO 9660 standard, which is portable, so most CDs and DVDs can be mounted by volume management. However, CDs or DVDs with UFS file systems are not portable between architectures, so they must be used on the architecture for which they were designed.

For example, a CD or DVD with a UFS file system for a SPARC platform cannot be recognized by an IA platform. Likewise, an IA UFS CD cannot be mounted by volume management on a SPARC platform. The same limitation applies to diskettes. (Actually, some architectures share the same bit structure, so occasionally a UFS format specific to one architecture will be recognized by another architecture, but the UFS file system structure was not designed to guarantee this compatibility).

To accommodate the different formats, the CD or DVD is split into slices, which are similar in effect to partitions on hard disks. The 9660 portion is portable, but the UFS portion is architecture-specific. If you are having trouble mounting a CD or DVD, particularly if it is an installation CD or DVD, make sure its UFS file system is appropriate for your system's architecture (check the label on the CD or DVD).

Accessing Jaz Drives or Zip Drives

You can determine whether accessing your Jaz or Zip drives changes from previous Solaris releases, depending on the following:

  • If you are upgrading from the Solaris 8 6/00 release to the Solaris 9 release, you can continue to access your Jaz drives and Zip drives in the same way as in previous releases.

  • If you are freshly installing the Solaris 9 release, you cannot access your Jaz drives and Zip drives in the same way as in previous Solaris releases.

    Follow these steps if you want to access your Jaz and Zip drives in the same way as in previous Solaris releases:

    1. Comment the following line in the /etc/vold.conf file by inserting a pound (#) sign at the beginning of the text, like this:

      # use rmdisk drive /dev/rdsk/c*s2 dev_rmdisk.so rmdisk%d
    2. Reboot the system.

How to Add a New Removable Media Drive

Adding a new removable media drive involves creating the /reconfigure file and rebooting the system so that volume management recognizes the new media drive.

  1. Become superuser.

  2. Create the /reconfigure file.

    # touch /reconfigure
  3. Bring the system to run level 0.

    # init 0
  4. Turn off power to the system.

  5. Connect the new media drive.

    See your hardware handbook for specific instructions.

  6. Turn on power to the system.

    The system comes up to multiuser mode automatically.

How to Stop and Start Volume Management (vold)

Occasionally, you might want to manage media without the help of volume management. This section describes how to stop and restart volume management.

How to Stop Volume Management (vold)

  1. Make sure media is not being used.

    If you are not sure whether you have found all users of the media, use the fuser command, as described in "How to Find Out If Removable Media Is Still in Use".

  2. Become superuser.

  3. Enter the volmgt stop command.

    # /etc/init.d/volmgt stop
    #
 
 
 
  Previous   Contents   Next