Log backup failed


My production log back job failed. We are running Ola Hallengren's script, and Full/Diff/Log are all in good shapes for a while until this morning when I tried to share the backup drive on the server so the restore script could move the .bak to
a test server.

Since then, I have tried to undo my sharing and possible permission changes on the server drive/folder, but the log back job is still failing.

The error message makes no sense to me. But could these two events (job failure and sharing) totally unrelated?

We have weekly full, daily diff and 10 min log backup, and last good log was 8:10.

Here is my command and error (with some values replaced): Thanks!

Date 8/17/2016 8:20:00 AM
sqlcmd -E -S $(ESCAPE_SQUOTE(SRVR)) -d master -Q "EXECUTE [dbo].[DatabaseBackup] @Databases = 'R_TP', @Directory = N'G:\Backup', @BackupType = 'LOG', @Verify = 'Y', @CleanupTime = 48, @CheckSum = 'Y', @LogToTable = 'Y'" -b

Log Job History (DatabaseBackup - R_TP - LOG)
Step ID 1
Server SISDB01
Job Name DatabaseBackup - R_TP - LOG
Step Name DatabaseBackup - USER_DATABASES - LOG
Duration 00:00:00
Sql Severity 0
Sql Message ID 0
Operator Emailed
Operator Net sent
Operator Paged
Retries Attempted 0

Executed as user: svc1. Date and time: 2016-08-17 08:20:00 Server: Sv1 Version: 12.0.4457.0 Edition: Enterprise Edition (64-bit) Procedure: [master].[dbo].[DatabaseBackup] Parameters: @Databases = 'R_TP', @Directory = 'G:\Backup', @BackupType = 'LOG', @Verify = 'Y', @CleanupTime = 48, @Compress = NULL, @CopyOnly = 'N', @ChangeBackupType = 'N', @BackupSoftware = NULL, @CheckSum = 'Y', @BlockSize = NULL, @BufferCount = NULL, @MaxTransferSize = NULL, @NumberOfFiles = NULL, @CompressionLevel = NULL, @Description = NULL, @Threads = NULL, @Throttle = NULL, @Encrypt = 'N', @EncryptionType = NULL, @EncryptionKey = NULL, @ReadWriteFileGroups = 'N', @OverrideBackupPreference = 'N', @LogToTable = 'Y', @Execute = 'Y' Source: http://ola.hallengren.com Date and time: 2016-08-17 08:20:00 Database: [R_TP] Status: ONLINE Standby: No Updateability: READ_WRITE User access: MULTI_USER Is accessible: Yes Recovery model: FULL Differential base LSN: 26686000532210700005 Differential base is snapshot: No Last log backup LSN: 26748003388880600001 Date and time: 2016-08-17 08:20:00 Command: DECLARE @ReturnCode int EXECUTE @ReturnCode = [master].dbo.xp_create_subdir N'G:\Backup\Sv1\R_TP\LOG' IF @ReturnCode <> 0 RAISERROR('Error creating directory.', 16, 1) HResult 0x5620, Level 16, State 1 xp_create_subdir() returned error 183, 'Cannot create a file when that file already exists.' Msg 50000, Level 16, State 1, Server SISDB01, Line 1 Error creating directory. Outcome: Failed Duration: 00:00:00 Date and time: 2016-08-17 08:20:00 Date and time: 2016-08-17 08:20:00. Process Exit Code 1. The step failed.

Appears to be:

trying to create a subfolder : G:\Backup\Sv1\R_TP\LOG

Might be a file, of that name (LOG), in that folder (G:\Backup\Sv1\R_TP) which is preventing the Folder (LOG) being created.

Failing that, just create the Folder (manually) and see if it sorts itself out, by itself. Might be permission problems, so you might need to change the permissions on that folder (i.e. the relevant parent folder and all children)

1 Like


Thank you!

It is a permission issue.

Network 101 for dummy DBA is still on the top of my reading list. :slight_smile:



1 Like