As usual I first test update no my home test server prior to update traccar on the production line and this time all went bad.
I already had issues on my test server but it was because of external reasons. Since then I forgot about even updating, just stood testing it to be sure there's nothing odd.
Now I updated my main server, start traccar and nothing happens, HTOP shows traccar trying to start but just goes down almost immediately.
Log is not created and nothing is shown on screen.
Only when trying to start traccar manually (java -jar, etc, etc...) I see some message and It left me thinking a LOT because I tought java came with traccar, so It should be the same version it was compiled with...
This is the error:
/opt/traccar# java -jar tracker-server.jar conf/traccar.mxl
Error: A JNI error has occurred, please check your installation and try again
Exception in thread "main" java.lang.UnsupportedClassVersionError: org/traccar/Main has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
The most concerning is that my test server never gave me those messages.
You have to upgrade the Java version on your server. The error message is fairly clear.
And yet, more odd behavior... It started on is own...
I didn't update java on the server.... is not even installed. Is using java version that comes with traccar.
It's not odd. Traccar comes with its own Java version, which is obviously compatible. So when you run with your outdated Java it doesn't work, but when it uses its own it works.
I don't think you actually read what I wrote.
- Server has no java installed, the only java is the one that comes with traccar.
- It didn't start with "service traccar start" didn't made log, didn't tell anything on screen.
- I wrote the start command by keyboard instead of allowing the /etc/systemd file to start traccar (the exact same statement) which gave the screen error, while the systemd file said nothing.
- It started on its own, (there's a 10s retry on a js file)
- No java update whatsoever, no java install whatsoever........................... and yet it didn't gave the error, and yet it started.
I think there may be some kind of memory leak, be it java/jre related or whatever, but the only thing I can think of is some memory variable/value still allocated even after stopping traccar and deleting it's folder to install 4.15, and starting 4.15 on it's own folder...
If you don't have java installed on the server, your command will fail with the something like "Command 'java' not found".
Variables are declared by traccar start command on systemd, so after it's executed once, there's no more need to declare environment stuff.
That's why I think it may be related to some sort of leak, memory leak or alike.
As usual I first test update no my home test server prior to update traccar on the production line and this time all went bad.
I already had issues on my test server but it was because of external reasons. Since then I forgot about even updating, just stood testing it to be sure there's nothing odd.
Now I updated my main server, start traccar and nothing happens, HTOP shows traccar trying to start but just goes down almost immediately.
Log is not created and nothing is shown on screen.
Only when trying to start traccar manually (java -jar, etc, etc...) I see some message and It left me thinking a LOT because I tought java came with traccar, so It should be the same version it was compiled with...
This is the error:
The most concerning is that my test server never gave me those messages.