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.

No comments:

Post a Comment

Followers