On Tue, 05 Apr 2005 01:27:12 GMT, Logan Shaw
>> If I understand you correctly, one of the big difficulties that the
>> /dev tree is not managed by the operating system.
>If by "operating system" you mean "kernel", then yes, that's true.
>However, if you include devfsadmd as part of the operating system
>like I do, then it's not true.
Yes, I meant kernel. Sorry for the imprecise language. I'm not sure I
would include administrative programs as part of the OS per se.
>> This may result in
>> the appearance of 'ghost' devices - devices that are left over from
>> previous instantiations of the OS.
>You can find whether those exist by doing "devfsadm -Cnsv".
>And you can remove them with "devfsadm -Cnv".
Yes, however many, many systems are not run this way. (i.e. with the
junk that accumulates over time cleaned up)
>> Additionally, some configurations -
>> especially RAID ones - may have devices that are present in the /dev
>> tree but not current plumbed to a /devices entry.
>Hmm, how would that happen? How could they be of any meaning, unless
>something were creating device nodes in /dev? And if that were happening,
>isn't that supposed to be a no-no now that /devices exists?
I have seen this with Hi-Av systems where the secondary (spare,
whatever) has references to devices in /dev but, due to the current
role of the server (i.e. secondary) are not active with respect to the
devices they reference. Even in cases as simple as dual-initiated
SCSI, the secondary is typically disabled from accessing the disk
devices until its role is changed to become primary.
In simpler cases, entries are left in /dev that point to /devices
entries that simply no longer exist due to hardware configuration
changes, changes in drivers or software, etc.
>> The /devices tree is managed by the OS, so it is the system of record
>> for devices.
>Yes, in the sense that /devices is always supposed to correspond
>pretty directly to the kernel's view of the devices that actually
>exist arranged in a hierarchy that corresponds to their relation
>to each other. But as I mentioned before, neither of them is
>managed by the OS itself.
I was with you until the last sentence. If by OS you mean kernel, then
the /devices tree is explicitely managed and guaranteed to be the
representation of the kernel's understanding (view) of the hierarchy
of devices under its control. So, its not a case of neither, but
rather one of them not be managed (i.e. /dev).
However, you say that your definition of OS includes the various
administrative programs shipped with the kernel. In that context, the
relationship between /dev and /devices *is* managed via the devfsadm
mechanisms you describe. So, how is the OS (under your definition) not
managing the relation?
Quote:> - Logan