Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Is there any way to get a list of all the hardware devices (USB, etc.) attached to the system and which device name (wrong word, but i can't think of the correct term right now) that they reside on? For example, /dev/sda or /dev/sdc3 etc. I need to know because for some reason, my floppy drive keeps changing names (at one point it was sda, then sdc, and now I have no idea) every time I boot into Linux.
Devices that start with 's' are scsi devices, your floppy should be /dev/fd*. For various device lists you can do "cat /proc/*"
"cat /proc/pci" for pci
"cat /proc/scsi" for scsi and so on.
Distribution: Slackware, (Non-Linux: Solaris 7,8,9; OSX; BeOS)
Posts: 1,152
Rep:
Another option is to recompile your kernel to support devfs, which is a
dynamic device filesystem, rather than the node locked /dev that has been
so popular for so long. If you go this route, READ, READ, READ. You
can cause some major problems if you screw up, but once you've got it,
it's great.
For example:
Code:
bash-2.05a$ ls /dev/ide/
cd hd host0
bash-2.05a$ ls /dev/ide/host0/
bus0 bus1
bash-2.05a$ ls /dev/ide/host0/bus1/
target0 target1
bash-2.05a$ ls /dev/ide/host0/bus1/target0/
lun0
bash-2.05a$ ls /dev/ide/host0/bus1/target0/lun0/
disc part1 part10 part2 part5 part6 part7 part8 part9
bash-2.05a$
This shows my partitions on my first hard drive on my second
IDE bus of the first IDE host controller. . .
I really don't think I am ready to recompile my kernel. The standard Mandrake kernel was too old for my computer, so my friend (over the phone) had me download and install a new one. This wasn't recompiling, but I still had no idea what he was having me do.
So basically, I have to use the method that Aussie suggested and then just guess through all of them until the floppy drive mounts? I'd think that a sophisticated OS like Linux would be able to automatically detect media devices instead of making the user guess and check. Strange.
Thanks for both of your help though. Maybe someone else has a suggestion/program that makes this a little more bareable?
Distribution: Slackware, (Non-Linux: Solaris 7,8,9; OSX; BeOS)
Posts: 1,152
Rep:
Linux does automatically detect devices (for the most part), it just isn't
always clear what the user wants those devices to be. Is your floppy
drive anything other than the (outdated) standard 1.44 MB floppy that
has its own controller on the MB?
You can also find the floppy drive name in the boot messages:
dmesg | less
look for something like:
Code:
ide0: BM-DMA at 0xc400-0xc407, BIOS settings: hda:DMA, hdb:DMA
ide1: BM-DMA at 0xc408-0xc40f, BIOS settings: hdc:DMA, hdd:DMA
hda: IBM-DTLA-305030, ATA DISK drive
hdb: MATSHITADVD-ROM SR-8587, ATAPI CD/DVD-ROM drive
hdc: IBM-DTTA-350840, ATA DISK drive
hdd: CD-ROM Drive/F5A, ATAPI CD/DVD-ROM drive
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
ide1 at 0x170-0x177,0x376 on irq 15
hda: 60036480 sectors (30739 MB) w/380KiB Cache, CHS=3737/255/63
hdc: 16514064 sectors (8455 MB) w/467KiB Cache, CHS=16383/16/63, UDMA(33)
hdb: ATAPI 48X DVD-ROM drive, 256kB Cache, UDMA(33)
Uniform CD-ROM driver Revision: 3.12
Partition check:
/dev/ide/host0/bus0/target0/lun0: p1 p2 p3 < p5 p6 p7 p8 >
/dev/ide/host0/bus1/target0/lun0: [PTBL] [1027/255/63] p1 p2 < p5 p6 p7 p8 p9 p10 >
Floppy drive(s): fd0 is 1.44M
This tells me that my floppy drive is /dev/fd0, I have the following hard
drive partitions:
/dev/hda1, /dev/hda2, /dev/hda3, /dev/hda5, hda6, hda7, hda8
/dev/hdc1, /dev/hdc2, hdc5, hdc6, hdc7, hdc8, hdc9, hdc10
That /dev/hdb is a DVD drive, that /dev/hdd is a CD drive.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.