However, removing the same tag can take hours. The problem is that while it is removed instantly from the OneAgent, it continues to be displayed in the SaaS GUI for a very long time, and until it disappears, the logic will not change.
In the CloudOps certification materials I have found this.
When does meta data/naming/tagging get applied:
Tagging and naming rules: ~ 30s Manual/API based: immediately Via environment variables (for Process Groups): when process starts Via oneagentctl: Tags/Meta Data: ~5/10min delay Host name/host group: OneAgent restart
So in case of oneagentctl there is a delay, minutes not hours.
You should raise a support ticket with an example.
Via oneagentctl: Tags/Meta Data: ~5/10min delay - for us on the latest version of OneAgent and SaaS it is from 4 to 6 hours. Looks like there is no solution
This is a known behaviour — tag removal via oneagentctl takes longer to reflect compared to adding tags.
When you remove a tag, the OneAgent stops reporting it — but the Dynatrace server-side doesn’t immediately purge it. The platform waits for a certain grace period (can be up to a few hours) before confirming the tag is truly gone.
Use the Dynatrace API to remove the tag server-side immediately.