Wednesday, April 21, 2010

java.io.IOException: Cannot run program CreateProcess error=87, The parameter is incorrect

Problem:
Recently we observed our ant scripts are failing to fork a JVM process and they are failing with error “CreateProcess error=87, The parameter is incorrect"”

Solution:
Please reduce the classpath size for the javac/java

Root Cause:
In windows operating system if the arguments to process is too long . The process cannot be launched by the Operating system, In our case while ant forks the java/javac process and provides the classpath as argument . The classpath size exceeds the maximum size OS can handle. The solution for this problem is to reduce classpath. (i.e) reducing the size of arguments to process.

GWT compiler fails with Bad class version

Solution: This might happen because of incorrect version of Javac used by the GWTcompiler or the incorrect version of the jar files in project space.

We observed ant in netbeans is using the default JVM of the netbeans ide instead of JVM set for the project. Please change the default JDK used by neatbeans by changing netbeans.conf file.

For more info please refer http://wiki.netbeans.org/FaqJdkHome

Regards
Balaji

Followers