Default config question V6.2

SwayDev6 months ago

I am currently on v5.8 and intend to update to v6.2

Did a trial upgrade with a new setup from 5.8 to 6.2, the default.xml is not there anymore.

Would there be a minimal required values default.xml file?

E.g. in my default files I had protocol timeouts for some of the protocols, then filters etc.

Or do we just backup the 5.8 default config and move it to 6.2? In this case do we remove the port/protocol configs from the file?

What's the best practice?

asicar6 months ago

The best practice was as the default.xml said DO NOT MODIFY THIS FILE. Use traccar.xml instead. so the logical thing is to simply put your configuration and parameters and filters in the traccar.xml

Anton Tananaev6 months ago

Defaults are the same as before. You can find them in the documentation. Never copy defaults from old versions. That's the whole reason we removed that file. People keep mindlessly copying default parameters from old versions, which can and does break new version sometimes.

SwayDev6 months ago

So, if I need to add filters, or firebase configurations it should be added in traccar.xml?

Anton Tananaev6 months ago

Yes, that was always the case.

SwayDev6 months ago

Thank you for the clarification @tananev and @asicar

I have been doing it wrong.

AndiP6 months ago

Thanks all.

But now I have a question:
Previously I had disabled all protocols that are not used by my trackers to not expose IP ports that are not used to the public.
I did that by uncommenting the protocols from default.xml.

How can I now disable certain protocols in traccar.xml, and from where would I get the full list after every update?

Thanks
Andi

AndiP6 months ago

Ok, was digging through the code and see, the ports are now assigned in code instead of from configuration.
I fear, what I previously achieved easily with commenting unused protocols is not possible anymore.

So far I put iptables rules in that prevent the ports from being exposed. If there is a better way, happy to try though.

Pavel6 months ago

It is possible to disable protocols by setting port to 0 in traccar.xml. But it's sucks.

<entry key='[PORT_TO_DISABLE].port'>0</entry>
AndiP6 months ago

Hi, yep, this is obviously an option.

However, when new protocols get added, one needs to check sources again to find the added protocol in order to disable it.

Yep, not really user friendly to handle. But we should not complain, after all we are using free software and have our workarounds...

Pavel6 months ago

Of course, but IMHO, it is more correct to activate only what you need.

Pavel6 months ago

protocols.enable config

List of protocols to enable. If not specified, Traccar enabled all protocols that have port numbers listed. The value is a comma-separated list of protocol names. Example value: teltonika,osmand

We are dumb, RTFM :)

AndiP6 months ago

aaaah. ok.

I gotta try that now.

Thanks for diving into that.

AndiP6 months ago

Update: Works like a charm. Now I am happy again :-)

Many thanks for help, Pavel.

paulo andre jannke6 months ago

I use a different port sitting on the default example tk103 I use port 5000 instead of 5001 how can I change it now if the file is no longer present?