Can't get client to communicate with server

LostAndConfused 3 days ago

I installed the latest version on a RPI as my server. I used Port Check to verify port 5055 is open on my router. I reinstalled Traccar on my phone. I use DynDNS, so I used that as the address for my server. On my client, I have Continuous tracking turned on. When I select Send location, using Show status I can see where it gets my location. It is apparently an old location. It returns LocationResult: 11 (217874ms old). Then I get HTTP POST: <a hex string with a date and time. Then it locks 1 record, which I assume is this being logged somewhere. The final line is DEBUG [b0 first]. This looks like the client is sending properly (I hope).

On the server, I go into the log. I get the following:

2026-02-10 07:00:00  INFO: [T80503aa9] connected
2026-02-10 07:00:01  INFO: [Tf849b6c2] connected
2026-02-10 07:00:01  INFO: [Tf849b6c2: g1rus < 117.143.17.251] 13426974546f7272656e7420>
2026-02-10 07:00:01  WARN: Unknown device - 8382447343779540596 (117.143.17.251)
2026-02-10 07:00:03  INFO: [T80503aa9: radar < 185.247.137.34] 300c02010160070201030400>
2026-02-10 07:00:03  WARN: [T80503aa9] error - Adjusted frame length exceeds 1024: 3276>
2026-02-10 07:00:03  INFO: [T80503aa9] disconnected
2026-02-10 07:00:03  INFO: [Tc916d15a] connected
2026-02-10 07:00:03  INFO: [Tc916d15a: radar < 185.247.137.34] 301d02010177188016312e33>
2026-02-10 07:00:03  WARN: [Tc916d15a] error - Adjusted frame length exceeds 1024: 1183>
2026-02-10 07:00:03  INFO: [Tc916d15a] disconnected
2026-02-10 07:00:12  WARN: [Tf849b6c2] error - Connection reset - SocketException (...)
2026-02-10 07:00:12  INFO: [Tf849b6c2] disconnected
2026-02-10 07:00:15  INFO: [Tf05b2ec2] connected
2026-02-10 07:00:18  INFO: [Tf05b2ec2: radar < 185.247.137.10] <?xml version='1.0'?><st>
2026-02-10 07:00:18  WARN: [Tf05b2ec2] error - Adjusted frame length exceeds 1024: 2822>
2026-02-10 07:00:18  INFO: [Tf05b2ec2] disconnected
2026-02-10 07:00:30  INFO: [Tb1414723] connected

Granted, I don't know what I'm looking at. However, I don't know what the IP addresses are (they don't match my phone or my ISP. I've triple-checked that the identifiers match. The end result is the server says my cell phone is offline. What am I missing?

Anton Tananaev 3 days ago

The logs that you should is probably just noise unrelated to the app.

LostAndConfused 3 days ago

So are you saying my server isn't getting the data from my client?

Anton Tananaev 3 days ago

Yes. Either the client is not sending or there's some issue in between.

AussieTraccar 3 days ago

To remove some of the noise from the logs, just enable only the protocols you need. For the Traccar Client, it uses the Osmand protocol (I think it is enabled regardless) so use the .XML configuration option to disable the others you are not using:

<entry key='protocols.enable'>osmand</entry>

You can do a very basic connectivity test from your web browser, by browsing to http://{your_dymanic_dns}:5055 and this should yield something like the following in your logs:

2026-02-11 00:00:00  INFO: [T129b1f6c: osmand < 111.222.333.444] GET / HTTP/1.1\r\nHost: 111.222.333.444\r\nConnection: close\r\nAccept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8\r\nSec-GPC: 1\r\nAccept-Language: en-US,en;q=0.5\r\nSec-Fetch-Site: none\r\nSec-Fetch-Mode: navigate\r\nSec-Fetch-User: ?1\r\nSec-Fetch-Dest: document\r\nAccept-Encoding: gzip, deflate, br\r\n
2026-02-11 00:00:00  INFO: [T129b1f6c: osmand > 111.222.333.444] HTTP/1.1 400 Bad Request\r\ncontent-length: 0\r\n\r\n

Another thing you could possibly do, is to have the port forwarded/opened to the Traccar Manager web UI port at 8082? If you can browse this port, then you can specify this port for the Traccar Client for testing e.g. http://{your_dymanic_dns}:8082

LostAndConfused 3 days ago

I can browse 8082 using my dynamic DNS. I get the following when I use 5055:

2026-02-10 19:23:13  INFO: [T79754586: osmand < 192.168.0.1] GET / HTTP/1.1\r\nHost: jeffreamartin.from-fl.com:5055\r\nConnection: keep-alive\r\nUpgrade-Insecure-Requests: 1\>
2026-02-10 19:23:13  INFO: [T79754586: osmand > 192.168.0.1] HTTP/1.1 400 Bad Request\r\ncontent-length: 0\r\n\r\n

So I should be getting data. However, it might be related to my other issue with getting a token. I keep getting a java error when I try to get a token. You asked what database I'm using. I didn't install anything extra other than your zip file.

Anton Tananaev 3 days ago

Your text editor cut the line there.

LostAndConfused 3 days ago

Yeah, in the text editor it's all one line, but my screen is smaller than the line is long.

Anton Tananaev 3 days ago

I'm saying that you have not copied the whole line.

AussieTraccar 3 days ago

So if your Traccar Client is POSTing correctly to your http://{your_dymanic_dns}:5055 then you should see the corresponding log entry.

iOS Example:

2026-02-11 00:00:00  INFO: [T64a62219: osmand < 111.222.333.444] POST / HTTP/1.1\r\nAccept: */*\r\nUser-Agent: traccar_client/119 CFNetwork/1568.200.51 Darwin/24.1.0\r\n ...

Android Example:

2026-02-11 15:38:47  INFO: [T64a62219: osmand < 111.222.333.444] POST / HTTP/1.1\r\nHost: traccar.example.com\r\nConnection: close\r\nContent-Length: 428\r\nContent-Type: application/json; charset=utf-8\r\nAccept-Encoding: gzip\r\nUser-Agent: okhttp/4.12.0\r\n\r\n ... 

If something is mis-configured relating to the client/device, then you see an "Unknown" device warning in the logs, with the corresponding configured Traccar Client "id":

2026-02-11 00:00:00  INFO: [T64a62219] connected
2026-02-11 00:00:00  INFO: [T64a62219: osmand < 111.222.333.444] POST / HTTP/1.1\r\nHost: traccar.example.com\r\nConnection: close\r\nContent-Length: 426\r\nContent-Type: application/json; charset=utf-8\r\nAccept-Encoding: gzip\r\nUser-Agent: okhttp/4.12.0\r\n\r\n ...
... "device_id":"1234567890"}
2026-02-11 00:00:00  WARN: Unknown device - 1234567890 (111.222.333.444)
2026-02-11 00:00:00  INFO: [T64a62219: osmand > 111.222.333.444] HTTP/1.1 404 Not Found\r\ncontent-length: 0\r\n\r\n
2026-02-11 00:00:00  INFO: [T64a62219] disconnected

Are you able to connect your mobile device via Wi-Fi on the same network as your Traccar server, and specify the Traccar Client [Server URL] as http://192.168.0.1:5055 and test it that way?

LostAndConfused 2 days ago

It works when I use the local IP address. However, you put in the port number (5055). I never did that before. I put that in and now it works. I changed to my dynamic DNS address, and with port 5055 on the end, it works. Go figure.

Thanks for all your help.