Can't get email to work

jfa year ago

So everything is running fine but I tried to setup email and it won't send:
error in tracker-server.log:

 WARN: Email report failed - Connection timed out - ConnectException (... < SmtpMailManager:152 < ReportMailer:58 < ...)

my smtp:

<entry key='mail.smtp.host'>mail.infomaniak.com</entry>
<entry key='mail.smtp.port'>465</entry>
<entry key='mail.smtp.ssl.enable'>true</entry>
<entry key='mail.smtp.from'>myemailadress</entry>
<entry key='mail.smtp.auth'>true</entry>
<entry key='mail.smtp.username'>myemailadress</entry>
<entry key='mail.smtp.password'>mypassword</entry>
Track-trace2a year ago

Meaby this line

<entry key='mail.smtp.starttls.enable'>true</entry>

instead of

<entry key='mail.smtp.ssl.enable'>true</entry>
jfa year ago

my email host says 465, and I just tried, same result.

Anton Tananaeva year ago

Either there's some problem with your email server or some configuration details are incorrect, but I'm not sure how we can help with either of those issues.

jfa year ago

Previously i tried adding it globally to "traccar.xml" this did not work. But the same configuration works when adding it as attributes to a user.

Anton Tananaeva year ago

They work exactly the same no matter where you add, so there must be some other thing you missed.

Turbovixa year ago

Are you sure your VPS is not blocking traffic on port 465?

jfa year ago

i disabled the firewall for a short while to test if that was the problem and it didnt have an effect, but I solved my problem. I couldn't set it up globally but when i set it up for each user it works and thats good enough for me.

Anton Tananaeva year ago

Maybe you had a password with a special character? Remember that you need to escape any special characters because it's an XML file.