java.lang.OutOfMemoryError: Java heap space

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

java.lang.OutOfMemoryError: Java heap space

indon.bae
All,
 
Need urgent help!
 
Our OpenNMS was running well last six months without any issue, but suddenly I was no longer able to sign on to it via Web browser.
In order to restart OpenNMS, I tried "opennms stop", but did not worked because of errors.
Only way I can restart the OpenNMS is reloading OS (Fedora Core 6) but few hours later, I got same error and I cannot log-on.
 
The problem seems to me that something is causing an error -  "java.lang.OutOfMemoryError: Java heap space."
Could anyone help me understand what is causing this problem and how to remedy this problem?
 
Copy of few lines from "output.log" file.
"Executing command: /opt/opennms/bin/runjava -r -- -Dopennms.home=/opt/opennms -Xmx256m -jar /opt/opennms/lib/opennms_bootstrap.jar start
Exception in thread "Timer-3411" java.util.ConcurrentModificationException
     at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
     at org.snmp4j.Snmp.close(Unknown Source)
     at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
     at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
     at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
     at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
     at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Exception in thread "Timer-3419" java.util.ConcurrentModificationException

at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)

at org.snmp4j.Snmp.close(Unknown Source)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)

at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)

at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)

at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

  
Your help will be greatly appreciated.

--
In Don Bae

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Antw: java.lang.OutOfMemoryError: Java heap space

Michael Seibold
Hi In Don Bae,

I can't tell you the reason why opennms needs more heap space now, some possibilities are that

- you have more nodes now in the data base
- defined more data collections or services to poll
- have reduced the timespan between polling or datacollection cycles
- have CPU problems or disk I/O problems so polling cycles are not finished
   before the next cycle starts, which in the end will need some extra memory for each
  polling cycle that is stiill not finished

for sure there are other reasons too. You should look for what has been changed lately.

To avoid the urgent problem you can increase the java heap size in $OPENNMS_HOME/etc/opennms.conf like:

        JAVA_HEAP_SIZE=512

Default value set during installation is 256, these are MBytes of Memory.

Hope this helps

- Michael


>>> <[hidden email]> 20.08.2008 19:12 >>>
All,

Need urgent help!

Our OpenNMS was running well last six months without any issue, but suddenly
I was no longer able to sign on to it via Web browser.
In order to restart OpenNMS, I tried "opennms stop", but did not worked
because of errors.
Only way I can restart the OpenNMS is reloading OS (Fedora Core 6) but few
hours later, I got same error and I cannot log-on.

The problem seems to me that something is causing an error -
 "java.lang.OutOfMemoryError: Java heap space."
Could anyone help me understand what is causing this problem and how to
remedy this problem?

Copy of few lines from "output.log" file.
"Executing command: /opt/opennms/bin/runjava -r --
-Dopennms.home=/opt/opennms -Xmx256m -jar
/opt/opennms/lib/opennms_bootstrap.jar start
Exception in thread "Timer-3411" java.util.ConcurrentModificationException
     at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
     at org.snmp4j.Snmp.close(Unknown Source)
     at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
     at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
     at
org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
     at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
     at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Exception in thread "Timer-3419" java.util.ConcurrentModificationException

at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)

at org.snmp4j.Snmp.close(Unknown Source)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)

at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)

at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)

at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Your help will be greatly appreciated.

--
In Don Bae


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Antw: java.lang.OutOfMemoryError: Java heap space

indon.bae
Hi Michael,

Thanks for your suggestion.
I'll change HEAP size to 512.
 
Unfortunately, I cannot think of anything changed recentely.
However, I'll try to reduce # of nodes.
 
Thanks, again.
 
In Don Bae
On Thu, Aug 21, 2008 at 1:03 AM, Michael Seibold <[hidden email]> wrote:
Hi In Don Bae,

I can't tell you the reason why opennms needs more heap space now, some possibilities are that

- you have more nodes now in the data base
- defined more data collections or services to poll
- have reduced the timespan between polling or datacollection cycles
- have CPU problems or disk I/O problems so polling cycles are not finished
  before the next cycle starts, which in the end will need some extra memory for each
 polling cycle that is stiill not finished

for sure there are other reasons too. You should look for what has been changed lately.

To avoid the urgent problem you can increase the java heap size in $OPENNMS_HOME/etc/opennms.conf like:

       JAVA_HEAP_SIZE=512

Default value set during installation is 256, these are MBytes of Memory.

Hope this helps

- Michael


>>> <[hidden email]> 20.08.2008 19:12 >>>
All,

Need urgent help!

Our OpenNMS was running well last six months without any issue, but suddenly
I was no longer able to sign on to it via Web browser.
In order to restart OpenNMS, I tried "opennms stop", but did not worked
because of errors.
Only way I can restart the OpenNMS is reloading OS (Fedora Core 6) but few
hours later, I got same error and I cannot log-on.

The problem seems to me that something is causing an error -
 "java.lang.OutOfMemoryError: Java heap space."
Could anyone help me understand what is causing this problem and how to
remedy this problem?

Copy of few lines from "output.log" file.
"Executing command: /opt/opennms/bin/runjava -r --
-Dopennms.home=/opt/opennms -Xmx256m -jar
/opt/opennms/lib/opennms_bootstrap.jar start
Exception in thread "Timer-3411" java.util.ConcurrentModificationException
    at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
    at org.snmp4j.Snmp.close(Unknown Source)
    at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
    at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
    at
org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
    at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
    at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Exception in thread "Timer-3419" java.util.ConcurrentModificationException

at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)

at org.snmp4j.Snmp.close(Unknown Source)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)

at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)

at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)

at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Your help will be greatly appreciated.

--
In Don Bae


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss



--
In Don Bae

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Antw: java.lang.OutOfMemoryError: Java heap space

indon.bae
I increased heap size by adding 'JAVA_HEAP_SIZE=512' in $OPENNMS_HOME/etc/opennms.conf but the results are same.
Once I increased java heap size, I restarted OpenNMS but it failed few hours later, as you can see from copy of '/var/log/opennms/daemon/output.log.
___________________________________________________
Thu Aug 21 09:02:33 PDT 2008
begin ulimit settings:
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
max nice                        (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 32735
max locked memory       (kbytes, -l) 32
max memory size         (kbytes, -m) unlimited
open files                      (-n) 10240
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
max rt priority                 (-r) 0
stack size              (kbytes, -s) 8192
cpu time               (seconds, -t) unlimited
max user processes              (-u) 32735
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited
end ulimit settings
Executing command: /opt/opennms/bin/runjava -r  --   -Dopennms.home=/opt/opennms -Xmx512m -jar /opt/opennms/lib/opennms_bootstrap.jar  start 
:
:
2008-08-21 15:14:28.812::INFO:  Shutdown hook executing
Exception in thread "LinkdScheduler-5 Pool-fiber2" java.lang.OutOfMemoryError: Java heap space
2008-08-21 15:17:46.098:/opennms:INFO:  Destroying Spring FrameworkServlet 'dispatcher'
2008-08-21 15:21:02.480:/opennms:INFO:  Destroying Spring FrameworkServlet 'mapDispatcher'
2008-08-21 15:21:04.553:/opennms:INFO:  Destroying Spring FrameworkServlet 'gwtDispatcher'
2008-08-21 15:21:11.453:/opennms:INFO:  Closing Spring root WebApplicationContext
2008-08-21 15:21:16.397:/opennms:INFO:  Shutting down Log4J
log4j:WARN No appenders could be found for logger (OpenNMS.Collectd.org.opennms.netmgt.collectd.SnmpIfCollector).
log4j:WARN Please initialize the log4j system properly.
2008-08-21 15:21:18.407:/opennms:INFO:  [InitializerServletContextListener] Destroyed servlet systems successfully
2008-08-21 15:21:33.548::INFO:  Shutdown hook complete
---------------------------------------------------------------------------------------------


 
On Thu, Aug 21, 2008 at 8:24 AM, <[hidden email]> wrote:
Hi Michael,

Thanks for your suggestion.
I'll change HEAP size to 512.
 
Unfortunately, I cannot think of anything changed recentely.
However, I'll try to reduce # of nodes.
 
Thanks, again.
 
In Don Bae
On Thu, Aug 21, 2008 at 1:03 AM, Michael Seibold <[hidden email]> wrote:
Hi In Don Bae,

I can't tell you the reason why opennms needs more heap space now, some possibilities are that

- you have more nodes now in the data base
- defined more data collections or services to poll
- have reduced the timespan between polling or datacollection cycles
- have CPU problems or disk I/O problems so polling cycles are not finished
  before the next cycle starts, which in the end will need some extra memory for each
 polling cycle that is stiill not finished

for sure there are other reasons too. You should look for what has been changed lately.

To avoid the urgent problem you can increase the java heap size in $OPENNMS_HOME/etc/opennms.conf like:

       JAVA_HEAP_SIZE=512

Default value set during installation is 256, these are MBytes of Memory.

Hope this helps

- Michael


>>> <[hidden email]> 20.08.2008 19:12 >>>
All,

Need urgent help!

Our OpenNMS was running well last six months without any issue, but suddenly
I was no longer able to sign on to it via Web browser.
In order to restart OpenNMS, I tried "opennms stop", but did not worked
because of errors.
Only way I can restart the OpenNMS is reloading OS (Fedora Core 6) but few
hours later, I got same error and I cannot log-on.

The problem seems to me that something is causing an error -
 "java.lang.OutOfMemoryError: Java heap space."
Could anyone help me understand what is causing this problem and how to
remedy this problem?

Copy of few lines from "output.log" file.
"Executing command: /opt/opennms/bin/runjava -r --
-Dopennms.home=/opt/opennms -Xmx256m -jar
/opt/opennms/lib/opennms_bootstrap.jar start
Exception in thread "Timer-3411" java.util.ConcurrentModificationException
    at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
    at org.snmp4j.Snmp.close(Unknown Source)
    at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
    at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
    at
org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
    at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
    at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Exception in thread "Timer-3419" java.util.ConcurrentModificationException

at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)

at org.snmp4j.Snmp.close(Unknown Source)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)

at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)

at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)

at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Your help will be greatly appreciated.

--
In Don Bae


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss



--
In Don Bae



--
In Don Bae

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Antw: java.lang.OutOfMemoryError: Java heap space

Jeff Gehlbach
On Aug 22, 2008, at 12:13 PM, [hidden email] wrote:

> I increased heap size by adding 'JAVA_HEAP_SIZE=512' in  
> $OPENNMS_HOME/etc/opennms.conf but the results are same.
> Once I increased java heap size, I restarted OpenNMS but it failed  
> few hours later, as you can see from copy of '/var/log/opennms/
> daemon/output.log.

That means that OpenNMS is still running out of heap space.  You have  
never in this thread mentioned what version of OpenNMS you are using  
-- please provide that information any time you report a problem.

> Unfortunately, I cannot think of anything changed recentely.

Since you're suddenly seeing heap exhaustion, *something* has  
changed.  It may not be something that you changed intentionally,  
which means you must go looking for what it could be.

I'll quote Michael's comments on a few reasons this can happen, even  
without your explicit action:

> - you have more nodes now in the data base

If you are running Discovery, new nodes can appear at any time with no  
action on your part.  How many nodes are in your database?

> - defined more data collections or services to poll

An upgrade of OpenNMS can result in a growth in data collection or  
service definitions.

> - have CPU problems or disk I/O problems so polling cycles are not  
> finished
>   before the next cycle starts, which in the end will need some  
> extra memory for each
>  polling cycle that is stiill not finished

This problem can appear, seemingly out of nowhere, when more nodes /  
services / data collection are added to the system.  It can also be  
triggered on some systems by a sudden growth in the number of events  
in the OpenNMS database.

I think CPU or I/O problems are the most likely reason for your  
problems.  What is the load average as reported by the "uptime"  
command?  What is the iowait percentage?  Some versions of "top"  
report this, or you may need to use "iostat -x" from the "sysstat"  
package, which may not be installed by default.  What about memory  
statistics as reported by "free"?

-jeff

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: Antw: java.lang.OutOfMemoryError: Java heap space

indon.bae
Hi Jeff,
 
Thank you for your help.
I'll try as you suggested and if I still experiencing problem, I will inculde as much as information as you also mentioned in your other email.

In Don Bae
On Sat, Aug 23, 2008 at 1:26 PM, Jeff Gehlbach <[hidden email]> wrote:
On Aug 22, 2008, at 12:13 PM, [hidden email] wrote:

> I increased heap size by adding 'JAVA_HEAP_SIZE=512' in
> $OPENNMS_HOME/etc/opennms.conf but the results are same.
> Once I increased java heap size, I restarted OpenNMS but it failed
> few hours later, as you can see from copy of '/var/log/opennms/
> daemon/output.log.

That means that OpenNMS is still running out of heap space.  You have
never in this thread mentioned what version of OpenNMS you are using
-- please provide that information any time you report a problem.

> Unfortunately, I cannot think of anything changed recentely.

Since you're suddenly seeing heap exhaustion, *something* has
changed.  It may not be something that you changed intentionally,
which means you must go looking for what it could be.

I'll quote Michael's comments on a few reasons this can happen, even
without your explicit action:

> - you have more nodes now in the data base

If you are running Discovery, new nodes can appear at any time with no
action on your part.  How many nodes are in your database?

> - defined more data collections or services to poll

An upgrade of OpenNMS can result in a growth in data collection or
service definitions.

> - have CPU problems or disk I/O problems so polling cycles are not
> finished
>   before the next cycle starts, which in the end will need some
> extra memory for each
>  polling cycle that is stiill not finished

This problem can appear, seemingly out of nowhere, when more nodes /
services / data collection are added to the system.  It can also be
triggered on some systems by a sudden growth in the number of events
in the OpenNMS database.

I think CPU or I/O problems are the most likely reason for your
problems.  What is the load average as reported by the "uptime"
command?  What is the iowait percentage?  Some versions of "top"
report this, or you may need to use "iostat -x" from the "sysstat"
package, which may not be installed by default.  What about memory
statistics as reported by "free"?

-jeff

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss



--
In Don Bae

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: java.lang.OutOfMemoryError: Java heap space

BryanD
In reply to this post by indon.bae
I am having the same issue. It started after we added a bunch of new nodes so I don't doubt that I need to increase the heap space. I am running:
OpenNMS Version: 1.5.90
Java Version: 1.5.0_15 Sun Microsystems Inc.
Java Virtual Machine: 1.5.0_15-b04 Sun Microsystems Inc.
Operating System: Linux 2.6.24-19-server (i386)

The problem is I don't have an opennms.conf file (was this changed in 1.5.90?) so I don't know where to increase the heap space. Where do I do this?

indon.bae wrote
All,

Need urgent help!

Our OpenNMS was running well last six months without any issue, but suddenly
I was no longer able to sign on to it via Web browser.
In order to restart OpenNMS, I tried "opennms stop", but did not worked
because of errors.
Only way I can restart the OpenNMS is reloading OS (Fedora Core 6) but few
hours later, I got same error and I cannot log-on.

The problem seems to me that something is causing an error -
 "java.lang.OutOfMemoryError: Java heap space."
Could anyone help me understand what is causing this problem and how to
remedy this problem?

Copy of few lines from "output.log" file.
"Executing command: /opt/opennms/bin/runjava -r --
-Dopennms.home=/opt/opennms -Xmx256m -jar
/opt/opennms/lib/opennms_bootstrap.jar start
Exception in thread "Timer-3411" java.util.ConcurrentModificationException
     at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
     at org.snmp4j.Snmp.close(Unknown Source)
     at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
     at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
     at
org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
     at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
     at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Exception in thread "Timer-3419" java.util.ConcurrentModificationException

at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)

at org.snmp4j.Snmp.close(Unknown Source)

at org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)

at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)

at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)

at
org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)

at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)

at java.util.TimerThread.mainLoop(Timer.java:512)

at java.util.TimerThread.run(Timer.java:462)

Your help will be greatly appreciated.

--
In Don Bae

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: java.lang.OutOfMemoryError: Java heap space

Jeff Gehlbach
On Sep 2, 2008, at 9:56 AM, BryanD wrote:

> I am having the same issue. It started after we added a bunch of new  
> nodes so
> I don't doubt that I need to increase the heap space. I am running:
> OpenNMS Version: 1.5.90

You really should upgrade sooner rather than later.

> The problem is I don't have an opennms.conf file (was this changed in
> 1.5.90?) so I don't know where to increase the heap space. Where do  
> I do
> this?

There is no opennms.conf file until you create one.  It can contain  
just the one line:

JAVA_HEAP_SIZE=512

-jeff

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Reply | Threaded
Open this post in threaded view
|

Re: java.lang.OutOfMemoryError: Java heap space

indon.bae
In reply to this post by BryanD
You need to create it under "'$OPENNMS_HOME/etc" directory.

On Tue, Sep 2, 2008 at 6:56 AM, BryanD <[hidden email]> wrote:

I am having the same issue. It started after we added a bunch of new nodes so
I don't doubt that I need to increase the heap space. I am running:
OpenNMS Version: 1.5.90
Java Version: 1.5.0_15 Sun Microsystems Inc.
Java Virtual Machine: 1.5.0_15-b04 Sun Microsystems Inc.
Operating System: Linux 2.6.24-19-server (i386)

The problem is I don't have an opennms.conf file (was this changed in
1.5.90?) so I don't know where to increase the heap space. Where do I do
this?


indon.bae wrote:
>
> All,
>
> Need urgent help!
>
> Our OpenNMS was running well last six months without any issue, but
> suddenly
> I was no longer able to sign on to it via Web browser.
> In order to restart OpenNMS, I tried "opennms stop", but did not worked
> because of errors.
> Only way I can restart the OpenNMS is reloading OS (Fedora Core 6) but few
> hours later, I got same error and I cannot log-on.
>
> The problem seems to me that something is causing an error -
>  "java.lang.OutOfMemoryError: Java heap space."
> Could anyone help me understand what is causing this problem and how to
> remedy this problem?
>
> Copy of few lines from "output.log" file.
> "Executing command: /opt/opennms/bin/runjava -r --
> -Dopennms.home=/opt/opennms -Xmx256m -jar
> /opt/opennms/lib/opennms_bootstrap.jar start
> Exception in thread "Timer-3411" java.util.ConcurrentModificationException
>      at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
>      at org.snmp4j.Snmp.close(Unknown Source)
>      at
> org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
>      at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
>      at
> org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
>      at
> org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
>      at
> org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
> at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)
>
> at java.util.TimerThread.mainLoop(Timer.java:512)
>
> at java.util.TimerThread.run(Timer.java:462)
>
> Exception in thread "Timer-3419" java.util.ConcurrentModificationException
>
> at java.util.Hashtable$Enumerator.next(Hashtable.java:1020)
>
> at org.snmp4j.Snmp.close(Unknown Source)
>
> at
> org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.close(Snmp4JWalker.java:223)
>
> at org.opennms.netmgt.snmp.SnmpWalker.finish(SnmpWalker.java:149)
>
> at org.opennms.netmgt.snmp.SnmpWalker.handleTimeout(SnmpWalker.java:143)
>
> at
> org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker.access$1000(Snmp4JWalker.java:58)
>
> at
> org.opennms.netmgt.snmp.snmp4j.Snmp4JWalker$Snmp4JResponseListener.onResponse(Snmp4JWalker.java:163)
>
> at org.snmp4j.Snmp$PendingRequest.run(Unknown Source)
>
> at java.util.TimerThread.mainLoop(Timer.java:512)
>
> at java.util.TimerThread.run(Timer.java:462)
>
> Your help will be greatly appreciated.
>
> --
> In Don Bae
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the
> world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Please read the OpenNMS Mailing List FAQ:
> http://www.opennms.org/index.php/Mailing_List_FAQ
>
> opennms-discuss mailing list
>
> To *unsubscribe* or change your subscription options, see the bottom of
> this page:
> https://lists.sourceforge.net/lists/listinfo/opennms-discuss
>

--
View this message in context: http://n2.nabble.com/java.lang.OutOfMemoryError%3A-Java-heap-space-tp736272p833983.html
Sent from the OpenNMS - discuss mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss



--
In Don Bae

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss