SOS not showing in events window

Tupp 2 years ago

Hi,

Recently I have installed a clean/new instance of traccar version 5.9, everything works perfectly except SOS notifications in the event window. I have configured everything correctly that mirrors our old instance of 4.15 notifications (which work). Here are the settings I have configured:

Notifications
Type of Notification (Alarm)>All Devices (Yes)>Alarms (SOS)>Channels

Users
Connections>Notications(Alarms SOS [1]

When a user sends an SOS I can see it generated when a report is run against the user, I can also see this in the SQL database events. When I configure the notification and run a test from the notification configuration screen that works, but I can't seem to get it working for a user.

I have even tried an upgrade of our 4.15 instance to 5.9 and that does not work either. Does anyone have any ideas on how I can get this fixed?

Anton Tananaev 2 years ago

Have you checked logs for errors?

Tupp 2 years ago

Hey Anton,

Thanks for getting back to me, there are no errors in the logs, apologies I forgot to mention that I had checked them. I'm seeing all the normal traffic. The confusing part is that when I run Reports>Events>MyDevice>Show I see alarms reported in the report when I trigger an alarm.

Anton Tananaev 2 years ago
  1. Which channels do you have configured in the notification?
  2. Is the WebSocket connected?

Ideally also provide screenshots for both.

Tupp 2 years ago

Hi Anton,

I've configured web as the channel see screenshot:
https://www.dropbox.com/scl/fi/4xa8be5x4eoprsnlvutei/Traccar-Notification.png?rlkey=p8tp2ialhx6l4o9l2hhs2vawf&dl=0

This is what I see when I click test channels on my notification:
https://www.dropbox.com/scl/fi/7exg9orbmqldw23tuiu2q/traccar-event.png?rlkey=sunlxb5rpmlv4kgye5oomwdpq&dl=0

When a report is run against my device I'm seeing this:
https://www.dropbox.com/scl/fi/dtlm1ejec7lcja1prvew2/Reports.png?rlkey=ylrpc0vhtuz7v4gv73k1f8buj&dl=0

I have confirmed that the Websocket is connected and receiving information using Postman.

Currently I have tested this on a Windows Server (SQL backend) and a RHEL instance with the Linux installation with the same results.

The app version we are using is 7.0 FYI on Google Pixels.

Anton Tananaev 2 years ago

I'm not sure I understand about Postman. You need to confirm that it's working in the web app.

Tupp 2 years ago

No probs, so when I run the command ws://IP:8082/api/socket I see the following information when my device connects which leads me to believe that we are connected.

https://www.dropbox.com/scl/fi/wloqemi6cisslx1oxqt5u/WebSocket.jpg?rlkey=mtapo1kujeyacmscbub3n43s7&dl=0

Is there a better way to check that the web app is working?

Anton Tananaev 2 years ago

I'm asking you to check in the app, not calling the API directly from somewhere else.

Tupp 2 years ago

Hi Anton,

No problems, when triggering an SOS from a device here is what I am seeing in web developer tools in firefox inside the traccar manager app using the websocket implementation in (https://github.com/traccar/traccar-web/blob/9bd75b29e3654e0854e3ae35741609dd24ceb218/web/simple/app.js)

https://www.dropbox.com/scl/fi/0s0uwufcelyt4ebishzlo/Firefox-Websocket.png?rlkey=g36sq7qx7i8aienk8nbuzlbdj&dl=0

Anton Tananaev 2 years ago

No other ideas. You must be missing something.

Tupp 2 years ago

Hi Anton,

So after a bit more troubleshooting I have installed the latest traccar into my lab with my device directly connecting to the server with no VPN or firewall in place and I get notifications working.

What I'm seeing in my production environment (devices VPN in) they are not working. I have rolled the version back to 4.15 and notifications work perfectly, after I upgrade to any version 5+ beyond after that they do not work. I'm wondering what could have changed in the code from 4.15 onwards to cause this issue? Any thoughts? Appreciate your help.

Anton Tananaev 2 years ago

No idea. Are you sure you don't have any plugins that can mess up with the app?

Tupp 2 years ago

Hi Anton,

Apologies only just getting back to you on this. No plugins or anything like that could block notifications (have tried several different browsers also). Weirdly I cloned the traccar RHEL VM from my lab and onto my laptop with the exact same settings and the notifications do not work even after a rebuild using the exact same settings. Something very strange is going on, will continue to troublehsoot.