(Not a duplicate of Understanding /dev and its subdirs and files)
I was browsing around my filesystem and for the first time I took a second to analyze my /dev
directory. I was surprised by the amount of devices files in it, and couldn't make sense of all of them:
max@linux-vwzy:/dev> ls
adsp disk fd0u1760 initctl mem root sg0 tty tty21 tty35 tty49 tty62 vboxdrv vcsa2
audio dri fd0u1840 input mixer rtc sg1 tty0 tty22 tty36 tty5 tty63 vboxnetctl vcsa3
autofs dsp fd0u1920 kmem mixer1 rtc0 sg2 tty1 tty23 tty37 tty50 tty7 vboxusb vcsa4
block dvd fd0u360 kmsg net scd0 sg3 tty10 tty24 tty38 tty51 tty8 vcs vcsa5
bootsplash dvdrw fd0u720 log network_latency sda sg4 tty11 tty25 tty39 tty52 tty9 vcs1 vcsa6
bsg fb0 fd0u800 loop0 network_throughput sda1 sg5 tty12 tty26 tty4 tty53 ttyS0 vcs10 vcsa7
btrfs-control fd fd0u820 loop1 null sda2 sg6 tty13 tty27 tty40 tty54 ttyS1 vcs2 vga_arbiter
bus fd0 fd0u830 loop2 nvram sda3 sg7 tty14 tty28 tty41 tty55 ttyS2 vcs3 xconsole
cdrom fd0u1040 full loop3 oldmem sdb shm tty15 tty29 tty42 tty56 ttyS3 vcs4 zero
cdrw fd0u1120 fuse loop4 port sdc snapshot tty16 tty3 tty43 tty57 ttyS4 vcs5
char fd0u1440 fw0 loop5 ppp sdc1 snd tty17 tty30 tty44 tty58 ttyS5 vcs6
console fd0u1600 hidraw0 loop6 psaux sdd sr0 tty18 tty31 tty45 tty59 ttyS6 vcs7
core fd0u1680 hidraw1 loop7 ptmx sde stderr tty19 tty32 tty46 tty6 ttyS7 vcsa
cpu fd0u1722 hidraw2 mapper pts sdf stdin tty2 tty33 tty47 tty60 uinput vcsa1
cpu_dma_latency fd0u1743 hpet mcelog random sdg stdout tty20 tty34 tty48 tty61 urandom vcsa10
I know that the sd*
's are my disks and filesystems, but what are loopx
, fd0uxxxx
, sgx
, vcsxxx
and all the other single files. Most of them are device files according to ls
.
I understand that fully answering this question would require a ton of information, so unless someone can provide a link with a great rundown of the different devices files in dev
and what they are all used for, I propose we make a CW answer.
/dev
I should know about? (Maybe you'll have answers for all of them anyway, maybe not…) – Stéphane Gimenez Aug 29 '11 at 21:27