Always OffLine..

asiLab2 years ago

Hello,
even if in my console I've an accepted device producing Position objects:

2022-06-16 02:11:21  INFO: [T2b5e7e50] id: 35265309015168, time: 2022-06-16 00:11:21, lat: 41.02478, lon: 14.49674, course: 0.0, accuracy: 1.0

On my Web interface i continue to see device "offline".
Maybe (for sure) I'm doing something wrong...

Any help appreciated...

Gian

Anton Tananaev2 years ago

What device are you using? Is it disconnecting after sending the data?

Would be nice to see larger log fragment from connected to disconnected messages.

asiLab2 years ago

Dear Anton,
first.. thanks for your help.

Device is our company device and we are implementing protocol. The device stay on same socket for all the time, it disconnects just when no more moving. Here is a larger log trace:

2022-06-16 02:43:40  INFO: [T97af89c8] connected
2022-06-16 02:43:41  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343334313a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31373a303a303a6770733a33303e
2022-06-16 02:43:41  INFO: [T97af89c8: asi > 192.168.1.1] 47505253204143544956450d0a
RCVD:<R:16062022004341:41.024872:14.496579:0:130:35:21:17:0:0:gps:30>
2022-06-16 02:43:42  INFO: [T97af89c8: asi < 192.168.1.1] 3c2341473a33353236353330393031353136383e0a
2022-06-16 02:43:42  INFO: [T97af89c8: asi > 192.168.1.1] 47505253204143544956450d0a
RCVD:<#AG:35265309015168>
2022-06-16 02:43:43  INFO: [T97af89c8: asi < 192.168.1.1] 3c2341473a33353236353330393031353136383e0a
RCVD:
<#AG:35265309015168>
2022-06-16 02:43:43  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343334333a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31373a303a303a6770733a33303e
2022-06-16 02:43:43  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:43, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:
<R:16062022004343:41.024872:14.496579:0:130:35:21:17:0:0:gps:30>
Match found:<R:16062022004343:41.024872:14.496579:0:130:35:21:17:0:0:gps:30>
2022-06-16 02:43:44  INFO: [T97af89c8: asi < 192.168.1.1] 3c50494e473e0a
2022-06-16 02:43:44  INFO: [T97af89c8: asi > 192.168.1.1] 3c504f4e473e0a
RCVD:<PING>
2022-06-16 02:43:45  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343334353a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31353a303a303a6770733a33303e
2022-06-16 02:43:45  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:45, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:
<R:16062022004345:41.024872:14.496579:0:130:35:21:15:0:0:gps:30>
Match found:<R:16062022004345:41.024872:14.496579:0:130:35:21:15:0:0:gps:30>
2022-06-16 02:43:47  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343334373a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31333a303a313a6770733a33303e
2022-06-16 02:43:47  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:47, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:<R:16062022004347:41.024872:14.496579:0:130:35:21:13:0:1:gps:30>
Match found:<R:16062022004347:41.024872:14.496579:0:130:35:21:13:0:1:gps:30>
2022-06-16 02:43:49  INFO: [T97af89c8: asi < 192.168.1.1] 3c50494e473e0a
2022-06-16 02:43:49  INFO: [T97af89c8: asi > 192.168.1.1] 3c504f4e473e0a
RCVD:<PING>
2022-06-16 02:43:49  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343334393a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31333a303a313a6770733a33303e
2022-06-16 02:43:49  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:49, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:
<R:16062022004349:41.024872:14.496579:0:130:35:21:13:0:1:gps:30>
Match found:<R:16062022004349:41.024872:14.496579:0:130:35:21:13:0:1:gps:30>
2022-06-16 02:43:51  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343335313a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31323a303a313a6770733a33303e
2022-06-16 02:43:51  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:51, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:<R:16062022004351:41.024872:14.496579:0:130:35:21:12:0:1:gps:30>
Match found:<R:16062022004351:41.024872:14.496579:0:130:35:21:12:0:1:gps:30>
2022-06-16 02:43:53  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343335333a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31343a303a303a6770733a33303e
2022-06-16 02:43:53  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:53, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:<R:16062022004353:41.024872:14.496579:0:130:35:21:14:0:0:gps:30>
Match found:<R:16062022004353:41.024872:14.496579:0:130:35:21:14:0:0:gps:30>
2022-06-16 02:43:54  INFO: [T97af89c8: asi < 192.168.1.1] 3c50494e473e0a
2022-06-16 02:43:54  INFO: [T97af89c8: asi > 192.168.1.1] 3c504f4e473e0a
RCVD:<PING>
2022-06-16 02:43:55  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343335353a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31343a303a303a6770733a33303e
2022-06-16 02:43:55  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:55, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
RCVD:
<R:16062022004355:41.024872:14.496579:0:130:35:21:14:0:0:gps:30>
Match found:<R:16062022004355:41.024872:14.496579:0:130:35:21:14:0:0:gps:30>
2022-06-16 02:43:57  INFO: [T97af89c8: asi < 192.168.1.1] 3c523a31363036323032323030343335373a34312e3032343837323a31342e3439363537393a303a3133303a33353a32313a31333a303a303a6770733a33303e
RCVD:<R:16062022004357:41.024872:14.496579:0:130:35:21:13:0:0:gps:30>
Match found:<R:16062022004357:41.024872:14.496579:0:130:35:21:13:0:0:gps:30>
2022-06-16 02:43:57  INFO: [T97af89c8] id: 35265309015168, time: 2022-06-16 00:43:57, lat: 41.02487, lon: 14.49658, course: 0.0, accuracy: 1.0
2022-06-16 02:43:59  INFO: [T97af89c8: asi < 192.168.1.1] 3c50494e473e0a
2022-06-16 02:43:59  INFO: [T97af89c8: asi > 192.168.1.1] 3c504f4e473e0a
RCVD:<PING>
2022-06-16 02:43:59  INFO: [T97af89c8: asi < 192.168.1.1] 

Match found:<R:16062022004507:41.024872:14.496576:0:130:35:19:12:0:1:gps:30>
2022-06-16 02:45:09  INFO: [T97af89c8: asi < 192.168.1.1] 3c50494e473e0a
2022-06-16 02:45:09  INFO: [T97af89c8: asi > 192.168.1.1] 3c504f4e473e0a
RCVD:<PING>
2022-06-16 02:45:09  INFO: [T97af89c8] disconnected
Anton Tananaev2 years ago

Looks fine. I guess you need to debug the code to understand what's not working correctly.

asiLab2 years ago

Yes.. I'm looking in ConnectionManager to control correct states changes at moment... I will update if i find a solution.

Thanks.
Gian

asiLab2 years ago

As suspected also here everything ok I added a log in ConnectionManager :

System.out.println("Device state from:" + oldStatus + " to:" + status)

here we are... it seems that web wont reflect same things..

Device state from:offline to:online
2022-06-16 02:57:23  INFO: [T010e249f: asi < 192.168.1.1] 3c2341473a33353236353330393031353136383e0a
Device state from:online to:online
2022-06-16 02:57:23  INFO: [T010e249f: asi < 192.168.1.1] 3c523a31363036323032323030353732333a34312e3032343833303a31342e3439363632303a303a3132383a33333a32313a31373a303a303a6770733a33303e
2022-06-16 02:57:23  INFO: [T010e249f] id: 35265309015168, time: 2022-06-16 00:57:23, lat: 41.02483, lon: 14.49662, course: 0.0, accuracy: 1.0
Device state from:online to:online
2022-06-16 02:57:24  INFO: [T010e249f: asi < 192.168.1.1] 3c50494e473e0a
2022-06-16 02:57:24  INFO: [T010e249f: asi > 192.168.1.1] 3c504f4e473e0a
Device state from:online to:online
2022-06-16 02:59:03  INFO: [T010e249f] disconnected
Device state is:offline
Device state from:online to:offline
asiLab2 years ago

Solved. Admin user (default at installation) doesnt receives updates. Any other user created later with same device assigned receives updates.

Thanks.

Vishala year ago

Hello

I am using a GV75 device that appears to be offline all time. No logs at all related to this. I'm adding some if that works for troubleshooting.

device: gv75
traccar version: 4.11
Traccar Running on HTTPS and forwarded 8082 port using IPTABLE

2022-12-22 13:45:29  INFO: user: 1, action: create, object: device, id: 2
2022-12-22 13:45:29  INFO: user: 1, action: link, owner: user, id: 1, property: device, id: 2
2022-12-22 13:56:59  INFO: user: 1, action: login
2022-12-22 14:09:00  INFO: user: 1, action: create, object: device, id: 3
2022-12-22 14:09:00  INFO: user: 1, action: link, owner: user, id: 1, property: device, id: 3
2022-12-22 14:09:39  INFO: [0df09c00] connected 

Any help appreciated
Vishal

Anton Tananaeva year ago

You should probably create another forum thread. Also make sure you do troubleshooting first and provide us with results.