powered by simpleCommunicator - 2.0.59     © 2025 Programmizd 02
Целевая тема:
Создать новую тему:
Автор:
Закрыть
Цитировать
Форумы / IBM DB2, WebSphere, IMS, U2 [игнор отключен] [закрыт для гостей] / как правильно память в JVM настраивать?
2 сообщений из 2, страница 1 из 1
как правильно память в JVM настраивать?
    #36461963
Андрей Панфилов
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Участник
есть Oracle AS (понимаю, что не совсем по теме, но JVM-таки от IBM) на AIX 6.1 с JDK build 1.4.2, J2RE 1.4.2 IBM AIX build ca142-20090307 (SR13)

время от времени (10-20 раз в день) в JVM возникает OOM, в некоторых случаях процесс падает, в некоторых продолжает жить

вывод от -verbose:gc примерно такой
Код: plaintext
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.
<AF[42]: Allocation Failure. need 8388624 bytes, 165 ms since last AF>
<AF[42]: managing allocation failure, action=2 (1102473840/1610611200)>
  <GC(58): GC cycle started Wed Feb 10 08:49:18 2010
  <GC(58): freed 17552920 bytes, 69% free (1120026760/1610611200), in 2700 ms>
  <GC(58): mark: 461 ms, sweep: 14 ms, compact: 2225 ms>
  <GC(58): refs: soft 8 (age >= 32), weak 131, final 17, phantom 0>
  <GC(58): moved 6029630 objects, 344134560 bytes, reason=1, used 264 more bytes>
<AF[42]: managing allocation failure, action=3 (1120026760/1610611200)>
<AF[42]: managing allocation failure, action=4 (1120026760/1610611200)>
<AF[42]: clearing all remaining soft refs>
  <GC(59): GC cycle started Wed Feb 10 08:49:21 2010
  <GC(59): freed 530728 bytes, 69% free (1120557488/1610611200), in 2230 ms>
  <GC(59): mark: 342 ms, sweep: 13 ms, compact: 1875 ms>
  <GC(59): refs: soft 579 (age >= 32), weak 6, final 93, phantom 0>
  <GC(59): moved 2079813 objects, 115998504 bytes, reason=1, used 32 more bytes>
<AF[42]: managing allocation failure, action=6 (1120557488/1610611200)>
JVMDG217: Dump Handler is Processing OutOfMemory - Please Wait.
JVMDG315: JVM Requesting Heap dump file
...............................JVMDG318: Heap dump file written to /u01/oracle/product/ias/10.1.2/j2ee/home/hea
pdump974850.1265780963.phd
JVMDG303: JVM Requesting Java core file
JVMDG304: Java core file written to /u01/oracle/product/ias/10.1.2/j2ee/home/javacore974850.1265780986.txt
JVMDG274: Dump Handler has Processed OutOfMemory.
<AF[42]: Insufficient space in Javaheap to satisfy allocation request>
<AF[42]: completed in 47600 ms>


<AF[43]: Allocation Failure. need 1048592 bytes, 106817 ms since last AF>
<AF[43]: managing allocation failure, action=2 (878148240/1610611200)>
  <GC(62): freeing class sun.reflect.GeneratedMethodAccessor6(b81bffa8)>
  <GC(62): freeing class sun.reflect.GeneratedMethodAccessor48(b8133f98)>
  <GC(62): unloaded and freed 2 classes>
  <GC(62): GC cycle started Wed Feb 10 08:51:53 2010
  <GC(62): freed 217787320 bytes, 68% free (1095935560/1610611200), in 816 ms>
  <GC(62): mark: 753 ms, sweep: 63 ms, compact: 0 ms>
  <GC(62): refs: soft 0 (age >= 32), weak 6880, final 360, phantom 0>
<AF[43]: completed in 817 ms>


<AF[44]: Allocation Failure. need 4194320 bytes, 88 ms since last AF>
<AF[44]: managing allocation failure, action=2 (1089909808/1610611200)>
  <GC(63): GC cycle started Wed Feb 10 08:51:54 2010
  <GC(63): freed 25646320 bytes, 69% free (1115556128/1610611200), in 3648 ms>
  <GC(63): mark: 707 ms, sweep: 31 ms, compact: 2910 ms>
  <GC(63): refs: soft 0 (age >= 32), weak 45, final 1, phantom 0>
  <GC(63): moved 6828966 objects, 388635512 bytes, reason=16, used 18672848 more bytes>
<AF[44]: completed in 3660 ms>


<AF[45]: Allocation Failure. need 16777232 bytes, 412 ms since last AF>
<AF[45]: managing allocation failure, action=2 (1088818456/1610611200)>
  <GC(64): GC cycle started Wed Feb 10 08:51:58 2010
  <GC(64): freed 19870776 bytes, 68% free (1108689232/1610611200), in 2074 ms>
  <GC(64): mark: 441 ms, sweep: 15 ms, compact: 1618 ms>
  <GC(64): refs: soft 0 (age >= 32), weak 87, final 10, phantom 0>
  <GC(64): moved 314797 objects, 18334728 bytes, reason=1, used 52504 more bytes>
<AF[45]: managing allocation failure, action=3 (1108689232/1610611200)>
<AF[45]: managing allocation failure, action=4 (1108689232/1610611200)>
<AF[45]: clearing all remaining soft refs>
  <GC(65): GC cycle started Wed Feb 10 08:52:00 2010
  <GC(65): freed 439288 bytes, 68% free (1109128520/1610611200), in 2068 ms>
  <GC(65): mark: 452 ms, sweep: 16 ms, compact: 1600 ms>
  <GC(65): refs: soft 533 (age >= 32), weak 0, final 37, phantom 0>
  <GC(65): moved 561139 objects, 31769704 bytes, reason=1, used 24664 more bytes>
<AF[45]: managing allocation failure, action=6 (1109128520/1610611200)>
JVMDG217: Dump Handler is Processing OutOfMemory - Please Wait.
JVMDG315: JVM Requesting Heap dump file
...............................JVMDG318: Heap dump file written to /u01/oracle/product/ias/10.1.2/j2ee/home/hea
pdump974850.1265781122.phd
JVMDG303: JVM Requesting Java core file
JVMDG304: Java core file written to /u01/oracle/product/ias/10.1.2/j2ee/home/javacore974850.1265781156.txt
JVMDG274: Dump Handler has Processed OutOfMemory.
<AF[45]: Insufficient space in Javaheap to satisfy allocation request>
<AF[45]: completed in 57756 ms>


т.е. насколько я понимаю памяти свободной в хипе еще навалом, а выделить все равно не может. Как бороться с ситуацией? параметры запуска относящиеся к памяти JVM такие: -Xms1536m -Xmx1536m -Xgcpolicy:subpool -verbose:gc -Xk9000
...
Рейтинг: 0 / 0
как правильно память в JVM настраивать?
    #36464279
Андрей Панфилов
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Участник
при чтении доков сложилось впечатление, что -Xmx должен быть больше -Xms, при уменьшенном -Xms512m все равно сегодня завалилось:

Код: plaintext
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.
<AF[657]: Allocation Failure. need 1145584 bytes, 4127 ms since last AF>
<AF[657]: managing allocation failure, action=2 (519462960/1610611200)>
  <GC(699): GC cycle started Thu Feb 11 15:25:02 2010
  <GC(699): freed 89206512 bytes, 37% free (608669472/1610611200), in 1050 ms>
  <GC(699): mark: 1029 ms, sweep: 21 ms, compact: 0 ms>
  <GC(699): refs: soft 5 (age >= 32), weak 2154, final 174, phantom 1>
<AF[657]: completed in 1051 ms>

<AF[658]: Allocation Failure. need 2291152 bytes, 1 ms since last AF>
<AF[658]: managing allocation failure, action=2 (607228976/1610611200)>
  <GC(700): GC cycle started Thu Feb 11 15:25:03 2010
  <GC(700): freed 5822384 bytes, 38% free (613051360/1610611200), in 5912 ms>
  <GC(700): mark: 884 ms, sweep: 21 ms, compact: 5007 ms>
  <GC(700): refs: soft 8 (age >= 32), weak 0, final 0, phantom 0>
  <GC(700): moved 10882320 objects, 601258752 bytes, reason=1, used 3456 more bytes>
<AF[658]: managing allocation failure, action=3 (613051360/1610611200)>
<AF[658]: managing allocation failure, action=4 (613051360/1610611200)>
<AF[658]: clearing all remaining soft refs>
  <GC(701): GC cycle started Thu Feb 11 15:25:09 2010
  <GC(701): freed 309712 bytes, 38% free (613361072/1610611200), in 6436 ms>
  <GC(701): mark: 1546 ms, sweep: 22 ms, compact: 4868 ms>
  <GC(701): refs: soft 285 (age >= 32), weak 0, final 120, phantom 0>
  <GC(701): moved 5321795 objects, 289535744 bytes, reason=1, used 8 more bytes>
<AF[658]: managing allocation failure, action=6 (613361072/1610611200)>
JVMDG217: Dump Handler is Processing OutOfMemory - Please Wait.
JVMDG315: JVM Requesting Heap dump file
...................................................................JVMDG318: Heap dump file written to /u01/ora
cle/product/ias/10.1.2/j2ee/home/heapdump1089558.1265891115.phd
JVMDG303: JVM Requesting Java core file
JVMDG304: Java core file written to /u01/oracle/product/ias/10.1.2/j2ee/home/javacore1089558.1265891165.txt
JVMDG274: Dump Handler has Processed OutOfMemory.
<AF[658]: Insufficient space in Javaheap to satisfy allocation request>
<AF[658]: completed in 104742 ms>
...
Рейтинг: 0 / 0
2 сообщений из 2, страница 1 из 1
Форумы / IBM DB2, WebSphere, IMS, U2 [игнор отключен] [закрыт для гостей] / как правильно память в JVM настраивать?
Найденые пользователи ...
Разблокировать пользователей ...
Читали форум (0):
Пользователи онлайн (0):
x
x
Закрыть


Просмотр
0 / 0
Close
Debug Console [Select Text]