8.0 hard-crash, can not develop anymore...

Hi,

Serious problem here. IntelliJ-8 crashes hard with the stack trace below and I don't mean that I get a stack trace dialog that I can report,no the whole process just vanishes. I got the stack trace by starting the bat file in bin. This happens consistenty after reading about 88% of my project. I first discovered it on #8995 then I downloaded the final-8 version and still get the same crash. I can not develop anymore.... help.

Circumstances & environment:
Windows XP, 4G machine. I tried the the #9885 as well as the final-8 version as freshly installed, threw away my .IntelliJIdea80\system dir to get rid of cashes. When the problem started it was after a shutdown of my machine while IntelliJ #8995 was running. When starting IntelliJ again it started re-parsing all my file. Around 88%: BANG, gone. I tried it several times, same thing over and over. I checked my disk, tried final 8, nothing seems to work. I must say we have a pretty extensive project (java: 33K files with 2G contents, class: 50k with 700M contents), but I could work before without problems and the amount of files has not increased suddenly. (My eclipse-using-colleagues were jealous because they were experiencing many hangs and delays... so I have to solve this one ;)

Memory is not the problem, heap as well as perm space are healthy.

Any workarounds are welcome...

-Tom

Edited by: Tom Brus on Nov 9, 2008 7:27 AM: StackTrace removed to reduce scrolling time, see JIRA for details

10 comments
Comment actions Permalink

NEWS: I tried an old #8858 build and it starts up just fine!

Conclusion: introduction of some serious bug since that version.

http://www.jetbrains.net/jira/browse/IDEA-20523

-Tom

Edited by: Tom Brus on Nov 8, 2008 10:43 AM

0
Comment actions Permalink

Hello Tom,

Unfortunately you're running into a JDK bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6521677

So it's not something that was introduced by us. We did change the patterns
for accessing memory-mapped files, so it's possible that the old code didn't
trigger the bug and the new one does, but unfortunately there's not much
we can do about it. As a workaround, you can try running IDEA under an older
JDK version (set the IDEA_JDK environment variable to point to an installation
directory of a different JDK).

Serious problem here. IntelliJ-8 crashes hard with the stack trace
below and I don't mean that I get a stack trace dialog that I can
report,no the whole process just vanishes. I got the stack trace by
starting the bat file in bin. This happens consistenty after reading
about 88% of my project. I first discovered it on #8995 then I
downloaded the final-8 version and still get the same crash. I can not
develop anymore.... help.

Circumstances & environment:
Windows XP, 4G machine. I tried the the #9885 as well as the final-8
version as freshly installed, threw away my .IntelliJIdea80\system dir
to get rid of cashes. When the problem started it was after a shutdown
of my machine while IntelliJ #8995 was running. When starting IntelliJ
again it started re-parsing all my file. Around 88%: BANG, gone. I
tried it several times, same thing over and over. I checked my disk,
tried final 8, nothing seems to work. I must say we have a pretty
extensive project with very many files, but I could work before
without problems and the amount of files has not increased suddenly.
(My eclipse-using-colleagues were jealous because they were
experiencing many hangs and delays... so I have to solve this one ;)
Memory is not the problem, heap as well as perm space are healthy.

Any workarounds are welcome...

-Tom

-----
Here is the stack trace:
-----
java.lang.Error: Cleaner terminated abnormally
at sun.misc.Cleaner$1.run(Cleaner.java:130)
at java.security.AccessController.doPrivileged(Native Method)
at sun.misc.Cleaner.clean(Cleaner.java:127)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccess
orImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
com.intellij.util.io.MappedBufferWrapper$1.run(MappedBufferWrapper.jav
a:124)
at java.security.AccessController.doPrivileged(Native Method)
at
com.intellij.util.io.MappedBufferWrapper.clean(MappedBufferWrapper.jav
a:116)
at
com.intellij.util.io.MappedBufferWrapper.unmapMappedByteBuffer142b19(M
appedBufferWrapper.java:107)
at
com.intellij.util.io.MappedBufferWrapper.unmap(MappedBufferWrapper.jav
a:60)
at
com.intellij.util.io.MappedBufferWrapper.dispose(MappedBufferWrapper.j
ava:192)
at
com.intellij.util.io.PagedFileStorage$1.onDropFromCache(PagedFileStora
ge.java:47)
at
com.intellij.util.io.PagedFileStorage$1.onDropFromCache(PagedFileStora
ge.java:35)
at
com.intellij.util.containers.SLRUMap.clear(SLRUMap.java:106)
at
com.intellij.util.io.PagedFileStorage.unmapAll(PagedFileStorage.java:1
57)
at
com.intellij.util.io.PagedFileStorage.resize(PagedFileStorage.java:164
)
at
com.intellij.util.io.ResizeableMappedFile.resize(ResizeableMappedFile.
java:39)
at
com.intellij.util.io.ResizeableMappedFile.expand(ResizeableMappedFile.
java:54)
at
com.intellij.util.io.ResizeableMappedFile.ensureSize(ResizeableMappedF
ile.java:49)
at
com.intellij.util.io.ResizeableMappedFile.put(ResizeableMappedFile.jav
a:152)
at
com.intellij.util.io.PersistentEnumerator.allocVector(PersistentEnumer
ator.java:337)
at
com.intellij.util.io.PersistentEnumerator.enumerateImpl(PersistentEnum
erator.java:302)
at
com.intellij.util.io.PersistentEnumerator.enumerate(PersistentEnumerat
or.java:179)
at
com.intellij.util.io.PersistentHashMap$2.onDropFromCache(PersistentHas
hMap.java:69)
at
com.intellij.util.io.PersistentHashMap$2.onDropFromCache(PersistentHas
hMap.java:61)
at
com.intellij.util.containers.SLRUMap$2.removeEldestEntry(SLRUMap.java:
41)
at
com.intellij.util.containers.hash.LinkedHashMap.put(LinkedHashMap.java
:81)
at com.intellij.util.containers.SLRUMap.put(SLRUMap.java:74)
at
com.intellij.util.containers.SLRUCache.get(SLRUCache.java:24)
at
com.intellij.util.io.PersistentHashMap.appendData(PersistentHashMap.ja
va:157)
at
com.intellij.util.indexing.MapIndexStorage$1.onDropFromCache(MapIndexS
torage.java:25)
at
com.intellij.util.indexing.MapIndexStorage$1.onDropFromCache(MapIndexS
torage.java:23)
at
com.intellij.util.containers.SLRUMap$2.removeEldestEntry(SLRUMap.java:
41)
at
com.intellij.util.containers.hash.LinkedHashMap.put(LinkedHashMap.java
:81)
at com.intellij.util.containers.SLRUMap.put(SLRUMap.java:74)
at
com.intellij.util.indexing.MapIndexStorage$1.put(MapIndexStorage.java:
17)
at
com.intellij.util.indexing.MapIndexStorage$1.put(MapIndexStorage.java:
12)
at
com.intellij.util.containers.SLRUCache.get(SLRUCache.java:24)
at
com.intellij.util.indexing.MapIndexStorage$1.get(MapIndexStorage.java:
22)
at
com.intellij.util.indexing.MapIndexStorage$1.get(MapIndexStorage.java:
7)
at
com.intellij.util.indexing.MapIndexStorage.read(MapIndexStorage.java:4
5)
at
com.intellij.util.indexing.MapIndexStorage.addValue(MapIndexStorage.ja
va:36)
at
com.intellij.util.indexing.MemoryIndexStorage.addValue(MemoryIndexStor
age.java:29)
at
com.intellij.util.indexing.MapReduceIndex.updateWithMap(MapReduceIndex
.java:34)
at
com.intellij.psi.stubs.StubIndexImpl$MyIndex.updateWithMap(StubIndexIm
pl.java:4)
at
com.intellij.psi.stubs.StubIndexImpl.updateIndex(StubIndexImpl.java:47
)
at
com.intellij.psi.stubs.StubUpdatingIndex.a(StubUpdatingIndex.java:54)
at
com.intellij.psi.stubs.StubUpdatingIndex.access$200(StubUpdatingIndex.
java:29)
at
com.intellij.psi.stubs.StubUpdatingIndex$MyIndex.updateWithMap(StubUpd
atingIndex.java:56)
at
com.intellij.util.indexing.MapReduceIndex.update(MapReduceIndex.java:1
2)
at
com.intellij.util.indexing.FileBasedIndex.a(FileBasedIndex.java:112)
at
com.intellij.util.indexing.FileBasedIndex.indexFileContent(FileBasedIn
dex.java:136)
at
com.intellij.util.indexing.UnindexedFilesUpdater.processFile(Unindexed
FilesUpdater.java:27)
at
com.intellij.ide.startup.FileSystemSynchronizer.updateFiles(FileSystem
Synchronizer.java:191)
at
com.intellij.ide.startup.FileSystemSynchronizer.execute(FileSystemSync
hronizer.java:72)
at
com.intellij.ide.startup.impl.StartupManagerImpl$1.run(StartupManagerI
mpl.java:9)
at
com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(Ap
plicationImpl.java:308)
at
com.intellij.ide.startup.impl.StartupManagerImpl.runStartupActivities(
StartupManagerImpl.java:21)
at
com.intellij.openapi.project.impl.ProjectManagerImpl$3.run(ProjectMana
gerImpl.java:3)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl$3.run(ProgressM
anagerImpl.java:1)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl$TaskRunnable.ru
n(ProgressManagerImpl.java:3)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl$4.run(ProgressM
anagerImpl.java:1)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl$2.run(ProgressM
anagerImpl.java:5)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessU
nderProgress(ProgressManagerImpl.java:13)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl.runProcess(Prog
ressManagerImpl.java:101)
at
com.intellij.openapi.application.impl.ApplicationImpl$7$1.run(Applicat
ionImpl.java:9)
at
com.intellij.openapi.application.impl.ApplicationImpl$5.run(Applicatio
nImpl.java:9)
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441
)
at
java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecu
tor.java:885)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.
java:907)
at java.lang.Thread.run(Thread.java:619)
at
com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(Applicat
ionImpl.java:10)
Caused by: java.io.IOException: The process cannot access the file
because another process has locked a portion of the file
at sun.nio.ch.FileChannelImpl.unmap0(Native Method)
at
sun.nio.ch.FileChannelImpl.access$100(FileChannelImpl.java:32)
at
sun.nio.ch.FileChannelImpl$Unmapper.run(FileChannelImpl.java:680)
at sun.misc.Cleaner.clean(Cleaner.java:125)
... 72 more
-----

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0
Comment actions Permalink

Hi Dmitri,

I discovered that already (see the JIRA), and was afraid of the consequences... :(

I'll check out if 8.0 runs with older JDKs, but, since the bug is reported on 1.4.2, going before that is probably no option, right? ;)

I read that it is solved in JDK 7, is that an option to run IntelliJ?

Any chance you are going to revert those changes to the mapping code?

-Tom

0
Comment actions Permalink

Hello Tom,

I discovered that already (see the JIRA), and was afraid of the
consequences... :(

I'll check out if 8.0 runs with older JDKs, but, since the bug is
reported on 1.4.2, going before that is probably no option, right? ;)

I read that it is solved in JDK 7, is that an option to run IntelliJ?


It's not officially supported, but you can try. :)

Any chance you are going to revert those changes to the mapping code?


The changes were done to reduce IDEA's virtual memory usage and avoid running
of virtual address space, so reverting them is undesirable. I'll discuss
with my colleages whether it's possible to make the new logic optional.

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0
Comment actions Permalink

Hi Dmitry,

I read that it is solved in JDK 7, is that an option to run IntelliJ?

It's not officially supported, but you can try. :)

I'll post the result to the forum as soon as I tried JDK7...

The changes were done to reduce IDEA's virtual memory usage and avoid running
of virtual address space, so reverting them is undesirable. I'll discuss
with my colleages whether it's possible to make the new logic optional.

Wow, that would be great!

By the way, am I the only one experiencing this?
Is it a matter of luck or is it the size of our project?
If it is luck, I would gladly spend an evening starting IntelliJ until it succeeds. I have a feeliing that it is only the filling of the cashes that is sensible to this bug. (Correct me if wrong ;)

Appreciate your effort (and developing IntelliJ in general :).

-Tom

0
Comment actions Permalink

JDK 7 can not be used to run IntelliJ: a dialog box says:

Java Version Mismatch
The JDK version is 1.7.0-ea
IDEA requires JDK 1.5 or 1.6


Is there some switch to circumvent this dialog?

-Tom

0
Comment actions Permalink

Dmitry,

I am getting a crash in 8.0 where IDEA crashes after the project build is completed. Here is the stacktrace:

bash-3.2$ /Applications/IntelliJ\ IDEA\ 8.0.app/Contents/MacOS/idea
NSRuntime.loadLibrary(/usr/lib/java/libObjCJava.dylib) error.
java.lang.UnsatisfiedLinkError: /usr/lib/java/libObjCJava.A.dylib:
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1822)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1702)
at java.lang.Runtime.load0(Runtime.java:769)
at java.lang.System.load(System.java:968)
at com.apple.cocoa.foundation.NSRuntime.loadLibrary(NSRuntime.java:127)
at com.apple.cocoa.foundation.NSRuntime.(NSRuntime.java:35) at com.apple.cocoa.foundation.NSObject.(NSObject.java:27) at com.intellij.ui.GrowlNotifications.(GrowlNotifications.java:9) at com.intellij.ui.GrowlNotifications.]]>(GrowlNotifications.java:24)
at com.intellij.ui.GrowlNotifications.getNofications(GrowlNotifications.java:10)
at com.intellij.ui.SystemNotificationsImpl.notify(SystemNotificationsImpl.java:3)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.a(ProgressManagerImpl.java:35)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.access$100(ProgressManagerImpl.java:27)
at com.intellij.openapi.progress.impl.ProgressManagerImpl$6.run(ProgressManagerImpl.java:11)
at com.intellij.openapi.application.impl.ApplicationImpl$5.run(ApplicationImpl.java:2)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
at java.util.concurrent.FutureTask.run(FutureTask.java:123)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:613)
at com.intellij.openapi.application.impl.ApplicationImpl$1$1.run(ApplicationImpl.java:10)

Can you tell me what the problem is?

Thanks

-Reggie

0
Comment actions Permalink

I remember there's a command line parameter to pass to IDEA so it doesn't check jdk version ... at least there was one with 7.0.
Can't remember the spelling though :(

0
Comment actions Permalink

Reggie, this stacktrace is not related to the one that is subject of this topic. Better start a new topic for your crash to keep things organized and easier to find. The Jetbrains people are watching this forum thoroughly, so don't be affraid your message is ignored.
Thanks, Tom

0
Comment actions Permalink

Add idea.no.jdk.check=true to idea.properties to run it in JDK 7. I tested it with an earlier build and it seemed to work fine.

http://blogs.jetbrains.com/idea/2006/08/running-mustang/ for an earlier version of Idea and JDK 6.

0

Please sign in to leave a comment.