WebSphere Application Server & Liberty

WebSphere Application Server & Liberty

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  WebSphere Application Server & HugePages on Linux

    Posted Thu August 03, 2017 09:20 AM

    We recently started having issues with a few virtual machines (RHEL) swapping to disk where HugePages is enabled at the OS level and at the WebSphere Application Server (WAS) JVM level (-Xlp).

    We have some questions for which the answers don't seem very clear in the different forums on the internet.

    The Linux administrators are saying that our WAS processes are starting outside of the HugePages allocated memory, even if we have the -Xlp flag set on the generic JVM arguments. Is there such thing as a process "starting outside of HugePages" when -Xlp is set? I don't believe it's possible - I think the process will just not start at all if the memory in HugePages cannot be allocated on startup.

    The HugePages_Free parameter on the OS is saying that we have like 16GB free (out of 55GB) when the OS is swapping to disk. That seems to indicate that the WAS process may have part of it running in different memory locations (i.e. 90% running in HugePages & 10% running outside). Is that possible? Should all of the process memory run in HugePages? For example, would the native libraries for the process run outside, but the heap be inside HugePages? When we look at historical statistics for the virtual machine, we see that the OS started swapping to disk once a performance test was running on one of the application servers. That seems to indicate that my WAS java process's memory are split between HugePages and non-HugePages memory.

    My config:

    /proc/meminfo

    MemTotal: 67974816 kB <-- 64.8 GB
    MemFree: 420972 kB <-- 411 MB
    HugePages_Total: 28160 <-- 57671680 kB (55 GB)
    HugePages_Free: 8225 <-- 16844800 kB (16 GB)
    HugePages_Rsvd: 658 <-- 1347584 kB (1.3 GB)
    Hugepagesize: 2048 kB

    /etc/security/limits.conf

    # Huges pages
    wasadmin soft memlock 57671680
    wasadmin hard memlock 57671680

    listing of WAS process's heap sizes (Total = 56320 MB)

    -Xlp -Xms4096m -Xmx4096m nodeagent
    -Xlp -Xms7168m -Xmx7168m AppSvr01
    -Xlp -Xms14336m -Xmx14336m AppSvr02
    -Xlp -Xms14336m -Xmx14336m AppSvr03
    -Xlp -Xms16384m -Xmx16384m AppSvr04

    Also, someone mentioned that the issue could be related to the startup scripts that we use which point to WAS' "startServer.sh" that do not have the -Xlp flag... is it possible that it causes some WAS processes to not load inside HugePages because their memory usage is not accounted for in the HugePages_Total assigned?

    What are your thoughts on this issue?

    Thank you.



  • 2.  RE: WebSphere Application Server & HugePages on Linux

    Posted Tue August 08, 2017 03:06 PM

    I think you are trying to solve the problem of high paging.  If that is the problem you are attempting to diagnose, then you need to look at things that cause the JVMs to force the Operating System to go to page space. 

    The things to investigate are:

    1. Does the Physical Memory to SWAP space allocation ratio meet the minimum baseline requirement for this version of the Operating System as specified by the vendor?

    2. Have the process owner id ulimits been set according to the product specifications for this Operating System?

    3. Have the minimum and maximum thread pools and memory allocations for heap been set to the same values?

    4. Have the total maximum heap sizes of the JVM + memory required for the JVM accounted for in the total physical memory on the server?  Generally an additional 30% above the heap.  But can be much more as the heap is larger.

    5. For the disk allocated for SWAP is there anything consuming that space?

    These are the most common causes of an Operating System pushing a JVM process memory to SWAP.