Sep 6, 2013, 12:33 AM
Post #1 of 4
Hi 2 all,
I'm a very beginner in programming perl. I've installed nagios on my Server and now I want to create a selfmade plugin in perl.
My intention is to get the free RAM space of my linux server. I know that such a plugin is programmed before, but I want this for learning.
I know, I'll get the free space with "free -m". So i can put this into a variable with
But now I have to "filter" the output, so that in $free_ram is only the available RAM, which can be used.
So my question: How can I filter the output of "free -m"?