---
title: Modifying the Java heap size
description: Modify the Java heap size for both Windows and Linux installations, including the Windows and Linux services.
component: pingaccess
version: 9.0
page_id: pingaccess:reference_guides:pa_modifying_the_java_heap_size
canonical_url: https://docs.pingidentity.com/pingaccess/9.0/reference_guides/pa_modifying_the_java_heap_size.html
revdate: January 12, 2024
section_ids:
  steps: Steps
  choose-from: Choose from:
  choose-from-2: Choose from:
---

# Modifying the Java heap size

Modify the Java heap size for both Windows and Linux installations, including the Windows and Linux services.

## Steps

1. Edit the `jvm-memory.options` file located in the `<PA_HOME>/conf` directory.

2. Specify overall heap size by modifying the `#Minimum heap size` and `#Maximum heap size` parameters.

   ### Choose from:

   * Modify `-Xms512m` to change the `#Minimum heap size` value.

   * Modify `-Xmx512m` to change the `#Maximum heap size` value.

   Specify units as `m`, megabytes, or `g`, gigabytes.

3. Specify young generation size by modifying the `#Minimum size for the Young Gen space` and `#Maximum size for the Young Gen space` variables.

   ### Choose from:

   * Modify `-XX:NewSize=256m` to change the `#Minimum size for the Young Gen space` value.

   * Modify `-XX:MaxNewSize=256m` to change the `#Maximum size for the Young Gen space` value.

   Set values to 50% of `#Minimum heap size` and `#Maximum heap size`.

   |   |                                                                                                                                                 |
   | - | ----------------------------------------------------------------------------------------------------------------------------------------------- |
   |   | Not advisable if selecting the G1 collector. For more information, see [Garbage Collector Configuration](pa_garbage_collector_config_ref.html). |

4. If you are running PingAccess as a Windows service, run the `generate-wrapper-jvm-options.bat` file located in the `<PA_HOME>/sbin/windows` directory.

   This file applies the changes from the `jvm-memory.options` file to the `wrapper-jvm-options.conf` file, which is used by the Windows service.
