This is because increasing the heap beyond the capabilities of your server to adequately Garbage Collect can cause other problems (eg performance/freezing) Increase Xmx in small increments (eg 512mb at a time), until you no longer experience the OutOfMemory error. ![]() ![]() If you do decide to increase the memory settings, there are a few general guidelines to follow: In case you need advice regarding how much memory you should use please check this page for some examples of hardware specifications. WARNING: Used =, Installed =, PCT.Used =, Available.Memory =. Then, on your central server, from which you instead to monitor all your other servers, you can run the following command: $ time. Then restart the snmpd agent, with: /etc/init.d/snmpd restart If you're using automation tools such as chef or puppet or similar tools in your environment, then this isn't a problem at all.Ĭonfiguration of the SNMP agent on the remote node(s):Īfter the snmp agent has been installed, simply vi the /etc/snmpd/nf file and add this line to it: rocommunity (specify-a-community-string-aka-password-here) However, this installation will be a one time deal. You'd have to ensure the snmp agent is installed on each of the remote nodes you wish to monitor memory on. This allows me to monitor all my systems from one central server(s), without having to copy or put a plugin on the remote nodes. I have snmp installed on all the remote nodes I monitor. If you wish to instead utilize an snmp plugin that already does all the necessary calculations for you, here's a link to one that works pretty well: checkMemoryviaSNMP. If you wish to write your own memory script, it'll be wise to ensure you account for buffered and cached memory when calculating used memory, otherwise, you'll end up gathering false data. Or, you can use a prewritten snmp plugin that'll do all the work for you. To graph memory metrics, as already suggested in previous posts, you can write your own script using system tools to gather the necessary memory information. Graphite is relatively easy to install on a ubuntu server and to install it, you can check out this link for the easy to follow installation procedures.Īfter graphite has been installed, now, you can send memory metrics to it, at whichever interval you wish every 5 seconds, every minute, every hour.etc. However, since it appears cacti is no longer popular in the mainstream, there is an alternative graphing application called Graphite. I'm more in line with one of the preceding posts that mentioned Cacti as a great way to monitor memory usage. I haven't had an opportunity yet to see exactly why this is the case. The only part I don't like is the fact that the script claims to require root privileges. I know in the comments above, you mentioned wanting a one-line snapshot from free, but I figured others might find this useful.Ĥ.0 KiB + 42.0 KiB = 46.0 KiB saslauthd (5)Ĥ60.0 KiB + 65.0 KiB = 525.0 KiB rsyslogdĥ68.0 KiB + 60.0 KiB = 628.0 KiB freshclamġ.4 MiB + 308.5 KiB = 1.7 MiB fail2ban-serverġ47.4 MiB + 36.5 MiB = 183.9 MiB apache2 (7) ![]() If you looking for a nice breakdown of the memory used by each running process, then I might recommend checking out ps_mem.py (found here at ).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |