About this article: This article is reviewed against the cited sources. This is source research, not lab validation. Check the stated versions and your own requirements before making changes.
A Veeam job with application-aware processing that is set to process transaction logs can finish with the warning Failed to truncate Microsoft SQL Server transaction logs. Details: Failed to process 'TruncateSQLLog' command. The detail line often reads Unable to truncate SQL server transaction logs. Details: Failed to truncate SQL server transaction logs for instances: MSSQLSERVER. Login failed for user 'DOMAIN\Bkpadmin'. Veeam's knowledge base article KB2027's first step is to confirm that the account used by Veeam has the required SQL permissions. The log on the SQL server names the account and the exact SQL error, and that error decides the fix.
What the warning means
For a virtual machine job, the transaction log setting sits in the job's SQL processing settings. Veeam's user guide says that with Truncate logs selected, components on the guest operating system "will wait for the backup to complete successfully and then truncate transaction logs". Truncation is therefore a separate step, run by Veeam components on the guest, that signs in to SQL Server with an account.
KB2027 says the account for that step is the one on the Guest Processing tab of the job for virtual machines, and for machines protected by Veeam Agent for Microsoft Windows it is the account used to add the machine to the protection group. If that account fails, "the software will failover and attempt to use the NT AUTHORITY\SYSTEM account". That fallback is why a log can show two accounts failing in one run.
While the step fails, Veeam does not truncate the log. How a log that is not truncated behaves is covered in SQL Transaction Log Keeps Growing: Find the Real Cause, which separates log reuse from file growth. What follows covers why Veeam's step fails.
Likely causes
The KB lists these errors as commonly seen in the logs.
| Cause | What you see | How to confirm |
|---|---|---|
| The account has no login on the instance | Description = Login failed for user 'DOMAIN\user'. |
The login is missing from Security > Logins on that instance |
| The login exists but cannot use the databases | The server principal "DOMAIN\user" is not able to access the database "DBName" under the current security context. |
The login is not in the sysadmin role |
| SQL Server found log corruption | BACKUP detected corruption in the database log. Check the error log for more information. |
The SQL Server error log shows the corruption detail |
| No full backup exists for a database | BACKUP LOG cannot be performed because there is no current database backup. |
Often a secondary replica of an Always On cluster that has only ever been backed up copy-only |
| The step ran out of time | Query timeout expired |
The job runs long; the default execution timeout is 300 seconds |
Prove the cause before changing anything
Every step here only reads.
1. Find out which account Veeam used. For a virtual machine job, open the job's Guest Processing settings and note the account. For Veeam Agent, it is the account used to add the machine to the protection group.
2. Read the Veeam log on the SQL server. KB2027 gives these locations:
C:\ProgramData\Veeam\Backup\VeeamGuestHelper_ddmmyyyy.log
C:\ProgramData\Veeam\Endpoint\<jobname>\Job.Backup.log
The first file belongs to Veeam Backup & Replication jobs; the second to Veeam Agent. In the first, look beneath the line "Transaction log truncation statistics"; in the second, beneath "Checking if can truncate SQL logs." There you find the account used, the instances processed and each database touched. A good result is every database listed without an error. A bad result is a Description = line from the table above.
3. Check the account's server roles. Use a different administrator account, because the failing account cannot connect. In sqlcmd, -E signs in with your own Windows account and -S names the server:
sqlcmd -E -S db01 -Q "SELECT IS_SRVROLEMEMBER('sysadmin', 'EXAMPLE\svc-veeam')"
Microsoft documents the result as 1 when the login is a member, 0 when it is not, and NULL when the role or login is not valid or you lack permission to see it. The same page says that for a Windows login, IS_SRVROLEMEMBER returns NULL "unless the login has been granted or denied direct access to SQL Server". A NULL for a Windows group login is therefore not proof of anything; read the role list in the Fix section instead.
Fix
Account has no login, or no database access
KB2027 gives one remedy for both permission errors: create the login if it is missing, and assign it the sysadmin role. Veeam's guest processing permissions page lists a narrower set (instance roles public and dbcreator, database roles and securables) and adds: "If you do not want to assign the permissions gradually, use an account that has local Administrator permissions on the target VM and system Administrator permissions (with the Sysadmin role) on the target Microsoft SQL Server." Choose with your database administrator.
First save the current state, signed in as a different administrator, with an existing C:\temp folder (create it, or change the -o paths to a folder that exists). The first command saves the server role memberships. The second saves whether the login exists at all, because a login that belongs to no listed role does not appear in the first file:
sqlcmd -E -S db01 -Q "SELECT roles.name AS RoleName, members.name AS MemberName FROM sys.server_role_members AS m INNER JOIN sys.server_principals AS roles ON m.role_principal_id = roles.principal_id INNER JOIN sys.server_principals AS members ON m.member_principal_id = members.principal_id" -o C:\temp\server-roles-before.txt
sqlcmd -E -S db01 -Q "SELECT name, type_desc, is_disabled FROM sys.server_principals WHERE name = 'EXAMPLE\svc-veeam'" -o C:\temp\login-before.txt
Open login-before.txt. If it lists a row for the account, the login existed before the change; if it lists no row, the login did not exist. Note which, because the back-out depends on it.
Risk: the next commands create a SQL Server login for the Veeam account and add it to the sysadmin role, which gives that account full control of the whole instance.
Run the change. If login-before.txt listed a row, the login already existed: run only the second statement (ALTER SERVER ROLE), not the first. If the account was already a member of sysadmin in server-roles-before.txt, nothing needs to change. CREATE LOGIN ... FROM WINDOWS takes the domain account in [DOMAIN\name] form, and ALTER SERVER ROLE ... ADD MEMBER adds it to the role:
sqlcmd -E -S db01 -Q "CREATE LOGIN [EXAMPLE\svc-veeam] FROM WINDOWS; ALTER SERVER ROLE sysadmin ADD MEMBER [EXAMPLE\svc-veeam];"
To undo it, run block 1 whenever you want to take the account out of the role. Run block 2 only if login-before.txt listed no row, which means this change created the login.
Risk: the next command removes the account from the sysadmin role. If server-roles-before.txt already showed the account in sysadmin, skip it, because it would remove access the account had before this change.
Block 1, remove the role membership:
sqlcmd -E -S db01 -Q "ALTER SERVER ROLE sysadmin DROP MEMBER [EXAMPLE\svc-veeam];"
Risk: the next command drops the login from the SQL Server instance. If the login existed before this change, dropping it removes a login that was already in use. Run it only when login-before.txt listed no row. DROP LOGIN fails while the login owns a securable, a server-level object or an Agent job.
Block 2, drop the login:
sqlcmd -E -S db01 -Q "DROP LOGIN [EXAMPLE\svc-veeam];"
Run both saved queries again to new files and compare them with server-roles-before.txt and login-before.txt.
Query timeout expired
KB2027 says the execution timeout default is 300 seconds, the value needed "will be unique to each environment", and "A common tactic is to increase the value by 300, test the job, and increase by another 300 seconds if it fails." The SqlExecTimeout DWORD sits under HKLM\SOFTWARE\Veeam\Veeam Backup and Replication for virtual machine jobs, and under HKLM\SOFTWARE\Veeam\Veeam Endpoint Backup for Veeam Agent jobs except the Failover Cluster type. For a Failover Cluster job managed by Backup & Replication, KB2027 says to create the value under the first key on all cluster nodes. The value belongs on the SQL server with the problem.
First save the current state. If the value does not exist, the file holds an error message, and that tells you there was nothing to restore:
reg query "HKLM\SOFTWARE\Veeam\Veeam Backup and Replication" /v SqlExecTimeout > C:\temp\sqlexectimeout-before.txt 2>&1
Risk: the next command writes a registry value that changes how long Veeam waits for SQL Server on this machine.
Set 600 seconds (300 + 300). reg add asks before overwriting an existing value:
reg add "HKLM\SOFTWARE\Veeam\Veeam Backup and Replication" /v SqlExecTimeout /t REG_DWORD /d 600
To undo it: if sqlexectimeout-before.txt showed an earlier value, set that number with the same reg add command; reg query shows REG_DWORD data in hexadecimal, so convert it to decimal first (our own note, because Microsoft's reg query page shows no sample output). If it showed an error, delete only that value, using the command below. Keep /v, because without it Microsoft's page says all entries and subkeys under the key are deleted, which here is Veeam's own settings key.
Risk: the next command deletes the value SqlExecTimeout. Run it only when sqlexectimeout-before.txt showed an error, which means the value did not exist before.
reg delete "HKLM\SOFTWARE\Veeam\Veeam Backup and Replication" /v SqlExecTimeout
Log corruption, or no current database backup
For corruption, KB2027 says the issue lies within the SQL instance or database and points to the SQL Server error log. That is a database administrator's repair. For the missing-backup error, the KB says a manual backup of the named database in SQL Server Management Studio solves it, or, in the KB's words, "you can set the secondary node as primary for just one backup job run". Veeam's page gives no steps for that; it does not say whether it means a job setting or a role change in the availability group. Both options change SQL Server's backup history; your database administrator should choose, and SQL Point-in-Time Restore: Plan and Verify the Backup Chain explains the backup chain.
Example (illustrative): the job db01-nightly warns on db01. VeeamGuestHelper_ddmmyyyy.log shows Login failed for user 'EXAMPLE\svc-veeam'. and then NT AUTHORITY\SYSTEM failing on the databases. The administrator signs in as EXAMPLE\dba1, saves the role list and the login check, finds no row for EXAMPLE\svc-veeam in login-before.txt, creates the login and adds it to sysadmin. The next run's log lists each database without a Description = line.
Confirm the fix
- Run the job. The warning is gone and the log lists every database under "Transaction log truncation statistics" without an error.
- The saved before-and-after role lists differ only by the change you made.
- If you changed the timeout, the run finishes inside the new value; if it fails again, add another 300 seconds.
What to watch afterwards
- Each night's job result for the same warning.
- The service account's password expiry and any account change; the login depends on that exact account.
- New SQL instances on the server, which need the same login.
- Always On secondary replicas, which carry the missing-backup error when only copy-only backups exist.
Read next
Related articles you may want next.
- TroubleshootingSQL Transaction Log Keeps Growing: Find the Real CauseSeparate log reuse, physical file growth and disk exhaustion, then identify the evidence needed for a DBA-approved SQL Server remedy and recovery check.Read article
- Backup & RecoverySqlServerWriter missing from vssadmin list writers: what it means for VSS backups of SQL ServerSqlServerWriter missing from vssadmin list writers? Check the SQL Writer service, its account and login, and database names before trusting VSS backups.Read article
- Backup & RecoverySQL Point-in-Time Restore: Plan and Verify the Backup ChainCheck native SQL backup chains, select a recovery point and rehearse a separate restore without confusing readable backups with recovered service.Read article
Risks and limits
- These commands have not been run or lab-tested.
- KB2027 lists no Veeam version numbers, and the user guide text above is from the version 13 guide.
- The
sysadminrole is the vendor's remedy and the broadest choice; use the narrower permissions list if your policy requires it. - Veeam documents the fallback to NT AUTHORITY\SYSTEM, so a second account appearing in the log is consistent with that fallback.
- Registry edits and role changes need an administrator and should follow your change process.
NetLeverage includes a daily full disaster-recovery backup of each hosted server at no extra charge. Talk to an engineer.
Sources
- Backup Job reports warning "Failed to truncate Microsoft SQL Server transaction logs." — Veeam Software, KB2027, published 28 April 2015, last modified 28 March 2025, accessed 2 December 2026
- Microsoft SQL Server Transaction Log Settings — Veeam Help Center, Veeam Backup & Replication 13 User Guide, page updated 26 November 2026 (build 13.2.0.193), accessed 2 December 2026
- Guest Processing — Veeam Help Center, Veeam Backup & Replication 13 User Guide, page updated 30 November 2026 (build 13.2.0.193), accessed 2 December 2026
- IS_SRVROLEMEMBER (Transact-SQL) — Microsoft Learn, last updated 18 November 2025, accessed 2 December 2026
- sys.server_principals (Transact-SQL) — Microsoft Learn, last updated 21 September 2026, accessed 2 December 2026
- sys.server_role_members (Transact-SQL) — Microsoft Learn, last updated 21 September 2026, accessed 2 December 2026
- ALTER SERVER ROLE (Transact-SQL) — Microsoft Learn, last updated 21 September 2026, accessed 2 December 2026
- CREATE LOGIN (Transact-SQL) — Microsoft Learn, last updated 21 September 2026, accessed 2 December 2026
- DROP LOGIN (Transact-SQL) — Microsoft Learn, last updated 21 September 2026, accessed 2 December 2026
- sqlcmd utility — Microsoft Learn, last updated 10 October 2026, accessed 2 December 2026
- reg add — Microsoft Learn, last updated 4 January 2024, accessed 2 December 2026
- reg query — Microsoft Learn, last updated 3 February 2023, accessed 2 December 2026
- reg delete — Microsoft Learn, last updated 3 February 2023, accessed 2 December 2026
This article was originally published on .