[nSLUG] mounting CDROM

Peter Cordes peter at llama.nslug.ns.ca
Wed Jun 4 15:39:57 ADT 2003


On Tue, Jun 03, 2003 at 09:29:32PM -0300, Diane Derrick wrote:
> Ok.  The system is an old HP netserver 4/33 le.  It has one onboard SCSI
> controller and one IDE controller.  The CDROM is the master on the IDE
> controller by itself.  I have not changed anything in the cmos since the
> install and I have tried the install cd as well as others.  Heres the dmesg
> dump

Well, looks like you're not the first person to wonder about using a CDU76E
with Linux:  http://lists.samba.org/pipermail/linux/1995-August/000055.html.
Hehe.  The Linux kernel identifies it as an ATAPI CDROM drive, which is a
good thing:  It's not a weird proprietary-interface thing, and should work
the same way as any modern drive (well, slower, of course :).  As Donald
suggests, you could use SCSI-emulation, which is necessary for burning CDs
with a burner, but not necessary for read-only drives.  It's simpler to
stick with the IDE CD driver.

 The source of your "driver not present" error message is the ide_open()
function in /usr/src/linux/drivers/ide/ide.c.  Even if you don't know C,
it's not too hard to understand:

static int ide_open (struct inode * inode, struct file * filp)
{
	ide_drive_t *drive;
        ...
	if (drive->driver == NULL) {
		if (drive->media == ide_disk)
			(void) request_module("ide-disk");
		if (drive->scsi)
			(void) request_module("ide-scsi");
		if (drive->media == ide_cdrom)
			(void) request_module("ide-cd");
		if (drive->media == ide_tape)
			(void) request_module("ide-tape");
		if (drive->media == ide_floppy)
			(void) request_module("ide-floppy");
	}

	...
	
	if (drive->driver != NULL && !drive->dead)
		return DRIVER(drive)->open(inode, filp, drive);
	printk(KERN_WARNING "%s: driver not present\n", drive->name);
	...
	return -ENXIO;
}

 From the fact that "hda: driver not present" gets printed, we can tell that
your kernel never finds a driver it likes for hda.  Since you were able to
install RedHat, and its installer runs on Linux (booting the CD boots a
Linux kernel, and the installer runs under that kernel), Linux must be able
to read data from the CDROM.  It is likely that if the IDE CDROM driver code
was in the kernel, it would be working right.  (If the ide-scsi code is
compiled in or loaded as a module, it could be causing the ide-cd code to
not touch the cdrom, but that seems unlikely, because your lsmod output
didn't show it, and besides, you don't have hda=ide-scsi on the kernel
command line.) The obvious conclusion is that the IDE CDROM driver isn't in
the kernel.  It was probably built as a module, but for some reason it isn't
getting loaded.  You do have some other modules that loaded ok, so it's
strange that ide-cd.o wouldn't be working.  Try
modprobe ide-cd
(as root, of course) and see what kind of error message you get.  (run dmesg
again;  New messages are added to the end of the list.)


-- 
#define X(x,y) x##y
Peter Cordes ;  e-mail: X(peter at llama.nslug.n , s.ca)

"The gods confound the man who first found out how to distinguish the hours!
 Confound him, too, who in this place set up a sundial, to cut and hack
 my day so wretchedly into small pieces!" -- Plautus, 200 BC




More information about the nSLUG mailing list