码迷,mamicode.com
首页 > 系统相关 > 详细

lsof linux

时间:2020-06-02 22:52:28      阅读:100      评论:0      收藏:0      [点我收藏+]

标签:访问   one   linu   let   number   ace   块设备   rate   cte   

lsof  list open files

Linux一切皆文件,通过文件不仅可以访问常规数据,还可以访问网络连接(套接字)和硬件,该文件描述符为应用程序与os之间提供了接口.lsof需访问各种特权文件,故需root运行

技术图片

 

 

 COMMAND contains  the  first nine characters of the name of the UNIX command associated with the process. 默认只显示前9个字符

 PID is the Process IDentification number of the process.

 TID  is the task (thread) IDentification number, if task (thread) reporting is supported by the dialect and a task (thread) is being listed.

 FD is the File Descriptor number of the file or:

  1. cwd  current working directory
  2. mem memory mapped file
  3. rtd root directory
  4. txt program text (code and data)

 FD is followed by one of these characters, describing the mode under which the file is open:

  1. r for read access
  2. w for write access
  3. u for read and write access
  4. space if mode unknow and no lock

 TYPE is the type of the node associated with the file

  1. IPv4 IPv4 socket
  2. IPv6 an open IPv6 network file - even if its address is IPv4, mapped in an IPv6 address
  3. unix UNIX domain socket
  4. DIR directory
  5. FIFO FIFO special file
  6. DEL a linux map file that has been deleted
  7. CHR a charater special file 字符设备文件
  8. BLK a block special file 块设备文件
  9. SOCK  a socket of unknown domain
  10. REG regular file
  11.   

 

  

lsof linux

标签:访问   one   linu   let   number   ace   块设备   rate   cte   

原文地址:https://www.cnblogs.com/dissipate/p/13034336.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!