티스토리 뷰
pmap 커맨드를 사용하면 linux process 의 가상 메모리 주소의 대역과 Mapping 된 결과를 확인할 수 있다.
10: java -Xms30m -Xmx30m -verbose:gc -XX:+UseG1GC Main
Address Kbytes RSS Dirty Mode Mapping
00000000fe200000 31232 30364 30364 rw--- [ anon ]
00000000fe200000 0 0 0 rw--- [ anon ]
0000000100080000 1048064 0 0 ----- [ anon ]
0000000100080000 0 0 0 ----- [ anon ]
0000562ecc068000 4 4 0 r-x-- java
0000562ecc068000 0 0 0 r-x-- java
0000562ecc268000 4 4 4 r---- java
0000562ecc268000 0 0 0 r---- java
0000562ecc269000 4 4 4 rw--- java
0000562ecc269000 0 0 0 rw--- java
0000562ecd99a000 132 28 28 rw--- [ anon ]
0000562ecd99a000 0 0 0 rw--- [ anon ]
00007feb34000000 8204 8204 8204 rw--- [ anon ]
00007feb34000000 0 0 0 rw--- [ anon ]
00007feb34803000 57332 0 0 ----- [ anon ]
00007feb34803000 0 0 0 ----- [ anon ]
00007feb38000000 132 4 4 rw--- [ anon ]
전체보기 :
10: java -Xms30m -Xmx30m -verbose:gc -XX:+UseG1GC Main
Address Kbytes RSS Dirty Mode Mapping
00000000fe200000 31232 30364 30364 rw--- [ anon ]
00000000fe200000 0 0 0 rw--- [ anon ]
0000000100080000 1048064 0 0 ----- [ anon ]
0000000100080000 0 0 0 ----- [ anon ]
0000562ecc068000 4 4 0 r-x-- java
0000562ecc068000 0 0 0 r-x-- java
0000562ecc268000 4 4 4 r---- java
0000562ecc268000 0 0 0 r---- java
0000562ecc269000 4 4 4 rw--- java
0000562ecc269000 0 0 0 rw--- java
0000562ecd99a000 132 28 28 rw--- [ anon ]
0000562ecd99a000 0 0 0 rw--- [ anon ]
00007feb34000000 8204 8204 8204 rw--- [ anon ]
00007feb34000000 0 0 0 rw--- [ anon ]
00007feb34803000 57332 0 0 ----- [ anon ]
00007feb34803000 0 0 0 ----- [ anon ]
00007feb38000000 132 4 4 rw--- [ anon ]
00007feb38000000 0 0 0 rw--- [ anon ]
00007feb38021000 65404 0 0 ----- [ anon ]
00007feb38021000 0 0 0 ----- [ anon ]
00007feb3fce6000 12 0 0 ----- [ anon ]
00007feb3fce6000 0 0 0 ----- [ anon ]
00007feb3fce9000 1016 12 12 rw--- [ anon ]
00007feb3fce9000 0 0 0 rw--- [ anon ]
00007feb3fde7000 96 64 0 r-x-- libnet.so
00007feb3fde7000 0 0 0 r-x-- libnet.so
00007feb3fdff000 2044 0 0 ----- libnet.so
00007feb3fdff000 0 0 0 ----- libnet.so
00007feb3fffe000 4 4 4 r---- libnet.so
00007feb3fffe000 0 0 0 r---- libnet.so
00007feb3ffff000 4 4 4 rw--- libnet.so
00007feb3ffff000 0 0 0 rw--- libnet.so
00007feb40000000 628 624 624 rw--- [ anon ]
00007feb40000000 0 0 0 rw--- [ anon ]
00007feb4009d000 64908 0 0 ----- [ anon ]
00007feb4009d000 0 0 0 ----- [ anon ]
00007feb44000000 132 4 4 rw--- [ anon ]
00007feb44000000 0 0 0 rw--- [ anon ]
00007feb44021000 65404 0 0 ----- [ anon ]
00007feb44021000 0 0 0 ----- [ anon ]
00007feb48000000 132 4 4 rw--- [ anon ]
00007feb48000000 0 0 0 rw--- [ anon ]
00007feb48021000 65404 0 0 ----- [ anon ]
00007feb48021000 0 0 0 ----- [ anon ]
00007feb4c000000 132 4 4 rw--- [ anon ]
00007feb4c000000 0 0 0 rw--- [ anon ]
00007feb4c021000 65404 0 0 ----- [ anon ]
00007feb4c021000 0 0 0 ----- [ anon ]
00007feb50000000 132 12 12 rw--- [ anon ]
00007feb50000000 0 0 0 rw--- [ anon ]
00007feb50021000 65404 0 0 ----- [ anon ]
00007feb50021000 0 0 0 ----- [ anon ]
00007feb54000000 444 420 420 rw--- [ anon ]
00007feb54000000 0 0 0 rw--- [ anon ]
00007feb5406f000 65092 0 0 ----- [ anon ]
00007feb5406f000 0 0 0 ----- [ anon ]
00007feb58000000 132 8 8 rw--- [ anon ]
00007feb58000000 0 0 0 rw--- [ anon ]
00007feb58021000 65404 0 0 ----- [ anon ]
00007feb58021000 0 0 0 ----- [ anon ]
00007feb5c000000 132 4 4 rw--- [ anon ]
00007feb5c000000 0 0 0 rw--- [ anon ]
00007feb5c021000 65404 0 0 ----- [ anon ]
00007feb5c021000 0 0 0 ----- [ anon ]
00007feb60000000 132 100 100 rw--- [ anon ]
00007feb60000000 0 0 0 rw--- [ anon ]
00007feb60021000 65404 0 0 ----- [ anon ]
00007feb60021000 0 0 0 ----- [ anon ]
00007feb64000000 132 32 32 rw--- [ anon ]
00007feb64000000 0 0 0 rw--- [ anon ]
00007feb64021000 65404 0 0 ----- [ anon ]
00007feb64021000 0 0 0 ----- [ anon ]
00007feb68000000 132 4 4 rw--- [ anon ]
00007feb68000000 0 0 0 rw--- [ anon ]
00007feb68021000 65404 0 0 ----- [ anon ]
00007feb68021000 0 0 0 ----- [ anon ]
00007feb6c06d000 196 196 196 rw--- [ anon ]
00007feb6c06d000 0 0 0 rw--- [ anon ]
00007feb6c09e000 72 64 0 r-x-- libnio.so
00007feb6c09e000 0 0 0 r-x-- libnio.so
00007feb6c0b0000 2044 0 0 ----- libnio.so
00007feb6c0b0000 0 0 0 ----- libnio.so
00007feb6c2af000 4 4 4 r---- libnio.so
00007feb6c2af000 0 0 0 r---- libnio.so
00007feb6c2b0000 4 4 4 rw--- libnio.so
00007feb6c2b0000 0 0 0 rw--- libnio.so
00007feb6c2b1000 108 108 0 r--s- cldrdata.jar
00007feb6c2b1000 0 0 0 r--s- cldrdata.jar
00007feb6c2cc000 108 108 0 r--s- nashorn.jar
00007feb6c2cc000 0 0 0 r--s- nashorn.jar
00007feb6c2e7000 4 0 0 ----- [ anon ]
00007feb6c2e7000 0 0 0 ----- [ anon ]
00007feb6c2e8000 1024 8 8 rw--- [ anon ]
00007feb6c2e8000 0 0 0 rw--- [ anon ]
00007feb6c3e8000 12 0 0 ----- [ anon ]
00007feb6c3e8000 0 0 0 ----- [ anon ]
00007feb6c3eb000 1016 8 8 rw--- [ anon ]
00007feb6c3eb000 0 0 0 rw--- [ anon ]
00007feb6c4e9000 4 0 0 ----- [ anon ]
00007feb6c4e9000 0 0 0 ----- [ anon ]
00007feb6c4ea000 12 0 0 ----- [ anon ]
00007feb6c4ea000 0 0 0 ----- [ anon ]
00007feb6c4ed000 1012 12 12 rw--- [ anon ]
00007feb6c4ed000 0 0 0 rw--- [ anon ]
00007feb6c5ea000 4 0 0 ----- [ anon ]
00007feb6c5ea000 0 0 0 ----- [ anon ]
00007feb6c5eb000 12 0 0 ----- [ anon ]
00007feb6c5eb000 0 0 0 ----- [ anon ]
00007feb6c5ee000 1012 8 8 rw--- [ anon ]
00007feb6c5ee000 0 0 0 rw--- [ anon ]
00007feb6c6eb000 4 0 0 ----- [ anon ]
00007feb6c6eb000 0 0 0 ----- [ anon ]
00007feb6c6ec000 12 0 0 ----- [ anon ]
00007feb6c6ec000 0 0 0 ----- [ anon ]
00007feb6c6ef000 1012 24 24 rw--- [ anon ]
00007feb6c6ef000 0 0 0 rw--- [ anon ]
00007feb6c7ec000 4 0 0 ----- [ anon ]
00007feb6c7ec000 0 0 0 ----- [ anon ]
00007feb6c7ed000 12 0 0 ----- [ anon ]
00007feb6c7ed000 0 0 0 ----- [ anon ]
00007feb6c7f0000 1012 24 24 rw--- [ anon ]
00007feb6c7f0000 0 0 0 rw--- [ anon ]
00007feb6c8ed000 12 0 0 ----- [ anon ]
00007feb6c8ed000 0 0 0 ----- [ anon ]
00007feb6c8f0000 1016 92 92 rw--- [ anon ]
00007feb6c8f0000 0 0 0 rw--- [ anon ]
00007feb6c9ee000 12 0 0 ----- [ anon ]
00007feb6c9ee000 0 0 0 ----- [ anon ]
00007feb6c9f1000 1016 8 8 rw--- [ anon ]
00007feb6c9f1000 0 0 0 rw--- [ anon ]
00007feb6caef000 1484 132 0 r---- LC_COLLATE
00007feb6caef000 0 0 0 r---- LC_COLLATE
00007feb6cc62000 12 0 0 ----- [ anon ]
00007feb6cc62000 0 0 0 ----- [ anon ]
00007feb6cc65000 1016 88 88 rw--- [ anon ]
00007feb6cc65000 0 0 0 rw--- [ anon ]
00007feb6cd63000 12 0 0 ----- [ anon ]
00007feb6cd63000 0 0 0 ----- [ anon ]
00007feb6cd66000 1016 88 88 rw--- [ anon ]
00007feb6cd66000 0 0 0 rw--- [ anon ]
00007feb6ce64000 4 0 0 ----- [ anon ]
00007feb6ce64000 0 0 0 ----- [ anon ]
00007feb6ce65000 1336 324 324 rw--- [ anon ]
00007feb6ce65000 0 0 0 rw--- [ anon ]
00007feb6cfb3000 1860 1860 0 r--s- rt.jar
00007feb6cfb3000 0 0 0 r--s- rt.jar
00007feb6d184000 4824 2972 2972 rw--- [ anon ]
00007feb6d184000 0 0 0 rw--- [ anon ]
00007feb6d63a000 3840 0 0 ----- [ anon ]
00007feb6d63a000 0 0 0 ----- [ anon ]
00007feb6d9fa000 38936 24 24 rw--- [ anon ]
00007feb6d9fa000 0 0 0 rw--- [ anon ]
00007feb70000000 132 4 4 rw--- [ anon ]
00007feb70000000 0 0 0 rw--- [ anon ]
00007feb70021000 65404 0 0 ----- [ anon ]
00007feb70021000 0 0 0 ----- [ anon ]
00007feb74000000 132 4 4 rw--- [ anon ]
00007feb74000000 0 0 0 rw--- [ anon ]
00007feb74021000 65404 0 0 ----- [ anon ]
00007feb74021000 0 0 0 ----- [ anon ]
00007feb78000000 132 4 4 rw--- [ anon ]
00007feb78000000 0 0 0 rw--- [ anon ]
00007feb78021000 65404 0 0 ----- [ anon ]
00007feb78021000 0 0 0 ----- [ anon ]
00007feb7c000000 132 4 4 rw--- [ anon ]
00007feb7c000000 0 0 0 rw--- [ anon ]
00007feb7c021000 65404 0 0 ----- [ anon ]
00007feb7c021000 0 0 0 ----- [ anon ]
00007feb80000000 132 4 4 rw--- [ anon ]
00007feb80000000 0 0 0 rw--- [ anon ]
00007feb80021000 65404 0 0 ----- [ anon ]
00007feb80021000 0 0 0 ----- [ anon ]
00007feb84000000 132 4 4 rw--- [ anon ]
00007feb84000000 0 0 0 rw--- [ anon ]
00007feb84021000 65404 0 0 ----- [ anon ]
00007feb84021000 0 0 0 ----- [ anon ]
00007feb88000000 132 4 4 rw--- [ anon ]
00007feb88000000 0 0 0 rw--- [ anon ]
00007feb88021000 65404 0 0 ----- [ anon ]
00007feb88021000 0 0 0 ----- [ anon ]
00007feb8c000000 132 4 4 rw--- [ anon ]
00007feb8c000000 0 0 0 rw--- [ anon ]
00007feb8c021000 65404 0 0 ----- [ anon ]
00007feb8c021000 0 0 0 ----- [ anon ]
00007feb90000000 132 4 4 rw--- [ anon ]
00007feb90000000 0 0 0 rw--- [ anon ]
00007feb90021000 65404 0 0 ----- [ anon ]
00007feb90021000 0 0 0 ----- [ anon ]
00007feb94000000 132 4 4 rw--- [ anon ]
00007feb94000000 0 0 0 rw--- [ anon ]
00007feb94021000 65404 0 0 ----- [ anon ]
00007feb94021000 0 0 0 ----- [ anon ]
00007feb98000000 132 12 12 rw--- [ anon ]
00007feb98000000 0 0 0 rw--- [ anon ]
00007feb98021000 65404 0 0 ----- [ anon ]
00007feb98021000 0 0 0 ----- [ anon ]
00007feb9c000000 132 4 4 rw--- [ anon ]
00007feb9c000000 0 0 0 rw--- [ anon ]
00007feb9c021000 65404 0 0 ----- [ anon ]
00007feb9c021000 0 0 0 ----- [ anon ]
00007feba0000000 132 12 12 rw--- [ anon ]
00007feba0000000 0 0 0 rw--- [ anon ]
00007feba0021000 65404 0 0 ----- [ anon ]
00007feba0021000 0 0 0 ----- [ anon ]
00007feba4000000 132 16 16 rw--- [ anon ]
00007feba4000000 0 0 0 rw--- [ anon ]
00007feba4021000 65404 0 0 ----- [ anon ]
00007feba4021000 0 0 0 ----- [ anon ]
00007feba8000000 132 12 12 rw--- [ anon ]
00007feba8000000 0 0 0 rw--- [ anon ]
00007feba8021000 65404 0 0 ----- [ anon ]
00007feba8021000 0 0 0 ----- [ anon ]
00007febac000000 132 12 12 rw--- [ anon ]
00007febac000000 0 0 0 rw--- [ anon ]
00007febac021000 65404 0 0 ----- [ anon ]
00007febac021000 0 0 0 ----- [ anon ]
00007febb0000000 132 28 28 rw--- [ anon ]
00007febb0000000 0 0 0 rw--- [ anon ]
00007febb0021000 65404 0 0 ----- [ anon ]
00007febb0021000 0 0 0 ----- [ anon ]
00007febb4000000 132 12 12 rw--- [ anon ]
00007febb4000000 0 0 0 rw--- [ anon ]
00007febb4021000 65404 0 0 ----- [ anon ]
00007febb4021000 0 0 0 ----- [ anon ]
00007febb8000000 132 52 52 rw--- [ anon ]
00007febb8000000 0 0 0 rw--- [ anon ]
00007febb8021000 65404 0 0 ----- [ anon ]
00007febb8021000 0 0 0 ----- [ anon ]
00007febbc007000 8 8 0 r--s- java-atk-wrapper.jar
00007febbc007000 0 0 0 r--s- java-atk-wrapper.jar
00007febbc009000 16 16 0 r--s- sunpkcs11.jar
00007febbc009000 0 0 0 r--s- sunpkcs11.jar
00007febbc00d000 24 24 0 r--s- sunjce_provider.jar
00007febbc00d000 0 0 0 r--s- sunjce_provider.jar
00007febbc013000 44 44 0 r--s- localedata.jar
00007febbc013000 0 0 0 r--s- localedata.jar
00007febbc01e000 2420 372 372 rw--- [ anon ]
00007febbc01e000 0 0 0 rw--- [ anon ]
00007febbc27b000 4 0 0 ----- [ anon ]
00007febbc27b000 0 0 0 ----- [ anon ]
00007febbc27c000 1024 8 8 rw--- [ anon ]
00007febbc27c000 0 0 0 rw--- [ anon ]
00007febbc37c000 4 0 0 ----- [ anon ]
00007febbc37c000 0 0 0 ----- [ anon ]
00007febbc37d000 1024 8 8 rw--- [ anon ]
00007febbc37d000 0 0 0 rw--- [ anon ]
00007febbc47d000 4 0 0 ----- [ anon ]
00007febbc47d000 0 0 0 ----- [ anon ]
00007febbc47e000 1504 492 492 rw--- [ anon ]
00007febbc47e000 0 0 0 rw--- [ anon ]
00007febbc5f6000 4 0 0 ----- [ anon ]
00007febbc5f6000 0 0 0 ----- [ anon ]
00007febbc5f7000 1024 8 8 rw--- [ anon ]
00007febbc5f7000 0 0 0 rw--- [ anon ]
00007febbc6f7000 4 0 0 ----- [ anon ]
00007febbc6f7000 0 0 0 ----- [ anon ]
00007febbc6f8000 1024 8 8 rw--- [ anon ]
00007febbc6f8000 0 0 0 rw--- [ anon ]
00007febbc7f8000 4 0 0 ----- [ anon ]
00007febbc7f8000 0 0 0 ----- [ anon ]
00007febbc7f9000 1024 8 8 rw--- [ anon ]
00007febbc7f9000 0 0 0 rw--- [ anon ]
00007febbc8f9000 4 0 0 ----- [ anon ]
00007febbc8f9000 0 0 0 ----- [ anon ]
00007febbc8fa000 1024 8 8 rw--- [ anon ]
00007febbc8fa000 0 0 0 rw--- [ anon ]
00007febbc9fa000 4 0 0 ----- [ anon ]
00007febbc9fa000 0 0 0 ----- [ anon ]
00007febbc9fb000 1024 8 8 rw--- [ anon ]
00007febbc9fb000 0 0 0 rw--- [ anon ]
00007febbcafb000 4 0 0 ----- [ anon ]
00007febbcafb000 0 0 0 ----- [ anon ]
00007febbcafc000 1024 8 8 rw--- [ anon ]
00007febbcafc000 0 0 0 rw--- [ anon ]
00007febbcbfc000 4 0 0 ----- [ anon ]
00007febbcbfc000 0 0 0 ----- [ anon ]
00007febbcbfd000 1024 8 8 rw--- [ anon ]
00007febbcbfd000 0 0 0 rw--- [ anon ]
00007febbccfd000 4 0 0 ----- [ anon ]
00007febbccfd000 0 0 0 ----- [ anon ]
00007febbccfe000 1024 8 8 rw--- [ anon ]
00007febbccfe000 0 0 0 rw--- [ anon ]
00007febbcdfe000 4 0 0 ----- [ anon ]
00007febbcdfe000 0 0 0 ----- [ anon ]
00007febbcdff000 2052 12 12 rw--- [ anon ]
00007febbcdff000 0 0 0 rw--- [ anon ]
00007febbd000000 2496 416 416 rwx-- [ anon ]
00007febbd000000 0 0 0 rwx-- [ anon ]
00007febbd270000 243264 0 0 ----- [ anon ]
00007febbd270000 0 0 0 ----- [ anon ]
00007febcc000000 1672 1416 1416 rw--- [ anon ]
00007febcc000000 0 0 0 rw--- [ anon ]
00007febcc1a2000 63864 0 0 ----- [ anon ]
00007febcc1a2000 0 0 0 ----- [ anon ]
00007febd0001000 8 8 0 r--s- dnsns.jar
00007febd0001000 0 0 0 r--s- dnsns.jar
00007febd0003000 12 12 0 r--s- icedtea-sound.jar
00007febd0003000 0 0 0 r--s- icedtea-sound.jar
00007febd0006000 4 4 0 r--s- jaccess.jar
00007febd0006000 0 0 0 r--s- jaccess.jar
00007febd0007000 24 24 0 r--s- jfr.jar
00007febd0007000 0 0 0 r--s- jfr.jar
00007febd000d000 196 124 0 r---- LC_CTYPE
00007febd000d000 0 0 0 r---- LC_CTYPE
00007febd003e000 7196 36 36 rw--- [ anon ]
00007febd003e000 0 0 0 rw--- [ anon ]
00007febd0745000 4 0 0 ----- [ anon ]
00007febd0745000 0 0 0 ----- [ anon ]
00007febd0746000 1024 24 24 rw--- [ anon ]
00007febd0746000 0 0 0 rw--- [ anon ]
00007febd0846000 4 0 0 ----- [ anon ]
00007febd0846000 0 0 0 ----- [ anon ]
00007febd0847000 1024 24 24 rw--- [ anon ]
00007febd0847000 0 0 0 rw--- [ anon ]
00007febd0947000 4 0 0 ----- [ anon ]
00007febd0947000 0 0 0 ----- [ anon ]
00007febd0948000 1024 24 24 rw--- [ anon ]
00007febd0948000 0 0 0 rw--- [ anon ]
00007febd0a48000 4 0 0 ----- [ anon ]
00007febd0a48000 0 0 0 ----- [ anon ]
00007febd0a49000 1024 24 24 rw--- [ anon ]
00007febd0a49000 0 0 0 rw--- [ anon ]
00007febd0b49000 4 0 0 ----- [ anon ]
00007febd0b49000 0 0 0 ----- [ anon ]
00007febd0b4a000 1024 24 24 rw--- [ anon ]
00007febd0b4a000 0 0 0 rw--- [ anon ]
00007febd0c4a000 4 0 0 ----- [ anon ]
00007febd0c4a000 0 0 0 ----- [ anon ]
00007febd0c4b000 1024 24 24 rw--- [ anon ]
00007febd0c4b000 0 0 0 rw--- [ anon ]
00007febd0d4b000 4 0 0 ----- [ anon ]
00007febd0d4b000 0 0 0 ----- [ anon ]
00007febd0d4c000 1024 24 24 rw--- [ anon ]
00007febd0d4c000 0 0 0 rw--- [ anon ]
00007febd0e4c000 4 0 0 ----- [ anon ]
00007febd0e4c000 0 0 0 ----- [ anon ]
00007febd0e4d000 1064 64 64 rw--- [ anon ]
00007febd0e4d000 0 0 0 rw--- [ anon ]
00007febd0f57000 3800 0 0 ----- [ anon ]
00007febd0f57000 0 0 0 ----- [ anon ]
00007febd130d000 32 32 0 r-x-- libzip.so
00007febd130d000 0 0 0 r-x-- libzip.so
00007febd1315000 2044 0 0 ----- libzip.so
00007febd1315000 0 0 0 ----- libzip.so
00007febd1514000 4 4 4 r---- libzip.so
00007febd1514000 0 0 0 r---- libzip.so
00007febd1515000 4 4 4 rw--- libzip.so
00007febd1515000 0 0 0 rw--- libzip.so
00007febd1516000 44 44 0 r-x-- libnss_files-2.27.so
00007febd1516000 0 0 0 r-x-- libnss_files-2.27.so
00007febd1521000 2044 0 0 ----- libnss_files-2.27.so
00007febd1521000 0 0 0 ----- libnss_files-2.27.so
00007febd1720000 4 4 4 r---- libnss_files-2.27.so
00007febd1720000 0 0 0 r---- libnss_files-2.27.so
00007febd1721000 4 4 4 rw--- libnss_files-2.27.so
00007febd1721000 0 0 0 rw--- libnss_files-2.27.so
00007febd1722000 24 0 0 rw--- [ anon ]
00007febd1722000 0 0 0 rw--- [ anon ]
00007febd1728000 92 64 0 r-x-- libnsl-2.27.so
00007febd1728000 0 0 0 r-x-- libnsl-2.27.so
00007febd173f000 2044 0 0 ----- libnsl-2.27.so
00007febd173f000 0 0 0 ----- libnsl-2.27.so
00007febd193e000 4 4 4 r---- libnsl-2.27.so
00007febd193e000 0 0 0 r---- libnsl-2.27.so
00007febd193f000 4 4 4 rw--- libnsl-2.27.so
00007febd193f000 0 0 0 rw--- libnsl-2.27.so
00007febd1940000 8 0 0 rw--- [ anon ]
00007febd1940000 0 0 0 rw--- [ anon ]
00007febd1942000 44 44 0 r-x-- libnss_nis-2.27.so
00007febd1942000 0 0 0 r-x-- libnss_nis-2.27.so
00007febd194d000 2044 0 0 ----- libnss_nis-2.27.so
00007febd194d000 0 0 0 ----- libnss_nis-2.27.so
00007febd1b4c000 4 4 4 r---- libnss_nis-2.27.so
00007febd1b4c000 0 0 0 r---- libnss_nis-2.27.so
00007febd1b4d000 4 4 4 rw--- libnss_nis-2.27.so
00007febd1b4d000 0 0 0 rw--- libnss_nis-2.27.so
00007febd1b4e000 32 32 0 r-x-- libnss_compat-2.27.so
00007febd1b4e000 0 0 0 r-x-- libnss_compat-2.27.so
00007febd1b56000 2048 0 0 ----- libnss_compat-2.27.so
00007febd1b56000 0 0 0 ----- libnss_compat-2.27.so
00007febd1d56000 4 4 4 r---- libnss_compat-2.27.so
00007febd1d56000 0 0 0 r---- libnss_compat-2.27.so
00007febd1d57000 4 4 4 rw--- libnss_compat-2.27.so
00007febd1d57000 0 0 0 rw--- libnss_compat-2.27.so
00007febd1d58000 168 160 0 r-x-- libjava.so
00007febd1d58000 0 0 0 r-x-- libjava.so
00007febd1d82000 2048 0 0 ----- libjava.so
00007febd1d82000 0 0 0 ----- libjava.so
00007febd1f82000 4 4 4 r---- libjava.so
00007febd1f82000 0 0 0 r---- libjava.so
00007febd1f83000 8 8 8 rw--- libjava.so
00007febd1f83000 0 0 0 rw--- libjava.so
00007febd1f85000 64 64 0 r-x-- libverify.so
00007febd1f85000 0 0 0 r-x-- libverify.so
00007febd1f95000 2044 0 0 ----- libverify.so
00007febd1f95000 0 0 0 ----- libverify.so
00007febd2194000 8 8 8 r---- libverify.so
00007febd2194000 0 0 0 r---- libverify.so
00007febd2196000 4 4 4 rw--- libverify.so
00007febd2196000 0 0 0 rw--- libverify.so
00007febd2197000 28 28 0 r-x-- librt-2.27.so
00007febd2197000 0 0 0 r-x-- librt-2.27.so
00007febd219e000 2044 0 0 ----- librt-2.27.so
00007febd219e000 0 0 0 ----- librt-2.27.so
00007febd239d000 4 4 4 r---- librt-2.27.so
00007febd239d000 0 0 0 r---- librt-2.27.so
00007febd239e000 4 4 4 rw--- librt-2.27.so
00007febd239e000 0 0 0 rw--- librt-2.27.so
00007febd239f000 92 84 0 r-x-- libgcc_s.so.1
00007febd239f000 0 0 0 r-x-- libgcc_s.so.1
00007febd23b6000 2044 0 0 ----- libgcc_s.so.1
00007febd23b6000 0 0 0 ----- libgcc_s.so.1
00007febd25b5000 4 4 4 r---- libgcc_s.so.1
00007febd25b5000 0 0 0 r---- libgcc_s.so.1
00007febd25b6000 4 4 4 rw--- libgcc_s.so.1
00007febd25b6000 0 0 0 rw--- libgcc_s.so.1
00007febd25b7000 1652 316 0 r-x-- libm-2.27.so
00007febd25b7000 0 0 0 r-x-- libm-2.27.so
00007febd2754000 2044 0 0 ----- libm-2.27.so
00007febd2754000 0 0 0 ----- libm-2.27.so
00007febd2953000 4 4 4 r---- libm-2.27.so
00007febd2953000 0 0 0 r---- libm-2.27.so
00007febd2954000 4 4 4 rw--- libm-2.27.so
00007febd2954000 0 0 0 rw--- libm-2.27.so
00007febd2955000 1508 736 0 r-x-- libstdc++.so.6.0.25
00007febd2955000 0 0 0 r-x-- libstdc++.so.6.0.25
00007febd2ace000 2048 0 0 ----- libstdc++.so.6.0.25
00007febd2ace000 0 0 0 ----- libstdc++.so.6.0.25
00007febd2cce000 40 40 40 r---- libstdc++.so.6.0.25
00007febd2cce000 0 0 0 r---- libstdc++.so.6.0.25
00007febd2cd8000 8 8 8 rw--- libstdc++.so.6.0.25
00007febd2cd8000 0 0 0 rw--- libstdc++.so.6.0.25
00007febd2cda000 16 4 4 rw--- [ anon ]
00007febd2cda000 0 0 0 rw--- [ anon ]
00007febd2cde000 13760 11540 0 r-x-- libjvm.so
00007febd2cde000 0 0 0 r-x-- libjvm.so
00007febd3a4e000 2044 0 0 ----- libjvm.so
00007febd3a4e000 0 0 0 ----- libjvm.so
00007febd3c4d000 600 600 600 r---- libjvm.so
00007febd3c4d000 0 0 0 r---- libjvm.so
00007febd3ce3000 164 164 164 rw--- libjvm.so
00007febd3ce3000 0 0 0 rw--- libjvm.so
00007febd3d0c000 204 196 196 rw--- [ anon ]
00007febd3d0c000 0 0 0 rw--- [ anon ]
00007febd3d3f000 104 104 0 r-x-- libpthread-2.27.so
00007febd3d3f000 0 0 0 r-x-- libpthread-2.27.so
00007febd3d59000 2044 0 0 ----- libpthread-2.27.so
00007febd3d59000 0 0 0 ----- libpthread-2.27.so
00007febd3f58000 4 4 4 r---- libpthread-2.27.so
00007febd3f58000 0 0 0 r---- libpthread-2.27.so
00007febd3f59000 4 4 4 rw--- libpthread-2.27.so
00007febd3f59000 0 0 0 rw--- libpthread-2.27.so
00007febd3f5a000 16 4 4 rw--- [ anon ]
00007febd3f5a000 0 0 0 rw--- [ anon ]
00007febd3f5e000 12 12 0 r-x-- libdl-2.27.so
00007febd3f5e000 0 0 0 r-x-- libdl-2.27.so
00007febd3f61000 2044 0 0 ----- libdl-2.27.so
00007febd3f61000 0 0 0 ----- libdl-2.27.so
00007febd4160000 4 4 4 r---- libdl-2.27.so
00007febd4160000 0 0 0 r---- libdl-2.27.so
00007febd4161000 4 4 4 rw--- libdl-2.27.so
00007febd4161000 0 0 0 rw--- libdl-2.27.so
00007febd4162000 112 108 0 r-x-- libz.so.1.2.11
00007febd4162000 0 0 0 r-x-- libz.so.1.2.11
00007febd417e000 2044 0 0 ----- libz.so.1.2.11
00007febd417e000 0 0 0 ----- libz.so.1.2.11
00007febd437d000 4 4 4 r---- libz.so.1.2.11
00007febd437d000 0 0 0 r---- libz.so.1.2.11
00007febd437e000 4 4 4 rw--- libz.so.1.2.11
00007febd437e000 0 0 0 rw--- libz.so.1.2.11
00007febd437f000 1948 1572 0 r-x-- libc-2.27.so
00007febd437f000 0 0 0 r-x-- libc-2.27.so
00007febd4566000 2048 0 0 ----- libc-2.27.so
00007febd4566000 0 0 0 ----- libc-2.27.so
00007febd4766000 16 16 16 r---- libc-2.27.so
00007febd4766000 0 0 0 r---- libc-2.27.so
00007febd476a000 8 8 8 rw--- libc-2.27.so
00007febd476a000 0 0 0 rw--- libc-2.27.so
00007febd476c000 16 16 16 rw--- [ anon ]
00007febd476c000 0 0 0 rw--- [ anon ]
00007febd4770000 56 56 0 r-x-- libjli.so
00007febd4770000 0 0 0 r-x-- libjli.so
00007febd477e000 2044 0 0 ----- libjli.so
00007febd477e000 0 0 0 ----- libjli.so
00007febd497d000 4 4 4 r---- libjli.so
00007febd497d000 0 0 0 r---- libjli.so
00007febd497e000 4 4 4 rw--- libjli.so
00007febd497e000 0 0 0 rw--- libjli.so
00007febd497f000 164 164 0 r-x-- ld-2.27.so
00007febd497f000 0 0 0 r-x-- ld-2.27.so
00007febd49a8000 8 8 0 r--s- zipfs.jar
00007febd49a8000 0 0 0 r--s- zipfs.jar
00007febd49aa000 8 8 0 r--s- sunec.jar
00007febd49aa000 0 0 0 r--s- sunec.jar
00007febd49ac000 4 4 0 r---- LC_NUMERIC
00007febd49ac000 0 0 0 r---- LC_NUMERIC
00007febd49ad000 4 4 0 r---- LC_TIME
00007febd49ad000 0 0 0 r---- LC_TIME
00007febd49ae000 4 4 0 r---- LC_MONETARY
00007febd49ae000 0 0 0 r---- LC_MONETARY
00007febd49af000 4 4 0 r---- SYS_LC_MESSAGES
00007febd49af000 0 0 0 r---- SYS_LC_MESSAGES
00007febd49b0000 4 4 0 r---- LC_PAPER
00007febd49b0000 0 0 0 r---- LC_PAPER
00007febd49b1000 4 4 0 r---- LC_NAME
00007febd49b1000 0 0 0 r---- LC_NAME
00007febd49b2000 28 28 0 r--s- gconv-modules.cache
00007febd49b2000 0 0 0 r--s- gconv-modules.cache
00007febd49b9000 700 700 700 rw--- [ anon ]
00007febd49b9000 0 0 0 rw--- [ anon ]
00007febd4a68000 60 60 60 rw--- [ anon ]
00007febd4a68000 0 0 0 rw--- [ anon ]
00007febd4a77000 60 0 0 ----- [ anon ]
00007febd4a77000 0 0 0 ----- [ anon ]
00007febd4a86000 60 60 60 rw--- [ anon ]
00007febd4a86000 0 0 0 rw--- [ anon ]
00007febd4a95000 32 32 16 rw-s- 10
00007febd4a95000 0 0 0 rw-s- 10
00007febd4a9d000 4 0 0 ----- [ anon ]
00007febd4a9d000 0 0 0 ----- [ anon ]
00007febd4a9e000 12 0 0 ----- [ anon ]
00007febd4a9e000 0 0 0 ----- [ anon ]
00007febd4aa1000 1020 112 112 rw--- [ anon ]
00007febd4aa1000 0 0 0 rw--- [ anon ]
00007febd4ba0000 4 4 0 r---- LC_ADDRESS
00007febd4ba0000 0 0 0 r---- LC_ADDRESS
00007febd4ba1000 4 4 0 r---- LC_TELEPHONE
00007febd4ba1000 0 0 0 r---- LC_TELEPHONE
00007febd4ba2000 4 4 0 r---- LC_MEASUREMENT
00007febd4ba2000 0 0 0 r---- LC_MEASUREMENT
00007febd4ba3000 4 4 0 r---- LC_IDENTIFICATION
00007febd4ba3000 0 0 0 r---- LC_IDENTIFICATION
00007febd4ba4000 4 4 4 rw--- [ anon ]
00007febd4ba4000 0 0 0 rw--- [ anon ]
00007febd4ba5000 4 0 0 r---- [ anon ]
00007febd4ba5000 0 0 0 r---- [ anon ]
00007febd4ba6000 8 8 8 rw--- [ anon ]
00007febd4ba6000 0 0 0 rw--- [ anon ]
00007febd4ba8000 4 4 4 r---- ld-2.27.so
00007febd4ba8000 0 0 0 r---- ld-2.27.so
00007febd4ba9000 4 4 4 rw--- ld-2.27.so
00007febd4ba9000 0 0 0 rw--- ld-2.27.so
00007febd4baa000 4 4 4 rw--- [ anon ]
00007febd4baa000 0 0 0 rw--- [ anon ]
00007ffd92dc9000 132 32 32 rw--- [ stack ]
00007ffd92dc9000 0 0 0 rw--- [ stack ]
00007ffd92dfa000 8 0 0 r---- [ anon ]
00007ffd92dfa000 0 0 0 r---- [ anon ]
00007ffd92dfc000 8 4 0 r-x-- [ anon ]
00007ffd92dfc000 0 0 0 r-x-- [ anon ]
ffffffffff600000 4 0 0 r-x-- [ anon ]
ffffffffff600000 0 0 0 r-x-- [ anon ]
---------------- ------- ------- -------
total kB 3650152 67032 49164
이 결과중 Heap 영역의 가상에 메모리 구간을 확인하고 싶었다.
pmap -x 19408 | sort -k 3 -n -r | more
RSS 사용순으로 정렬하였을때 가장 상단에 나오는 메모리 맵핑이 물리 메모리를 가장 많이 사용하는 맵핑이다.
하지만 linux 가 알 수 없는 맵핑의 경우에는 anon 으로 노출되어 실제로 힙 영역의 가상메모리 주소인지 알 수 없다.
00000000fe200000 ~ 0000000100080000 가 힙 영역인 이유는 아래와 같다
근거1) 가상메모리 크기가 힙 사이즈와 같다.
00000000fe200000 31232 30364 30364 rw--- [ anon ]
0000000100080000 1048064 0 0 ----- [ anon ]
0xfe200000 ~ 0x100080000 까지가 첫번째 맵핑이 사용하는 가상메모리 주소이다.
해당 맵핑이 사용하는 크기를 구하기 위해서 0x100080000 - 0xfe200000 하였다.
결과를 10진수로 변환하면 31981568 이고 주소 하나당 1byte 의 크기를 가지니 첫번째 맵핑이 사용하는 가상메모리 크기는 31981567byte 이고 30.5MB 이다.
해당 프로세스를 실행할때 JVM argument 로 -Xms30m -Xmx30m 을 전달하였다. 첫번째 맵핑의 크기와 매우 유사한것을 확인할 수 있다.
근거2) 힙 덤프의 객체 address 가 (0xfe200000 ~ 0x100080000) 사이에 할당됨.
실행중인 자바 프로세스의 힙 덤프를 떠서 MAT 로 분석을 해보았다.
화면에 보이는 객체들의 주소는 모두 첫번째 맵핑 사이에 존재함을 확인할 수 있다.
이는 Thread dump 에서도 확인할 수 있다.
"Surrogate Locker Thread (Concurrent GC)" #4 daemon prio=9 os_prio=0 tid=0x00007febcc109800 nid=0x23 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Finalizer" #3 daemon prio=8 os_prio=0 tid=0x00007febcc0d7800 nid=0x22 in Object.wait() [0x00007feb6cd61000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000000fe2111f0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:144)
- locked <0x00000000fe2111f0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:165)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:216)
"Reference Handler" #2 daemon prio=10 os_prio=0 tid=0x00007febcc0d3000 nid=0x21 in Object.wait() [0x00007feb6ce62000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000000fe2111e0> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:502)
at java.lang.ref.Reference.tryHandlePending(Reference.java:191)
- locked <0x00000000fe2111e0> (a java.lang.ref.Reference$Lock)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:153)
전체 보기 :
2022-01-04 09:28:26
Full thread dump OpenJDK 64-Bit Server VM (25.292-b10 mixed mode):
"Attach Listener" #11 daemon prio=9 os_prio=0 tid=0x00007feb50001000 nid=0x639 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Service Thread" #10 daemon prio=9 os_prio=0 tid=0x00007febcc117800 nid=0x29 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C1 CompilerThread3" #9 daemon prio=9 os_prio=0 tid=0x00007febcc114800 nid=0x28 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread2" #8 daemon prio=9 os_prio=0 tid=0x00007febcc112800 nid=0x27 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread1" #7 daemon prio=9 os_prio=0 tid=0x00007febcc110800 nid=0x26 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"C2 CompilerThread0" #6 daemon prio=9 os_prio=0 tid=0x00007febcc10e800 nid=0x25 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Signal Dispatcher" #5 daemon prio=9 os_prio=0 tid=0x00007febcc10a800 nid=0x24 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Surrogate Locker Thread (Concurrent GC)" #4 daemon prio=9 os_prio=0 tid=0x00007febcc109800 nid=0x23 waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
"Finalizer" #3 daemon prio=8 os_prio=0 tid=0x00007febcc0d7800 nid=0x22 in Object.wait() [0x00007feb6cd61000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000000fe2111f0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:144)
- locked <0x00000000fe2111f0> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:165)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:216)
"Reference Handler" #2 daemon prio=10 os_prio=0 tid=0x00007febcc0d3000 nid=0x21 in Object.wait() [0x00007feb6ce62000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait(Native Method)
- waiting on <0x00000000fe2111e0> (a java.lang.ref.Reference$Lock)
at java.lang.Object.wait(Object.java:502)
at java.lang.ref.Reference.tryHandlePending(Reference.java:191)
- locked <0x00000000fe2111e0> (a java.lang.ref.Reference$Lock)
at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:153)
"main" #1 prio=5 os_prio=0 tid=0x00007febcc00c000 nid=0xb waiting on condition [0x00007febd4b9c000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep(Native Method)
at Main.main(Main.java:9)
"VM Thread" os_prio=0 tid=0x00007febcc0c9000 nid=0x20 runnable
"Gang worker#0 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc021800 nid=0xc runnable
"Gang worker#1 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc023000 nid=0xd runnable
"Gang worker#2 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc025000 nid=0xe runnable
"Gang worker#3 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc026800 nid=0xf runnable
"Gang worker#4 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc028800 nid=0x10 runnable
"Gang worker#5 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc02a000 nid=0x11 runnable
"Gang worker#6 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc02c000 nid=0x12 runnable
"Gang worker#7 (Parallel GC Threads)" os_prio=0 tid=0x00007febcc02d800 nid=0x13 runnable
"G1 Main Concurrent Mark GC Thread" os_prio=0 tid=0x00007febcc046000 nid=0x1d runnable
"Gang worker#0 (G1 Parallel Marking Threads)" os_prio=0 tid=0x00007febcc048000 nid=0x1e runnable
"Gang worker#1 (G1 Parallel Marking Threads)" os_prio=0 tid=0x00007febcc049800 nid=0x1f runnable
"G1 Concurrent Refinement Thread#0" os_prio=0 tid=0x00007febcc03f000 nid=0x1c runnable
"G1 Concurrent Refinement Thread#1" os_prio=0 tid=0x00007febcc03d000 nid=0x1b runnable
"G1 Concurrent Refinement Thread#2" os_prio=0 tid=0x00007febcc03b800 nid=0x1a runnable
"G1 Concurrent Refinement Thread#3" os_prio=0 tid=0x00007febcc039800 nid=0x19 runnable
"G1 Concurrent Refinement Thread#4" os_prio=0 tid=0x00007febcc037800 nid=0x18 runnable
"G1 Concurrent Refinement Thread#5" os_prio=0 tid=0x00007febcc036000 nid=0x17 runnable
"G1 Concurrent Refinement Thread#6" os_prio=0 tid=0x00007febcc034000 nid=0x16 runnable
"G1 Concurrent Refinement Thread#7" os_prio=0 tid=0x00007febcc032800 nid=0x15 runnable
"G1 Concurrent Refinement Thread#8" os_prio=0 tid=0x00007febcc030800 nid=0x14 runnable
"VM Periodic Task Thread" os_prio=0 tid=0x00007febcc11a800 nid=0x2a waiting on condition
JNI global references: 5
Thread dump 에서 특정 객체의 Lock 을 기다리고 있는 구문을 보면 해당 객체의 주소를 확인할 수 있다.
waiting on <0x00000000fe2111e0> (a java.lang.ref.Reference$Lock)
이 또한 역시 첫번째 맵핑 구간에 포함된다.
결론
이러한 근거들을 토대로 해당 프로세스의 RSS 를 가장 많이 사용하고 있는 첫번째 프로세스 메모리 맵핑이 힙 영역임을 확인할 수 있다. 또한 Heap 덤프에 노출되는 Address 는 가상메모리 주소임을 확인할 수 있다.
Heap 의 가상메모리 범위를 알았기 때문에 GC 가 발생해도 JVM 은 물리 메모리를 OS 에게 반환하지 않는다. 를 확인하기 위해 Heap 가상메모리에 맵핑된 Physical memory 주소가 GC 이후에도 변하는지를 확인하고지 page table 을 확인하고 싶었다. 하지만 MMU 에서 관리하는 Page Table 은 확인할 수 없는 것으로 보인다.
'JAVA' 카테고리의 다른 글
Java wait(), notify(), notifyAll() 과 Thread 상태 (0) | 2022.06.29 |
---|---|
StringBuilder 와 StringBuffer 비교 (0) | 2022.03.23 |
JVM GC 후 Heap 에게 할당된 물리 메모리 OS에게 회수 여부 (0) | 2022.01.03 |
-Xms 보다 Memory 사용량이 더 적은 이유 (0) | 2021.12.31 |
mysql-connector -> mariadb-connector-j 시 주의할 점 (0) | 2021.10.20 |
- Total
- Today
- Yesterday
- mariadb-connector-j
- N+1
- aurora
- RoutePredication
- getBoolean
- msyql-connector-java
- reactor
- Flux
- RouteDefinition
- AbstractMethodError
- notifyAll()
- GlobalFilter
- DyanomoDB
- spring cloud gateway
- wait()
- circurit breaker
- Lazy
- dynamodb
- ConcurrentHashMap
- router
- ResultSet
- referencedColumnName
- notify()
- mariada-connector
- reative
- MariaDB
- rate limit
- HashMap
- custom config data convertion
- Seperate Chaining
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |