EJECT(1) EJECT(1)
eject - eject a removable media device
eject [ [ controller_id ] scsi_id [ lun ] | device | dir ]
eject ejects a removable mediad device. If the device has mounted
filesystems, eject will first try to unmount them.
Without any options, eject will act upon the first device it finds in the
hardware inventory table.
device
Specify the device to eject. The device may be specified using any
of the names described in the mediad(1m) man page. Note that some
devices do not support software eject.
dir If mediad is running, the mount point of the filesystem on the disk
to be ejected can be specified.
[controller_id] scsi_id
If mediad is running, the controller id and the scsi id of the
device to be ejected can be specified. If the controller id is left
out, it will default to 0.
/dev/rdsk/fd* floppy devices
/dev/scsi/* generic SCSI devices (for CD-ROM drives)
/dev/tape shorthand for the tape device on the system
/dev/rmt/* real name for all tape devices on the system
/etc/fsd.tab table of devices monitored by mediad
An error will occur if the specified device does not have a disk in it,
or if the file system on the disk couldn't be unmounted.
eject /dev/scsi/sc0d6l0 eject CD-ROM disk (controller 0 SCSI id 6)
eject /dev/rdsk/fds0d2.3.5 eject floppy disk (controller 0 SCSI id 2)
eject 0 2 eject floppy disk (controller 0 SCSI id 2)
eject 2 eject floppy disk (controller 0 SCSI id 2)
mediad(1M), mount(1M), umount(1M), ds(7M), smfd(7M)
The exit codes for eject have the following meanings:
0 : success
1 : Incorrect usage. Check the eject man page.
Page 1
EJECT(1) EJECT(1)
2 : The drive is busy. Make sure no programs are using the drive.
3 : Unable to eject. Try hardware eject.
4 : There is no media in the drive. Make sure you are specifying the
right drive.
5 : Software eject not supported. Use hardware eject.
6 : No such device. Check your scsi id, fsname, or dir.
7 : A system error has occurred. See /var/adm/SYSLOG for more info.
PPPPaaaaggggeeee 2222 [ Back ]
|