How to understand which device is which in the /dev directory
I am new in UNIX/Linux programming. I need a clear reference of each file in /dev directory and which file refers to which devices. I have read many posts but its not only confusing but also sharing very little data. Is there any online documentation or any os internal file that can give clear information about those device files?
For example
/proc/bus/input/devices
this file give some information about all input devices .
1 Answer
The /dev directory in UNIX is generally a folder that contains device files, and is how the O/S contacts the components on the system. Some of these are going to be actual devices, like a hard disk, network card, usb port, keyboard, or mouse. Some are "virtual" devices that are used for special purposes, such as sending output to /dev/null file, or a pseudo random number generator (/dev/random).
If you have the "lshw" package installed, that will list the actual hardware info, along with some device names. There is also lspci, lsmem, lscpu, lsusb, and probably a few others to help identify components on the system.
But to my knowledge, there is no single document or help file that will explain what all the files in /dev directory are used for. In general, I'd suggest if there are any you are curious about, just do a browser search for Ubuntu /dev/{device-filename} and odds are good someone has a description of the file's purpose.
More in general
"Zoraya ter Beek, age 29, just died by assisted suicide in the Netherlands. She was physically healthy, but psychologically depressed. It's an abomination that an entire society would actively facilitate, even encourage, someone ending their own life because they had no hope. Th…"