I am having a problem with my symlinks in the /dev directory
When I want to mount a cdrom or a dvd, the device that I must mount is /dev/hda. By default, the OS creates symlinks that point to /dev/hda (e.g. /dev/cdrom, /dev/dvd).
The problem is that for some reason, it is adding numbers behind these symlinks. For example, /dev/cdrom6 and /dev/dvd6. The number increases by one ever time I reboot the computer, which makes it nearly impossible for me to keep fstab working unless I want to let rebuildfstab do its thing (which I don't for various reasons). So my question is, why are there numbers being appended to the end of my sym links and how do I stop this from happening? Thanks, Jason P.S. My Linux version is 2.6.23-grml |
After doing a bit of searching, I think I may have solved the problem (although this won't fix it if you are using more than one optical drive).
I edited the /lib/udev/write_cd_rules script file, making the following changes: link_num=$(find_next_available 'cdrom[0-9]*') <---original link_num="" <---my version If you look further down in the script, you will see the following: Code:
write_rule "$match" "cdrom$link_num" "$comment" |
Could you post the code of find_next_available?
|
All times are GMT -5. The time now is 06:09 PM. |