How to increase connection timeout

Edilon Carvalho 4 years ago

Can someone help me change these settings?

Would just add this entry to the traccar.xml? web.timeout?

I have already specified the maximum heap size to -Xmx1G

The server is 4GB

Anton Tananaev4 years ago

What timeout are you talking about?

Edilon Carvalho 4 years ago

I mean connection timeout

<entry key='web.timeout'xxxxxx/entry>

What is the ideal value to set this parameter?

Anton Tananaev4 years ago

I understand that you are talking about connection timeout, but which connection timeout? Web port? Device ports? Any specific device port or all of them?

Edilon Carvalho 4 years ago

On the traccar optimization page there is this part that talks about what I'm asking

Setting connection timeout in Traccar

Operating system has timeout for all TCP connections, but it's usually very high. For example, on Linux it's common to have 2 hours timeout. It means that if your device re-connects without gracefully closing connection, then it will leave a hanging connection on the server that consumes server resources and is counted against total connection limit. When network connection is poor, a single device can easily create tens or even hundreds of connections within 2 hour period.

To avoid the problem, it's recommended to set connection limit in Traccar server. You can use "timeout" option in the config file. It's configured per protocol, and it's recommended to set the value (in seconds) to slightly higher than your device reporting interval.

Anton Tananaev4 years ago

It talks about device ports timeout. You can set it globally using "server.timeout". But it's a bit worrying that you trying to do something without clear understanding what it is and what it's for.

Edilon Carvalho 4 years ago

I was having the following problem:
Memory limit heap: 489mb non-heap: 0mb
I made all the changes according to the optimization page and it seems to have solved it.
There was no need but I also upgraded the memory