Skip to content

faq 73891947

Billy Charlton edited this page Sep 5, 2018 · 2 revisions

My MATSim run freezes. What can I do?

by Kai Nagel on 2016-07-18 14:55:33


(kai proxying from johan)

My setup:
- I ran a 10% simulation of Cape Town on my (linux) server (using 40 threads), starting the job through screen. Few hours later… job is just “dead”… and it always dies during the mobility simulation. The job shows in ‘top’, but nothing is going on. No error messages, nothing.
… so I though maybe my ‘screen’ multiplexer is buggered, tried restarting the job through ‘nohup … &’ 
Same problem. I then brought in the help of one of my colleagues who assisted in us hooking up (through GNU Debugger gdb) to the Java virtual machine, and tracing back. It seems the job is hanging, waiting for “something”. An excerpt of the traceback is attached.
It seems the “joining” of threads are in some dead-lock… which brings me back to the original issue: it seems something went wrong with the recent code changes. Maybe I’m doing something wrong, but from what I can see it seems to be a bit deeper. UnfortunatelyI do not have a specific Java code profiler/debugger through which I can run the job to see the exact stack trace.
But I thought you may want to be aware of it. I’ll restart the job with the LATEST build, but the error was with a build from yesterday morning ((=17/feb/2016))

Job 30245

#0 0x00007fa9c065766b in pthread_join (threadid=140367066609408, thread_return=thread_return@entry=0x7ffea97e5e28)
at pthread_join.c:92
#1 0x00007fa9c0e3ea35 in ContinueInNewThread0 (continuation=continuation@entry=0x7fa9c0e37ac0 <JavaMain>, stack_size=1048576,
args=args@entry=0x7ffea97e5ec0) at ../../../src/solaris/bin/java_md_solinux.c:1056
#2 0x00007fa9c0e394f7 in ContinueInNewThread (ifn=ifn@entry=0x7ffea97e5fc0, threadStackSize=<optimized out>, argc=<optimized out>,
argv=0x1d41348, mode=mode@entry=0, what=what@entry=0x0, ret=0) at ../../../src/share/bin/java.c:1870
#3 0x00007fa9c0e3eafb in JVMInit (ifn=ifn@entry=0x7ffea97e5fc0, threadStackSize=<optimized out>, argc=<optimized out>,
argv=<optimized out>, mode=0, mode@entry=1, what=0x0,
what@entry=0x7ffea97ea803 "playground.southafrica.population.census2011.capeTown.CapeTownControler", ret=ret@entry=0)
at ../../../src/solaris/bin/java_md_solinux.c:1092
#4 0x00007fa9c0e3a044 in JLI_Launch (argc=3, argv=0x1d41348, jargc=jargc@entry=1, jargv=jargv@entry=0x0, appclassc=appclassc@entry=1,
appclassv=appclassv@entry=0x0, fullversion=fullversion@entry=0x40083d "1.7.0_95-b00", dotversion=dotversion@entry=0x400839 "1.7",
pname=pname@entry=0x400834 "java", lname=lname@entry=0x400834 "java", javaargs=javaargs@entry=0 '\000',
cpwildcard=cpwildcard@entry=1 '\001', javaw=javaw@entry=0 '\000', ergo=ergo@entry=0) at ../../../src/share/bin/java.c:295
#5 0x00000000004006b5 in main (argc=<optimized out>, argv=<optimized out>) at ../../../../src/share/bin/main.c:125


Comments: 1


Re: My MATSim run freezes. What can I do?

by Kai Nagel on 2016-07-18 14:55:49

I think that in this case this got resolved by switching the multi-threaded mobsim from

		<param name="usingThreadpool" value="true" />

to

		<param name="usingThreadpool" value="false" />

The technical reason for this is absolutely unclear, but the version with "false" has been used a lot more.

Clone this wiki locally