Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 154857 - should mkinitrd add sg module if SCSI controllers are defined in modprobe.conf?
Summary: should mkinitrd add sg module if SCSI controllers are defined in modprobe.conf?
Status: CLOSED DUPLICATE of bug 151534
Alias: None
Product: Fedora
Classification: Fedora
Component: mkinitrd
Version: 3
Hardware: i386
OS: Linux
Target Milestone: ---
Assignee: Peter Jones
QA Contact: David Lawrence
Depends On:
TreeView+ depends on / blocked
Reported: 2005-04-14 16:05 UTC by Aleksandar Milivojevic
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2005-04-15 14:22:18 UTC

Attachments (Terms of Use)

Description Aleksandar Milivojevic 2005-04-14 16:05:41 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.6) Gecko/20050324 Firefox/1.0.2 Red Hat/1.0.2-1.4.1.centos4

Description of problem:
Not sure if this is bug or feature reqest...

Anyhow, should mkinitrd load sg (SCSI generic driver) if system contains any SCSI devices (for example, scsi-hostadapter* lines are detected in modprobe.conf)?  Currently, the only way to get SCSI devices that don't have specialized drivers automatically accessible after boot time seems to be either placing "modprobe sg" in /etc/rc.local or building initrd image by hand using --with=sg option.

Udev doesn't seem to be able to handle this.  It's kind of chicken and egg problem.  If there are no /dev/sg* nodes, applications can't trigger loading of sg device driver.  If sg driver is not loaded, udev doesn't create /dev/sg* nodes.  With old (pre-udev, such as Red Hat 7.3) systems this wasn't problem, since monolitic/static /dev contained sg* nodes (and therefore applications were able to trigger loading of sg driver by simply accessing one of sg* nodes).

This affects only some classes of SCSI devices.  For example, disks and tape drives are usually not affected, since they are usually accessed through specialized device drivers (st, sd_mod) and corresponding nodes in /dev.  Devices with no specialized drivers, such as changers in tape libraries for example, do not get any specialized devices automatically created.  So using /dev/sg* is the only way of accessing them.

An alternative approach to the problem would be if patch from bug 135836 is merged into the source tree.  That way users that have a need for /dev/sg* nodes would be able to specify it in configuration file.  That way, when kernel is upgraded, correct initrd image would be generated.  Somehow, I'd preffer having sg loaded always by default (if there are SCSI controllers in the system), but would be perfectly happy with specifying it in configuration file as proposed in bug 135836.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. use mkinitrd on machine with some SCSI hardware

Additional info:

Comment 1 Aleksandar Milivojevic 2005-04-14 18:19:32 UTC
One more alternative would be if "sg" is loaded from /etc/rc.sysinit (part of
initscripts package) when SCSI controlers are detected in the system.

Comment 2 Aleksandar Milivojevic 2005-04-15 14:22:18 UTC
The hotplug module is supposed to load sg driver as needed, and it wa not loaded
because of bug in it (I had buggy version of hotplug package from RHEL4).  The
bug in hotplug has been fixed and should be part of U1.  Marking this is dupe.

*** This bug has been marked as a duplicate of 151534 ***

Note You need to log in before you can comment on or make changes to this bug.