I have the suspicion that my program does not close all files, which it opened, because after 18 days it stops doing it's job without cognizable reason. My program uses a foreign library which might be the causer.
I assume that Linux (in my case Ubuntu Server) can not open an endless amount of file handles at the same time.
Question1: is it possible to query, how many free file handles are currently left in Linux?
Question2: is it possible to query, how many file handles a certain program is currently occupying?
Thanks in advance.