查看Linux某个进程打开的文件句柄(file descriptor)数量

先找到进程的pid

然后:

lsof -p [pid] | wc -l

或者

ls /proc/[pid]/fd | wc -l

查看系统总共使用中的文件描述符数量:

lsof | wc -l

references:
http://www.cyberciti.biz/tips/linux-procfs-file-descriptors.html

原文地址:https://www.cnblogs.com/foohack/p/5691377.html