1. - : regular file
  2. d : directory
  3. c : character device file
  4. b : block device file
  5. s : local socket file
  6. p : named pipe
  7. l : symbolic link

Character device

Character and block device files allow users and programs to communicate with hardware peripheral devices.

For example:

$ ls -ld /dev/vmmon 
crw------- 1 root root 10, 165 Jan 4 10:13 /dev/vmmon

In this case the character device is the vmware module device.

Block Device

Block devices are similar to character devices. They mostly govern hardware as hard drives, memory, etc.

$ ls -ld /dev/sda
brw-rw---- 1 root disk 8, 0 Jan 4 10:12 /dev/sda

 

ref. https://linuxconfig.org/identifying-file-types-in-linux

 

Identifying File types in Linux - LinuxConfig.org

Details Lubos Rendek System Administration 09 June 2016 Introduction When navigating the Linux file system you are sure to encounter different file types. The most used and obvious file types are regular files and directories. However, the Linux operating

linuxconfig.org

 

character device file 의 사용

https://temp123.tistory.com/16

'20. Programming > Tools - 4Linux' 카테고리의 다른 글

[Linux] 이전 dir로 이동하기 (Going to previous dir)  (0) 2018.04.06
[Linux] Permission 표현  (0) 2018.03.15
[Linux] SSH - Screen  (0) 2018.01.03

+ Recent posts