Failed to enable DC SafeBoot mode

Problem

You see this error when a Veeam backup runs:

Error: Failed to enable DC SafeBoot mode
Cannot execute [SetIntegerElement] method of [\\[HOSTNAME]\root\wmi:BcdObject.Id="{UUID}",StoreFilePath=""].
COM error: Code: 0xd0000022

Common cause

Most commonly seen with Sentinel One anti malware, but could be caused by other anti malware products as well. The Veeam Agent is modifies the boot record prior performing backup to make sure that restore point is created in Directory Services Restore Mode. Sentinel One is blocking this process.

Solution

Check if the server has Sentinel One Agent installed. If it does, you can disable Safe Boot Protect by running the following command

sentinelctl config -k [passphrase] -p agent.safeBootProtection -v false