对于Oracle implementation of Java 8对于 Mac OS X(以及 Linux 和 Windows),tz
time zone database 在哪里物理存储在 JDK/JRE 中?
我想找到实际的文件进行检查。
我在装有 El Capitan 的 Mac 上找到了 /Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk
中的 JVM。但是我细读了它的内容并没有发现任何我能识别的“tz”文件。
最佳答案
在 Java 8 中,tz 文件是
jre/lib/tzdb.dat
另见 Timezone Updater Tool .这在某种程度上说,
For JDK 8 and later family versions:
- Locate the
'tzdb.dat'
file under the modified JAVAHOME/jre/lib directory. This is the newer data file.- Locate the
'tzdb.dat.<oldtzdataversion>'
; file in the same JAVAHOME/jre/lib directory. This is the replaced, older data file.- Obtain the currently installed timezone data version from the command
java -jar tzupdater.jar -V
.- Rename the current
'tzdb.dat'
file to something like'tzdb.dat.<newtzdataversion>'
, or whatever version was given by the command in step 3. Ensure this name does not conflict with the older data files.- Rename the older data file to
'tzdb.dat'
.- Validate the change in currently active timezone data by executing
java -jar tzupdater.jar -V
.- Restart applications on this JDK/JRE instance as desired.
关于java - Java 8 的 Oracle JVM 中物理存储的 'tz' 时区数据库在哪里?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37534584/