6

I would like to know if there is some utility that can show how many open files I have on an Ubuntu server?

arikfr
  • 359
  • 2
  • 5
  • 15

1 Answers1

12

As root

lsof | wc -l

This will give you the number of lines returned by lsof. This utility lists all open files, including things like network sockets, so also man lsof for more options on what types of files are displayed.

Cory J
  • 1,528
  • 4
  • 19
  • 28