linux system() function + memory consumption
Hello everybody,
I have a C program which runs forever (forever loop). This program is
supposed to activate different commands and scripts on the basis of system status. In order to activate different commands and scripts I am using standard linux function system(). I have also tried fork() and exec..() family. Once program starts It starts eating up memory and in few hours there is no memory left for any other application. When i try to see meminfo in /proc i see that on every instance of activating the script my free memory is reducing and Inactive Memory Page are increased.
These inactive pages are not being freed either any time in the system uptime.
Any kind of help ... suggestion is appreciated.
Thanks in advance.
-Mihir.
|