Banner image, with the Linux logo and a folder with “/dev” written on it

The /dev directory in Linux

Find out what devices are connected to your system

Tepes Alexandru
3 min readJan 10, 2023

--

Everything in Linux is a file, and that is true for devices as well.

All devices connected to a Linux system are represented by a device file inside the dev directory. The directory’s name is short for “devices”, and can be found attached to the root filesystem.

There are many types of devices that can connect to a Linux system, but by far the most encountered are:

  • Character Devices
  • Block Devices

This article is intended at giving you a grasp of what these devices are, and how to identify them.

Character Devices

The simplest type of communication between devices in Linux is by sending individual bytes of data to the target device.

Usually, a group of 8 bits, besides being called a byte, is also called a character. By this convention, all devices that support receiving and sending streams of bytes are called character devices.

Examples of character devices are sound cards, mice, and keyboards.

Block Devices

Another way of communicating with a device is by sending and receiving blocks of bytes (or characters) in a…

--

--

Tepes Alexandru

Passionate about Software and Health, sharing what I’ve learned with the world. Thank you for over 35.000+ Views on Medium.