GNOME Bugzilla – Bug 307135
Shows "No media available" when trying to copy from CD/DVD-ROM drive
Last modified: 2005-09-29 14:19:23 UTC
Distribution/Version: Debian GNU/Linux unstable When i try to copy a cd from my CD/DVD-ROM (SAMSUNG DVD-ROM SD-612F) to my DVD-RW drive, i get an error message "No media available: There doesn't seem to be any media in the selected drive." which is obviously wrong, because i can mount the disc and read it's content. I cannot track the issue down, 'cause I don't know much about scsi command and the like, but i just commented out the function bailing out and producing the error dialog, and now i am able to copy my cd ;-) Let me know how i can give further input. Best regards, Philipp
Created attachment 47536 [details] [review] trivial patch to just test if we stop n-c-b from telling wrong things.
Include the output of list_cddrives in this bug.
$ ./list_cddrives name: HL-DT-ST DVDRAM GSA-4040B device: /dev/hda max_speed_read: 32 door: closed type: CD Recorder/CD ReWritable/DVD-RW/DVD+R/DVD+RW/CD Drive/DVD Drive media type: Couldn't open media media size: -0.00 MiB CD-Recorder/SCSI devices only: max_speed_write: 24 id: /dev/hda name: SAMSUNG DVD-ROM SD-612F device: /dev/hdb max_speed_read: 40 door: closed type: CD Drive/DVD Drive media type: Commercial CD or Audio CD (has-data) media size: -0.00 MiB approx. or 0 mins 0 secs CD-Recorder/SCSI devices only: max_speed_write: 0 id: /dev/hdb
when putting the same dist into the DVD-RW drive, it says: name: HL-DT-ST DVDRAM GSA-4040B device: /dev/hda max_speed_read: 32 door: closed type: CD Recorder/CD ReWritable/DVD-RW/DVD+R/DVD+RW/CD Drive/DVD Drive media type: CD-RW (rewritable) (has-data) media size: 701.00 MiB approx. or 80 mins 0 secs CD-Recorder/SCSI devices only: max_speed_write: 24 id: /dev/hda which seems to be more accurate.
requested info has been provided
Was the media mounted in /dev/hdb when the first list_cddrives was launched?
No, it was not mounted. When running list_cddrives while mounted, it says: "media type: Unknown media, CD drive is busy".
Can you try running: dvd+rw-mediainfo /dev/hda with the disc in the drive and unmounted and post the results here?
as expected for a _cd_ the output is: INQUIRY: [SAMSUNG ][DVD-ROM SD-612F ][FS03] GET [CURRENT] CONFIGURATION: :-( non-DVD media mounted, exiting...
You posted the info from hdb, right? Could you run it with hda with the media in the drive? Even though it is a CD we are looking to see if the dvd+rw-mediainfo will detect the media type at all. This will help us isolate the problem. Could you also attach the output of "lshal" to this bug. Thanks.
ok, this is the output for hda: INQUIRY: [HL-DT-ST][DVDRAM GSA-4040B][A303] GET [CURRENT] CONFIGURATION: :-( non-DVD media mounted, exiting...
Created attachment 48500 [details] output ouf lshal
At first glance everything seems fine. I've just added a few warning messages that may help isolate where the error is occurring. These will appear in n-c-b 11.4 (to be released today).
I think it's not fine, see the appended output from hal with the same media put into the DVDROM drive. Media type differs and this leads to the problem when questioning the drive for media size.
Created attachment 49865 [details] lshal output for media in the CD/DVD-ROM drive note that i have a new DVD-RW drive, a _NEC_DVD_RW_ND_3540A, obviously that has no impact on the problem.
I'm sorry, i cannot find out what is going wrong, but I think a problem is that n-c-b doesn't use HAL to figure out the disc size in: nautilus_burn_drive_get_media_size_from_path (const char *device) Maybe there should be a HAL version of this function?
For my drive, get_mmc_profile() bails out and returns -1
What version of n-c-b and HAL are you using now?
OK, I made some changes in CVS HEAD that should help in this case. When we can get a media type from HAL we'll use it to try to get the media size a second time. I also added some messages that will help us track down problems getting the MMC profile. Can you test this from HEAD and run the list_cddrives program again? Thanks.
list_cddrives output for the CD/DVD-ROM device: name: SAMSUNG DVD-ROM SD-612F device: /dev/hdb max_speed_read: 40 door: closed type: CD Drive/DVD Drive media type: Commercial CD or Audio CD (has-data) Could not determine drive profile: Error reading disc information media size: 9.65 MiB approx. or 0 mins 54 secs CD-Recorder/SCSI devices only: max_speed_write: 0 id: /dev/hdb that way, it works nicely for me.
So, it appears that the MMC DISC INFO (51h) command is failing for both HAL and n-c-b. HAL is reporting the wrong media type (CDROM) when it should be (CD-RW). The interesting thing is that we already know the the drive profile is at the point we bail out of get_mmc_profile. The only thing that was left to do was check if the disc was blank. I wonder if we should simply return the profile (sans blank status) instead of an error. I've updated the error message to display the profile value. Could you run the list_cddrives again and post the results?
list_cddrives output for the CD/DVD-ROM device: name: SAMSUNG DVD-ROM SD-612F device: /dev/hdb max_speed_read: 40 door: closed type: CD Drive/DVD Drive media type: Commercial CD or Audio CD (has-data) Could not fully determine drive profile 8: Error reading disc information media size: 9.65 MiB approx. or 0 mins 54 secs CD-Recorder/SCSI devices only: max_speed_write: 0 id: /dev/hdb
Ok, HEAD and 2.11.6 work for me, but obviously HAL has issues with my drive. Maybe you can point me to the right place to report those problems?
*** Bug 316528 has been marked as a duplicate of this bug. ***