-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Monday 2006-01-30 at 10:24 +0200, Roman Protsiuk wrote:
This one is very strange now: trying to boot with DVD inserted. System booted. No mounted DVD. ls -l /dev/hd* gives /dev/hda1 ... /dev/hdc /dev/hdd. :-\ Ejecting DVD. Inserting again. DVD is mounted. Everything OK (or almost everything). I guess my PC is playing tricks with me.
However, thanks for advices, Roma.
PS I've got one e-mail which said that this strange behavior might be related to the udev. I'll try and have a look at that.
You can also have a look at hal (hardware abstraction layer or something like that). The idea is that it monitors the hardware and informs the system of what hardware is available, etc. You can see it with the command "lshal". If I use "lshal --monitor" I can see a lot of text passing by when I put a new cdrom in the drive or plug/unplug an usb thing. Perhaps udev uses this information to know that it has got to create /dev/hdc, and my hypothesis would be that, in your case, when there is no disk in the drive, that information is missing, and the device file "disappears". If I'm not mistaken, udev creates the /dev/tree on the fly, virtually, same as /sys or /proc. In /etc/udev/rules.d/20-cdrom.rules (SuSE 9.3) I have these two lines: BUS="ide", ID="1.0", SYSFS{removable}="1", SYMLINK="dvdrecorder dvdram dvd" BUS="ide", ID="1.1", SYSFS{removable}="1", SYMLINK="cdrecorder cdrom" I think these two creates the symlinks dvdrecorder, dvdram.. etc, to hdc and hdd. I think, also, that you might or should have the rules to create hdc in "50-udev.rules" - but I don't know how. In "/etc/sysconfig/kernel" says: ## Type: yesno ## Default: yes # # Select whether a fully dynamic device nodes directory should be used. If set # to 'yes' the device node directory /dev will be mounted on tmpfs. In this # case all manual modification in the directory will be lost on reboot; these # modification should rather be done via custom udev rules. # If 'no' then /dev is on your disk, but is still modified from udev. That # means if your manual modifications persist depends on udev rules. # You should leave that to 'yes' except you know exactly what you are doing. # See man udev for details. # DEV_ON_TMPFS="yes" Well, that is funny. I installed recently version 10 in another partition, but I'm not using it. Checking its filesystem (the above text excerpt comes from it), I see that there is a real /dev directory, fully populated. Weird. maybe it is populated just in case you choose "no" above. I also see a /etc/udev/static_devices.txt file that looks very promising for your case. It says: # # udev.static_devices.txt # # List of all devices which have to be created statically as automatic # detection does not work. # # Format: # name type major minor mode So, for hdc, you need this line (mind, you have to test it, I can't): hdc b 22 0 600 I don't know how to tell udev to read that, perhaps rebooting. There is no "rcudev reload" command. You probably do not need hdc1, hdc2... but if you do, it's only the "minor" that changes. (hda 3, 0 hdb 3, 64 hdc 22, 0 hdd 22, 64 further info in /usr/src/linux/Documentation/devices.txt) # Octal permissions (man chmod): # UserID * 4 + GroupID * 2 + sticky * 1 # Read * 4 + Write * 2 + Execute * 1 ( owner ) # Read * 4 + Write * 2 + Execute * 1 ( group ) # Read * 4 + Write * 2 + Execute * 1 ( rest ) HTH. Further info. File "/etc/udev/rules.d/55-cdrom.rules" in 10.0 is very different: # cdrom links generated by YaST2 # SUBSYSTEM=="block", ENV{ID_PATH}=="pci-0000:00:1f.1-ide-1:0", SYSFS{removable}=="1", SYMLINK+="dvdram cdrom dvd cdrecorder" This means that if I move the cdrom position in the bus, it would not work. It is hardcoded to the pci identifier. It also means that Yast somehow creates this info. How? Dunno. - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFD3n0ntTMYHG2NR9URAjC9AJ9tySDPob8kKlVQcB2+PI24zBpO0QCcDaJe gSkh8ZmCSoEr3MdETo3nsmg= =j3uq -----END PGP SIGNATURE-----