IBM BS029ML Self Help Guide - Page 158

Additional IBM JVM attributes, Servers, Application Servers, WebSphere_Portal, Server Infrastructure

Page 158 highlights

Setting the JVM heap size to or greater than 1 GB on AIX necessitates reducing maxdata (the boundary between the permissible data area and the shared memory region in the AIX memory model). However, this shift effectively steals segments from the data area. One limitation that a smaller data area might impose would be in the ability to create native threads, as each thread has a native stack that is in turn allocated from the native heap. Note that in addition, when using a Java heap greater than 1 GB with the 1.4.x IBM JVM on AIX, the Java heap will be allocated with mmap() and not malloc(). Setting the JVM starting minimum heap size equal to the JVM maximum heap size, without first performing an analysis, gives little overall benefit in terms of long term performance gain. Therefore, we recommend that you refrain from setting the JVM starting minimum heap size equal to the JVM maximum and instead allow the heap to expand until it reaches a steady-state. This will ultimately allow you to determine at what value the heap usage stabilizes. Furthermore, setting the JVM starting minimum heap size equal to the JVM maximum heap size when using a large heap can lead to memory (native heap) fragmentation. Important: The JVM heap is preallocated (in terms of native memory) at the maximum heap size, so setting a large Java heap size effectively reduces the amount of physical memory available to the system. Under no circumstances should the JVM heap page out to disk. Calculate the free memory available after all other applications and the OS requirements have been taken into account. Additional IBM JVM attributes In addition to modifying the JVM heap sizes, the following additional attributes can be evaluated. To view or modify the IBM JVM settings from the WebSphere Application Server Administrative Console, select Servers → Application Servers → WebSphere_Portal → Server Infrastructure → Java and Process Management → Process Definition → Java Virtual Machine. The default and recommended values are shown in Table 5-2. Table 5-2 Additional IBM JVM settings Parameter Prevent GC of class loaded data Default value n/a Recommended value -Xnoclassgc GC Helper Threads n/a -XgcthreadsN The -Xnoclassgc setting prevents garbage collection (GC) from reclaiming class loaded data; only de-referenced user objects are reclaimed, and can offer a significant performance improvement. However, the parameter should be fully evaluated for suitability due to the nature of class loaded data. Be aware that dynamically compiled JSPs constitute class loaded data. With the addition of the -XgcthreadsN parameter, the default number of garbage collection (GC) helper threads that are used during the mark phase, can be explicitly overridden. Platforms with N processors will have N-1 helper threads available by default, which work alongside the master thread to complete the mark phase of GC. N is an integer. If mark stack overflows are observed while performing a verbose garbage collection trace, then additional helper threads may alleviate the problem. Mark Stack Overflows are indicative of deep or wide structures in the Java heap. Processing such structures leads to an overflow of the mark stack, which in turn triggers a sequential heap scan; this is slow and consumes 144 IBM WebSphere Portal V6 Self Help Guide

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108
  • 109
  • 110
  • 111
  • 112
  • 113
  • 114
  • 115
  • 116
  • 117
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • 125
  • 126
  • 127
  • 128
  • 129
  • 130
  • 131
  • 132
  • 133
  • 134
  • 135
  • 136
  • 137
  • 138
  • 139
  • 140
  • 141
  • 142
  • 143
  • 144
  • 145
  • 146
  • 147
  • 148
  • 149
  • 150
  • 151
  • 152
  • 153
  • 154
  • 155
  • 156
  • 157
  • 158
  • 159
  • 160
  • 161
  • 162
  • 163
  • 164
  • 165
  • 166
  • 167
  • 168
  • 169
  • 170
  • 171
  • 172
  • 173
  • 174
  • 175
  • 176
  • 177
  • 178
  • 179
  • 180
  • 181
  • 182
  • 183
  • 184
  • 185
  • 186
  • 187
  • 188
  • 189
  • 190
  • 191
  • 192
  • 193
  • 194
  • 195
  • 196
  • 197
  • 198
  • 199
  • 200
  • 201
  • 202
  • 203
  • 204
  • 205
  • 206
  • 207
  • 208
  • 209
  • 210
  • 211
  • 212
  • 213
  • 214
  • 215
  • 216
  • 217
  • 218
  • 219
  • 220
  • 221
  • 222
  • 223
  • 224
  • 225
  • 226
  • 227
  • 228
  • 229
  • 230
  • 231
  • 232
  • 233
  • 234
  • 235
  • 236
  • 237
  • 238
  • 239
  • 240
  • 241
  • 242

144
IBM WebSphere Portal V6 Self Help Guide
Setting the JVM heap size to or greater than 1 GB on AIX necessitates reducing maxdata (the
boundary between the permissible data area and the shared memory region in the AIX
memory model). However, this shift effectively steals segments from the data area. One
limitation that a smaller data area might impose would be in the ability to create native
threads, as each thread has a native stack that is in turn allocated from the native heap.
Note that in addition, when using a Java heap greater than 1 GB with the 1.4.x IBM JVM on
AIX, the Java heap will be allocated with mmap() and not malloc().
Setting the JVM starting minimum heap size equal to the JVM maximum heap size, without
first performing an analysis, gives little overall benefit in terms of long term performance gain.
Therefore, we recommend that you refrain from setting the JVM starting minimum heap size
equal to the JVM maximum and instead allow the heap to expand until it reaches a
steady-state. This will ultimately allow you to determine at what value the heap usage
stabilizes. Furthermore, setting the JVM starting minimum heap size equal to the JVM
maximum heap size when using a large heap can lead to memory (native heap)
fragmentation.
Additional IBM JVM attributes
In addition to modifying the JVM heap sizes, the following additional attributes can be
evaluated.
To view or modify the IBM JVM settings from the WebSphere Application Server
Administrative Console, select
Servers
Application Servers
WebSphere_Portal
Server Infrastructure
Java and Process Management
Process Definition
Java
Virtual Machine
. The default and recommended values are shown in Table 5-2.
Table 5-2
Additional IBM JVM settings
The -Xnoclassgc setting prevents garbage collection (GC) from reclaiming class loaded data;
only de-referenced user objects are reclaimed, and can offer a significant performance
improvement. However, the parameter should be fully evaluated for suitability due to the
nature of class loaded data. Be aware that dynamically compiled JSPs constitute class
loaded data.
With the addition of the -Xgcthreads
N
parameter, the default number of garbage collection
(GC) helper threads that are used during the mark phase, can be explicitly overridden.
Platforms with
N
processors will have
N
-1 helper threads available by default, which work
alongside the master thread to complete the mark phase of GC.
N
is an integer.
If mark stack overflows are observed while performing a verbose garbage collection trace,
then additional helper threads may alleviate the problem. Mark Stack Overflows are indicative
of deep or wide structures in the Java heap. Processing such structures leads to an overflow
of the mark stack, which in turn triggers a sequential heap scan; this is
slow
and consumes
Important:
The JVM heap is preallocated (in terms of native memory) at the maximum
heap size, so setting a large Java heap size effectively reduces the amount of physical
memory available to the system. Under no circumstances should the JVM heap page out
to disk. Calculate the free memory available after all other applications and the OS
requirements have been taken into account.
Parameter
Default value
Recommended value
Prevent GC of class loaded data
n/a
-Xnoclassgc
GC Helper Threads
n/a
-Xgcthreads
N