You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by userx <ga...@gmail.com> on 2018/11/20 13:12:10 UTC

Swapspace - Getting OOM error ?maxSize more than RAM

Hi All,

I went through the documentation present at 
https://apacheignite.readme.io/docs/swap-space
<https://apacheignite.readme.io/docs/swap-space>  
It states that if the maxSize parameter of the data region is more than the
size of the RAM, the OS will take care of the swapping.  This is to avoid
the OOM error. However even after the following configuration, I am getting
the OOM error

[17:59:44] Topology snapshot [ver=1, servers=1, clients=0, CPUs=8,
offheap=70.0GB, heap=7.1GB]
[17:59:44]   ^-- Node [id=52926F03-E374-492B-94D8-C713757B5491,
clusterState=ACTIVE]
[17:59:44] Data Regions Configured:
[17:59:44]   ^-- default [initSize=256.0 MiB, maxSize=6.4 GiB,
persistenceEnabled=false]
[17:59:44]   ^-- 500MB_Region [initSize=100.0 MiB, maxSize=64.0 GiB,
persistenceEnabled=false]
[18:05:31,828][SEVERE][main][] Critical system error detected. Will be
handled accordingly to configured handler [hnd=class
o.a.i.failure.StopNodeOrHaltFailureHandler, failureCtx=FailureContext
[type=CRITICAL_ERROR, err=class o.a.i.i.mem.IgniteOutOfMemoryException: Out
of memory in data region [name=default, initSize=256.0 MiB, maxSize=6.4 GiB,
persistenceEnabled=false] Try the following:
  ^-- Increase maximum off-heap memory size
(DataRegionConfiguration.maxSize)
  ^-- Enable Ignite persistence (DataRegionConfiguration.persistenceEnabled)
  ^-- Enable eviction or expiration policies]]



Configuration - 
<beans xmlns="http://www.springframework.org/schema/beans"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://www.springframework.org/schema/beans
        http://www.springframework.org/schema/beans/spring-beans.xsd">
	<bean class="org.apache.ignite.configuration.IgniteConfiguration">
		
		<property name="dataStorageConfiguration">
			<bean
				class="org.apache.ignite.configuration.DataStorageConfiguration">
				<property name="dataRegionConfigurations">
					<list>
						
						<bean
							class="org.apache.ignite.configuration.DataRegionConfiguration">
							
							<property name="name" value="500MB_Region" />

							
							<property name="initialSize"
								value="#{100L * 1024 * 1024}" />

							
							<property name="maxSize"
								value="#{64L * 1024 * 1024 * 1024}" />

							
							<property name="swapPath"
								value="C:\\Data\\Swapspace" />
						</bean>
					</list>
				</property>
			</bean>
		</property>

		
	</bean>
</beans>


Can anyone help ?




--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Swapspace - Getting OOM error ?maxSize more than RAM

Posted by aealexsandrov <ae...@gmail.com>.
Hi,

You faced that OOM issue because your cache was mapped to the default region
with max size 6.4 GB instead of 500MB_Region with max size 64GB.

I guess that you try to load more than 6.4 GB of data to this cache.

Generally, you should set the required data region for every cache in case
if it should not be mapped to the default region. 

BR,
Andrei



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Swapspace - Getting OOM error ?maxSize more than RAM

Posted by userx <ga...@gmail.com>.
Just for information,

This goes away once the CacheConfiguration is mapped to a region by using 
cacheCfg.setDataRegionName("500MB_Region") method.





--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/