I recently noticed that notifications were not working reliably, i.e. sometimes notification received, sometimes not. Until recently is was working well and even now, when using the notification test on the account tab, everything seems good and the test message is received 100% of the time (web, email & SMS), so I am assuming my setup is correct.
I decided to delete all of the notifications and start again. However, with no notifications set up I am still getting an 'Exited Geofence" notification option on all of the user accounts. If I try to choose this (by selecting the checkbox) I get the following error,
Cannot add or update a child row: a foreign key constraint fails (`traccar`.`tc_user_notification`, CONSTRAINT `fk_user_notification_notificationid` FOREIGN KEY (`notificationid`) REFERENCES `tc_notifications` (`id`) ON DELETE CASCADE) - SQLIntegrityConstraintViolationException (... < QueryBuilder:446 < DataManager:412 < PermissionsResource:80 < ...)
Checking the database directly (via HeidiSQL) indicated there are no entries in tables tc_user_notification or tc_notifications so it is difficult to see where the 'Exited Geofence' notification in the user accounts is coming from. I don't know if this is what is causing the notification problems I am experiencing, but it seems a possibilty, however, I can't select it or delete it so its difficult to be sure.
Can anybody suggest what to try next?
Try restarting the service and see if it's still there.
Restarted the MySQL service and that cleared the phantom notification issue, however, the problem with missing notifications is still there.
Following more testing it seems that the problem is just with alarms, in particular the fall down and SOS alarm, although the same issue is also observed with power on and power off. Event notifications such as geofence entry & exit are working reliably. The HEX alarm from the device is visible in the log as being received correctly, but it seems is not always actioned by the server. When the notification is received correctly there is also a record made in the tc_events table, but when no notification is received there is no record
You still get the same errors? It means something is seriously wrong with the database.
I have same issue with sound notifications, i reinstall windows app, i added notifications, but no luck, any fixes?
What Windows app?
Sorry i mean Server
Windows x64 traccar-windows-64-5.0
That won't help with the sound. What sound are we talking about btw?
before it had notification sound, for example device online, device moving and etc
What kind of notification? Web? Push? Something else?
Web with sound
It hasn't worked for a long time because modern browsers don't allow playing sounds. What browser are you using?
im using opera browser and two days ago it was working
Well, it doesn't work in most browsers, so it doesn't make sense to maintain it anymore. Have you switched to the modern app and that's when it stopped working?
yes i switched 5.0 version and now it stopped. i think its very good function to have a sound for attention. there is no way to fix it?