0
Not a bug
ubooquity time 1 hour behinde
I am using ubooquity on a Synology NAS. I see that the time in the log files is 1 hour behind the NAS system time. Do more users have this issue?
Customer support service by UserEcho
Any additional info/ideas are welcome as for know I don't see where the problem could come from.
But unless this oddity it has other unexpected side effects, the problem is not really worth investigating (I have never been able to reproduce it on my side).
https://docs.oracle.com/javase/8/docs/technotes/guides/troubleshoot/time-zone002.html
It is a pain when trying to troubleshoot and correlate a log entry with an event, or other system logs, so it is useful to have it set (for me). According to the article we need to use the -Duser.timezone. I will test it and report back.
8.2.5 Check -Duser.timezone System Property
You can explicitly set a default time zone on the command line by using the Java system property called
user.timezone
. This bypasses the settings in the Windows operating system and can be a workaround in some cases. For instance, this setting is useful if you want DST (daylight saving time) only for a single Java program running on the system.The following example examines the system property -Duser.timezone by running a Java program called DefaultTimeTestZone from the Windows Command Prompt window.
c:\tztest> java -Duser.timezone=America/New_York DefaultTimeZone
America/New_York
If setting a default time zone explicitly by specifying
-Duser.timezone
works for theDefaultTimeTestZone
program, but does not work for your program, you should check whether your code overwrites the default Java time zone during runtime, with a method call such as this:24691 admin 101480 S /share/HDA_DATA/.qpkg/QJDK8/bin/java -Duser.timezone=America/New_York -jar Ubooquity.jar -webadmin -headless
The time in the logs is now matched with system time. I do not know how it will handle DST, I will research that when the time comes up (pun intended). I am still looking for a list of TZs that JAVA will accept to see if there are any DSTs in there. The tzmappings file referrenced in the article does not exist on my system. There is a tzdb.dat, but it is not a flat file, so nothing that I can pull from it. For now I am good though.
For the other QNAP user, let me know if you want me to post my updated UbooQuity.sh file (updated for timezone, EST, and to use QJDK8).
If the city you specify uses DST (I've heard NYC does ;)), Java will automatically change time twice a year.
because I am not enough familiar with server management, it would be great if you could post your modified .sh file and how to use QJDK8.
** For QNAP systems only, and make sure to have the correct QJDK package installed **
EDIT: All formatting/tabs were lost. Sorry for the bad formatting :(. Not sure if I can attach the .sh file directly here or not.
[code]
#!/bin/sh
Incidentally, it also works with QJDK7. First I have only deactivated the QJDK7 and actived the QJDK8. But after a restart of Ubooquity Server I got errors in the log file. After that I tried the changed UbooQuity.sh file with QJDK7 and int works fine. After that I changed back to QJDK8 and made a Restart of my QNAP NAS. Now it works fine with QJDK8.
The topic of DST I solved in this way:
$JAVA -Duser.timezone=Etc/GMT-2 -jar Ubooquity.jar -webadmin -headless &
When we change to normal time, I change the entry manually to "Etc/GMT-1".
Thank you very much!
Good to know that the timezone parameter works on both JDK packages for our QNAP's. As a side note, I didn't change to QJDK8 because of the timezone issue, I did it because I was having some issues with Ubooquity crashing (not a lot in the logs, it would just stop responding and eventually restart itself). I am hoping that JDK8 will be more stable. I also started running out of memory and swapping, I have a new memory stick sitting here to upgrade my NAS. Hopefully the combination of those two "upgrades" will be the solution :)