Hi
I’ve activated ngalert
[feature_toggles]
enable = ngalert
and when bouncing Grafana it doesn’t come up with the error message in log:
t=2021-06-16T17:42:25+0100 lvl=info msg="Executing migration" logger=migrator id="move dashboard alerts to unified alerting"
t=2021-06-16T17:42:25+0100 lvl=eror msg="Executing migration failed" logger=migrator id="move dashboard alerts to unified alerting" error="failed to migrate alert 14: dashboard with UID under organisation 27 not found: %!w(<nil>)"
t=2021-06-16T17:42:25+0100 lvl=eror msg="Exec failed" logger=migrator error="failed to migrate alert 14: dashboard with UID under organisation 27 not found: %!w(<nil>)" sql="code migration"
So it complaints about OrgID 27 and alert 14.
Both items do not exist and were removed from Grafana some time before I tried to switch to ngalert
> curl -X GET https://admin:***@grafana:8086/api/orgs/27
{"message":"Organization not found"}
and
> curl -X DELETE https://admin:***@grafana:8086/api/alert-notifications/14
{"message":"alert notification not found"}
> curl -X GET https://admin:***@grafana:8086/api/alerts/14
{"message":"You are not allowed to edit/view alert"}
My understanding that there are some traces left from deleted organizations and alerts and migration process fails
Any suggestions how to fix it?
Thanks