Could anyone tell me how can I capture the memory log which can show the
stats at the time the above server run out of memory.

This server currently dedicates to run NPS. Tomcat has been assigned with
512MB (max) and has been manually tuned.

When the server crashed due to insufficient memory, I hardly find a tool or
log file which can tell me what the memory stats were and which NLM or
activities caused it. Though abend.log has logged a NLM causing the abend.
But I believe that in this case it was the result but not the cause.

What memory parameters should I keep watch ? I noticed that NSS.nlm, DS.nlm,
NIFIF.nlm are the most highly memory-used nlms.

I learned that Hamish's tuning only applies to server with more than 2GB
ram. Will his tuning tool help to fix my server?

Wai Chu