Tiny Core Base > TCB Q&A Forum
by-id
wysiwyg:
Good afternoon everyone! I was working on an extension for TC that utilizes the /dev/disk/by-id directory, but was troubled to see that TC does not appear to create these files. I quickly looked at another distro and copied the following two lines into a remastered boot image:
ENV{DEVTYPE}=="disk", ENV{ID_SERIAL}=="?*", SYMLINK+="disk/by-id/$env{ID_BUS}-$env{ID_SERIAL}"
ENV{DEVTYPE}=="partition", ENV{ID_SERIAL}=="?*", SYMLINK+="disk/by-id/$env{ID_BUS}-$env{ID_SERIAL}-part%n"
However, I can't seem to get this directory structure to populate. Any thoughts on how I can accomplish this?
Thanks,
Dave
CentralWare:
simple way to get labels:
--- Code: ---blkid | grep -v loop
--- End code ---
This will give you most anything you need pertaining to each device (label, uuid, format, etc.)
the "grep" portion simply disregards any extensions you might have loaded
wysiwyg:
Thanks for the response centralware. I use the by-id filenames to display a list to the user so they can identify which disk/partition they want to interact with. The filenames generated by the udev rule provide an easy way to do this. I don't think the blkid output is going to work as well. Any other thoughts?
Thanks,
Dave
gerald_clark:
Did you install the udev extensions?
wysiwyg:
--- Quote from: gerald_clark on January 24, 2015, 06:04:14 PM ---Did you install the udev extensions?
--- End quote ---
Yes, udev is installed. Everything works as normal, I just can't get the script to populate the /dev/disk/by-id directory.
Dave
Navigation
[0] Message Index
[#] Next page
Go to full version