Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is it possible to verify if the system has a DVD burner installed? I need this for a script.

share|improve this question
up vote 4 down vote accepted

As said in a comment, there is a cleaner way of doing that: wodim -prcap which gives exactly what you need.

Device seems to be: Generic mmc2 DVD-R/DVD-RW.

Also, dmesg | grep RW, in my case (DVD-RW/BD reader drive) it returns something like

[    2.399074] ata2.00: ATAPI: HL-DT-ST DVDRW/BDROM CT40N, A101, max UDMA/133
[    2.409247] scsi 1:0:0:0: CD-ROM            HL-DT-ST DVDRWBD CT40N    A101 PQ: 0 ANSI: 5

and wodim dev=/dev/cdrom -scanbus:

        1,0,0   100) 'HL-DT-ST' 'DVDRWBD CT40N   ' 'A101' Removable CD-ROM
share|improve this answer
wodim -prcap will give you better output about the capabilities of the device. – Jodie C Apr 8 '12 at 1:37
@JodieC didn't know about this one. Added to my answer – Renan Apr 8 '12 at 1:40

Simply enough: lshal|grep dvdr

share|improve this answer
This works if the system uses HAL, and some newer distros (e.g. Arch Linux, newer Ubuntu versions) don't. – Renan Apr 8 '12 at 1:16

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.