-
Bug
-
Resolution: Fixed
-
P4
-
9, 11, 12, 13
-
b03
-
x86_64
-
windows
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8220168 | 12.0.2 | Harold Seigel | P4 | Resolved | Fixed | b01 |
JDK-8219234 | 11.0.4-oracle | Harold Seigel | P4 | Resolved | Fixed | b02 |
JDK-8220033 | 11.0.4 | Harold Seigel | P4 | Resolved | Fixed | b01 |
JDK-8221947 | 11.0.3-oracle | Harold Seigel | P4 | Resolved | Fixed | b31 |
JDK-8221426 | 11.0.2 | Harold Seigel | P4 | Closed | Fixed | b31 |
Microsoft Windows 10 Pro (version 1803, OS version 17134.471)
OpenJDK 11.0.1 (2018-10-16), JRE 18.9 (build 11.0.1+13)
A DESCRIPTION OF THE PROBLEM :
Option -Xlog does not support Windows absolute paths, namely:
1) OK : -Xlog:class+load:file=app_cds.log
2) KO : -Xlog:class+load:file=c:\temp\app_cds.log
3) OK: -Xlog:class+load:file=\temp\app_cds.log (<== drive C: is assumed here !)
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
C:\temp> javac HelloWorld.java
C:\temp> jar cf app.jar -C . HelloWorld.class
C:\temp> java -XX:DumpLoadedClassList=C:\temp\classlist.txt -classpath app.jar HelloWorld
C:\temp> java -XX:SharedClassListFile=C:\temp\classlist.txt -XX:SharedArchiveFile=c:\temp\app_cds.jsa -Xshare:dump -classpath app.jar
C:\temp>
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
C:\temp> java.exe -Xshare:on -Xlog:class+load:file=app_cds.log -XX:SharedArchiveFile=c:\temp\app_cds.jsa -classpath app.jar HelloWorld
Hello world!
ACTUAL -
C:\temp> java -Xshare:on -Xlog:class+load:file=c:\temp\app_cds.log -XX:SharedArchiveFile=c:\temp\app_cds.jsa -classpath app.jar HelloWorld
[0.003s][error][logging] Invalid decorator '\temp\app_cds.log'.
Invalid -Xlog option '-Xlog:class+load:file=c:\temp\app_cds.log', see error log for details.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
---------- BEGIN SOURCE ----------
// File C:\temp\HelloWorld.java
public class HelloWorld {
public static void main(String... args) {
System.out.println("Hello world!");
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
*** simply omit the drive letter "C:" ***
C:\temp> java -Xshare:on -Xlog:class+load:file=\temp\app_cds.log -XX:SharedArchiveFile=c:\temp\app_cds.jsa -classpath app.jar HelloWorld
Hello world!
FREQUENCY : always
- backported by
-
JDK-8219234 -Xlog option usage => Invalid decorator '\temp\app_cds.log'.
- Resolved
-
JDK-8220033 -Xlog option usage => Invalid decorator '\temp\app_cds.log'.
- Resolved
-
JDK-8220168 -Xlog option usage => Invalid decorator '\temp\app_cds.log'.
- Resolved
-
JDK-8221947 -Xlog option usage => Invalid decorator '\temp\app_cds.log'.
- Resolved
-
JDK-8221426 -Xlog option usage => Invalid decorator '\temp\app_cds.log'.
- Closed
- relates to
-
JDK-8268542 serviceability/logging/TestFullNames.java tests only 1st test case
- Resolved
-
JDK-8225049 Bad -Xlog example in -Xlog:help, online documentation, JEP
- Resolved