How to allocate memory

Hi,

I have 2 systems with same hardware and software. One system is giving me error "Error occurred during initialization of VM Could not reserve enough space for object " when I tried to increase JBoss App's heap size to 2GB while the other system is running fine without any issue. Is there anything I can change/check in OS to compare. I have compared the both systems ulimit, processes, /proc/sys/vm, /ete/sysclt.conf they all look the same. Please help::

Working System with 2GB:
[root@dnpt017 root]# cat /proc/meminfo
total: used: free: shared: buffers: cached:
Mem: 5249564672 2382192640 2867372032 0 150224896 1232392192
Swap: 2146787328 0 2146787328
MemTotal: 5126528 kB
MemFree: 2800168 kB
MemShared: 0 kB
Buffers: 146704 kB
Cached: 1203508 kB
SwapCached: 0 kB
Active: 1197156 kB
ActiveAnon: 504040 kB
ActiveCache: 693116 kB
Inact_dirty: 540712 kB
Inact_laundry: 157176 kB
Inact_clean: 6396 kB
Inact_target: 380288 kB
HighTotal: 4325056 kB
HighFree: 2562320 kB
LowTotal: 801472 kB
LowFree: 237848 kB
SwapTotal: 2096472 kB
SwapFree: 2096472 kB
CommitLimit: 4659736 kB
Committed_AS: 935568 kB
HugePages_Total: 0
HugePages_Free: 0
Hugepagesize: 2048 kB
[root@dnpt017 root]#

Not working system with 2GB:
[root@dnpt015 etc]# cat /proc/meminfo
total: used: free: shared: buffers: cached:
Mem: 5249564672 2846355456 2403209216 0 141348864 1722580992
Swap: 2146787328 0 2146787328
MemTotal: 5126528 kB
MemFree: 2346884 kB
MemShared: 0 kB
Buffers: 138036 kB
Cached: 1682208 kB
SwapCached: 0 kB
Active: 1296160 kB
ActiveAnon: 498848 kB
ActiveCache: 797312 kB
Inact_dirty: 853800 kB
Inact_laundry: 263660 kB
Inact_clean: 0 kB
Inact_target: 482724 kB
HighTotal: 4325056 kB
HighFree: 2041836 kB
LowTotal: 801472 kB
LowFree: 305048 kB
SwapTotal: 2096472 kB
SwapFree: 2096472 kB
CommitLimit: 4659736 kB
Committed_AS: 888652 kB
HugePages_Total: 0
HugePages_Free: 0
Hugepagesize: 2048 kB
[root@dnpt015 etc]#

Compare the two systems for swap as this issue might be related to swap space utilization.

I have compared the /proc/swaps, both systems have the same swaps too:

[root@dnpt015 proc]# cat swaps
Filename Type Size Used Priority
/dev/sda2 partition 2096472 0 -1

[root@dnpt017 bin]# cat /proc/swaps
Filename Type Size Used Priority
/dev/sda2 partition 2096472 0 -1

dnpt015 has issue where dnpt017 is has NO Issue compare to JVM....

[root@dnpt015 proc]# vmstat 1 5
procs memory swap io system cpu
r b swpd free buff cache si so bi bo in cs us sy id wa
0 0 0 2174900 138048 1686520 0 0 0 1 0 2 2 1 1 1
0 0 0 2174900 138048 1686520 0 0 0 0 143 167 1 0 99 0
0 0 0 2174900 138048 1686520 0 0 0 0 181 238 0 0 100 0
0 0 0 2174900 138048 1686520 0 0 0 0 155 234 0 0 99 0
0 0 0 2174900 138048 1686520 0 0 0 0 108 89 0 0 100 0

[root@dnpt017 bin]# vmstat 1 5
procs memory swap io system cpu
r b swpd free buff cache si so bi bo in cs us sy id wa
0 0 0 2618548 146716 1207404 0 0 0 1 0 0 0 0 1 0
0 0 0 2618548 146716 1207404 0 0 0 0 124 146 0 0 100 0
0 0 0 2618548 146716 1207404 0 0 0 0 109 89 0 0 100 0
0 0 0 2618548 146716 1207404 0 0 0 0 219 262 1 0 99 0
0 0 0 2618548 146716 1207404 0 0 0 64 113 95 0 0 100 0

What versions of java and what switches for the java command? Are these both linux boxes? I believe the JVM heap size is limited to 2GB for some version of java under linux but I'm not 100% sure.

ulimit -a
java -version
32 bit java?