Events & Notifications not working

mrpurple 4 years ago

Hey traccar-community,

I know, this question is asked a few times already but i still did not get events and therefore notifications, to work.

what i did:

  • i setup email nofitications and tested the transmission (testmail) which worked.
  • i added geofences (settings - notifications)
  • i added notifications (settings - notifications) for actions like entering geofences and device movements.
  • i linked the geofences and the notifications to the device (device - settings - notifications - checkboxes)
  • i also tried enabling "all devices" in the settings - notifications window.

now i have a device which reports movements. i can see the movement after creating a report of actions. Also i can position the device in the geofence.

but i do not get any events in the event pane and i do not get any emails. is there any setting to enable notifications and/or events for my user or serverwide?

Anton Tananaev 4 years ago

Has your device moved in or out the geofence? Have you checked if events are generated?

mrpurple 4 years ago

it moved in and out several times multiple geofences. How do i check if events are generated beside the pane in the web GUI? the web interface doesn't show any events whatsoever.

Anton Tananaev 4 years ago

Events report.

mrpurple 4 years ago

the events report shows me no "geofence related" stuff but shows me "device in motion" which also should trigger an event according to my configuration which it does not.

mrpurple 4 years ago

i forgot to mention my version: i use 4.14 inside a docker container.

Anton Tananaev 4 years ago

It sounds like everything is correct, so it should be working.

mrpurple 4 years ago

this is driving me crazy because everything looks like it should. this is my docker run-command:

docker run \
-d --restart always \
--name traccar \
--hostname traccar \
-p 8088:8082 \
-p 5023:5023 \
-p 5023:5023/udp \
--ip 172.17.0.2 \
-v "$local_path"/persistent_data/logs:/opt/traccar/logs:rw \
-v "$local_path"/persistent_data/traccar.xml:/opt/traccar/conf/traccar.xml:ro \
-v "$local_path"/persistent_data/data:/opt/traccar/data:rw \
-v "$local_path"/persistent_data/default.xml:/opt/traccar/conf/default.xml:rw \
traccar/traccar:4.14

default.xml is stock from the container. I did not modify it.

traccar.xml looks like: (i anonymized the telegram- and mail-settings. mail is working.)
also i tried to add

<entry key='event.enable'>true</entry>

which doesnt seem to do anything.

default.xml

<properties>
    <entry key='config.default'>./conf/default.xml</entry>
    <!--
    This is the main configuration file. All your configuration parameters should be placed in this file.
    Default configuration parameters are located in the "default.xml" file. You should not modify it to avoid issues
    with upgrading to a new version. Parameters in the main config file override values in the default file. Do not
    remove "config.default" parameter from this file unless you know what you are doing.

    For list of available parameters see following page: https://www.traccar.org/configuration-file/
    -->
    <entry key='event.enable'>true</entry>
    <entry key='notificator.types'>web,mail,telegram</entry>
    <entry key='database.driver'>org.h2.Driver</entry>
    <entry key='database.url'>jdbc:h2:./data/database</entry>
    <entry key='database.user'>sa</entry>
    <entry key='database.password'></entry>
    <!-- EMAIL SETTINGS -->
    <entry key='mail.smtp.host'>SMTP_SERVER_IP</entry>
    <entry key='mail.smtp.port'>25</entry>
    <entry key='mail.smtp.starttls.enable'>false</entry>
    <entry key='mail.smtp.auth'>false</entry>
    <entry key='mail.smtp.from'>MAILADRESS_SENDER</entry>
    <entry key='mail.smtp.username'>MAILADRESS@DOMAIN.COM</entry>
    <entry key='mail.smtp.password'>PASS123</entry>
    <entry key='notificator.telegram.key'>bot_key</entry>
    <entry key='notificator.telegram.chatId'>chat_id</entry>
</properties>
Track-trace 4 years ago

@mrpurple

How about adding this to default.xml

<entry key='filter.skipAttributes.enable'>true</entry>
<entry key='filter.skipAttributes'>alarm,event,status</entry>

https://www.traccar.org/configuration-file/

mrpurple 4 years ago

thank you for your help @Track-trace. I added the lines, nothing changed. :(

Track-trace 4 years ago

When the device goes offline or comes online. Then you see that in the event window ?

mrpurple 4 years ago

no, i dont get eny events what so ever.

I can do a report for any timefrime, for example "today" and i do get lines which state "online" and "offline" but i dont get any events.

tracking works perfectly fine also. i am using two zx303 tracker and they track my gps-postitions without any problems.

Track-trace 4 years ago

@mrpurple you might an make screenshot from webinterface. Which show your Settings / Notification window. Upload it some where for instance to https://imgbb.com/upload

And the link it here so we can see your settings.

mrpurple 4 years ago

thank you. do you need any more screenshots?
https://ibb.co/ww6TZ8f
https://ibb.co/x1WwY4G
https://ibb.co/4PYLqp7

Track-trace 4 years ago

Click on your device as shown here.

https://ibb.co/YyGsJgQ

Then click on the settings above (red circle). Then click on Notifications from that menu. Check that everything is assigned to your device.
Like geofence in and Geofence out. Is that true ?

Show picture.