Status Offline

Karl Woods5 years ago

Evening Ladies, and Gents,

I've got my motorcycle tracker and my phone tracker both reporting on own installation.
I have the following information in my configuration file:

<entry key='server.timeout'>3900</entry>
<entry key='status.timeout'>3900</entry>
<entry key='teltonika.timeout'>3900</entry>
<entry key='osmand.timeout'>3900</entry>
<entry key='filter.zero'>true</entry>
<entry key='filter.invalid'>true</entry>

My phone shows as online constantly, (both phone and teltonika tracker are set to update once an hour if no movement is detected) however after five or so minutes my motorcycle tracker shows as offline. - Could someone point me in the right direction to resolve this, please?

Many thanks.

Anton Tananaev5 years ago

Very simple. Offline status means that your device disconnects from the server.

Karl Woods5 years ago

is there a way of changing that? or will it just say offline after each update?

Anton Tananaev5 years ago

That's something you need to ask your device vendor. Some devices are configurable.

Karl Woods5 years ago

OK thank you. I'll have to look into this, the device seems very heavily configurable, it's a teltonika FMB900.
I have a couple more questions if you don't mind.

  1. the first update my motorcycle sent was 0,0 so traccar thinks I've three and half thousand miles today, I ran the commands
delete from tc_events where servertime < DATE(NOW() - INTERVAL 1 HOUR);
delete from tc_positions where servertime < DATE(NOW() - INTERVAL 1 HOUR);
delete from tc_statistics where capturetime < DATE(NOW() - INTERVAL 1 HOUR);

to purge the original event, but the milage hasn't changed.

  1. if I access my local instance via the IP and port everything is fine, but I have it behind a Letsencrypt Ngynx Reverse proxy and every few minutes I get a WebSocket issue: "Error: Web socket connection error. "

my reverse proxy settings are as follows:

server {
    listen 443 ssl;
    listen [::]:443 ssl;

    server_name traccar.*;

    include /config/nginx/ssl.conf;

    client_max_body_size 0;

    location / {

        include /config/nginx/proxy.conf;
        proxy_pass http://192.168.12.227:8082;
        proxy_redirect http://192.168.12.227:8082/ /;
        proxy_redirect ws://192.168.12.227:8082/api/socket /api/socket;
    }
}
  1. Did you write the integration into HomeAssistant? It would be great to be able to monitor the voltage of motorcycle in HA and perform an automation based on this. I see that traccar can tell me what the voltage is, so it is being sent from the tracker...

Thank you so much for taking the time to read this.

Anton Tananaev5 years ago
  1. Restart.
  2. Read about proxying WebSocket connection.
  3. No.
Karl Woods5 years ago

Thanks.

I took a look at the configuration on my tracker and the timeout is on there, so that has been changed. Thanks. Just looking at proxying. I'm sure I had restarted, but never mind. Worst case scenario, I kill the existing database and setup another.

Anders Yuran5 years ago

I dont know how nginx do it but enabling mod_wstunnel in apache solv the websocket error for me

Anders Yuran5 years ago