In order to use CD-ROM/DVD drive in Linux, you first need to mount it. I will describe below how to mount CD-ROM/DVD drive in Linux.
The first step is to identify the device name of your CD-ROM or DVD drive. To do so, you can use dmesg output which indicates the device name for your CD-ROM or DVD drive.
hdd: PIONEER DVD-RW DVR-106D, ATAPI CD/DVD-ROM drive
In the above example, the device name is /dev/hdd. Verify that /dev/hdd exists.
Now go ahead and mount the identified device using mount command.
I assume that the mount point /media/cdrom already exists. Note that if the drive is empty or the media format of an inserted CD is not supported, the mount command will fail with the error message: "mount: No medium found".
While in the above example I use the root permission to mount a CD-ROM drive, you can actually allow non-root users to mount a CD-ROM drive, by editing /etc/fstab:
/dev/hdd /media/cdrom iso9660 ro,user,noauto 0 0
In the above, adding the "user" option in the fstab entry for /dev/hdd will allow normal users to mount/unmount the corresponding device.
Subscribe to Xmodulo
Do you want to receive Linux FAQs, detailed tutorials and tips published at Xmodulo? Enter your email address below, and we will deliver our Linux posts straight to your email box, for free. Delivery powered by Google Feedburner.
Did you find this tutorial helpful? Then please be generous and support Xmodulo!
Latest posts by Dan Nanni (see all)
- How to set up Apt caching server on Ubuntu or Debian - February 7, 2016
- How to monitor OpenFlow messages with packet sniffer - February 2, 2016
- How to search multiple pdf documents for words on Linux - January 13, 2016