none
SMS Backup failure RRS feed

  • Question

  • Hello Team,

    I have a CAS site where the site maintenance task backup is failing during the scheduled run. However when we run manually, it works and succeeds with message ID 5035. Below is the error message recorded in the site backup component.

    "Site Backup failed. The error reported by the service is ERROR: BackupComplete failed. Error message - ERROR: CopyFile to F:\SMSBackup\A01Backup\SiteDBServer failed: [error code: 21, error message: The device is not ready.]. Backup operation is not completed. Please see smsbkup.log for more information."

    And below is the error recorded as well. Could you please help on this?

    "

    Site Backup was unable to back up file system object \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf to F:\SMSBackup\A01Backup\SiteDBServer.

    Possible cause: \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf is not readable, or F:\SMSBackup\A01Backup\SiteDBServer is not writable.
    Solution: Adjust file attributes and/or permissions of \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf and/or F:\SMSBackup\A01Backup\SiteDBServer.

    Possible cause: The destination directory F:\SMSBackup\A01Backup\SiteDBServer did not already exist, and Site Backup was unable to create it.
    Solution: Verify that a regular file with the same name as F:\SMSBackup\A01Backup\SiteDBServer or one of its parent directories does not exist, or replace F:\SMSBackup\A01Backup\SiteDBServer with an existing directory.

    Possible cause: \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf or F:\SMSBackup\A01Backup\SiteDBServer are on remote computers that Site Backup does not have sufficient access rights to administer.
    Solution: Verify that the site server computer accounthas administrative rights on the site system. 

    Possible cause: An application is using F:\SMSBackup\A01Backup\SiteDBServer or some component of its path (for example, Windows Explorer may be viewing F:\SMSBackup\A01Backup\SiteDBServer's parent directory.)
    Solution: Verify that F:\SMSBackup\A01Backup\SiteDBServer and its parent directories are not in use by any application.

    Possible cause: Source \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf being copied to F:\SMSBackup\A01Backup\SiteDBServer may cause a recursive operation
    Solution: Verify that destination folder does not exist within the source folder.

    Possible cause: Source \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf contains some file(s) that is opened exclusively by some application.
    Solution: Retry backup again."

    Tuesday, July 16, 2019 9:51 AM

Answers

  • Honestly, stop using the built-in backup task and use a native SQL backup task which is far more flexible and capable in combination with an enterprise backup solution to backup the SQL backup file as well as other complementary items from the file system like cd.latest, the content library, source files, etc. It'll work far better and easily grabs everything you need while the backup task only grabs part of what you need.

    Jason | https://home.configmgrftw.com | @jasonsandys

    • Marked as answer by Thang Raj Thursday, July 18, 2019 8:22 AM
    Wednesday, July 17, 2019 8:22 PM

All replies

  • Delete or more the files and initiate the backup again.

    Also check NTFS and share permissions on shared folder.

    Tuesday, July 16, 2019 10:19 AM
  • Hello,
     
    Does it just fail this time, or does it fail every time at the scheduled time? However, since it has succeeded when running manually, I believe there will be no serious problems. 
     
    Check the smsbkup.log, locate to when the issue is occurred based on the status message. Could we find some clues there?
     
    Hope my answer could help you and look forward to your feedback.
     
    Best Regards,
    Ray 

    Please remembers to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Tuesday, July 16, 2019 10:25 AM
  • Hello Ray,

    It fails every time at the scheduled time. Below is the smsbackup log records.

    Registered connection to SQL server PMICHLAUCCM01.PMINTL.NET and database CM_A01. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Registered connection to master database on SQL server PMICHLAUCCM01.PMINTL.NET. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Initializing the status message reporting system... SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Inbox source is local on PMICHLAUCCM01.PMINTL.NET SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
        The path to the "Status Manager" inbox is "E:\Program Files\Microsoft Configuration Manager\inboxes\statmgr.box\statmsgs". SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
        SMS_STATUS_MANAGER is not running as part of this process, the SMS_EXECUTIVE to SMS_STATUS_MANAGER in-memory status message queue will not be used. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Registered this process as a source of "SMS Server" events. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Registered this process as a source of "SMS Client" events. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Registered this process as a source of "SMS Provider" events. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Status message reporting system initialized successfully. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Locale set to OS value (English_United States.1252). SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    SMS_SITE_BACKUP service 2012 started. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    STATMSG: ID=500 SEV=I LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:01:23.765 2019 ISTR0="SMS_SITE_BACKUP" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Starting backup - Tue Jul 16 00:01:23 2019 SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    SMS installation root directory = E:\Program Files\Microsoft Configuration Manager. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    SQL installation root directory = \\PMICHLAUCCM01\E$\MSSQL2012\MSSQL11.MSSQLSERVER\MSSQL. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Site server backup location = F:\SMSBackup. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    SQL backup location = F:\SMSBackup. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Verified that backup folder F:\SMSBackup exists. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Verified backup service has permission to access the backup folder F:\SMSBackup SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Sql Writer service is running. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    STATMSG: ID=5055 SEV=I LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:01:23.798 2019 ISTR0="" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    LogEvent(): Successfully logged Event to NT Event Log. (4 - 48 - 1,073,746,879) SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Starting VSS initialization... SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Starting Asynchronous GatherWriterMetadata. SMS_SITE_BACKUP 7/16/2019 12:01:23 AM 30668 (0x77CC)
    Number of writers that responded: 15. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Reading SMS Writer metadata... SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Number of FileIncludes: 0. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Number of FileExcludes: 0. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Number of Components: 9. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 0 - A01Backup\SiteServer\AdminUIContentStaging. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\ADMINUICONTENTSTAGING\* [Recursive: yes] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 1 - A01Backup\SiteServer\SMSServer\inboxes. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\INBOXES\* [Recursive: yes] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 2 - A01Backup\SiteServer\SMSServer\Logs. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\LOGS\* [Recursive: yes] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 3 - A01Backup\SiteServer\SMSServer\data. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\DATA\* [Recursive: yes] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 4 - A01Backup\SiteServer\SMSServer\srvacct. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\SRVACCT\* [Recursive: yes] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 5 - A01Backup\SiteServer\SMSServer. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\Program Files\Microsoft Configuration Manager\install.map [Recursive: no] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 6 - A01Backup\CD.Latest. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\PROGRAM FILES\MICROSOFT CONFIGURATION MANAGER\CD.LATEST\* [Recursive: yes] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 7 - A01Backup\SiteServer\SMSbkSiteRegSMS.dat. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = E:\Program Files\Microsoft Configuration Manager\BackupTemp\SMSbkSiteRegSMS.dat [Recursive: no] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume E:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Component 8 - A01Backup\SiteDBServer\SMSbkSQLSiteDB.dat. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Dependency On SQL Writer , LogicalPath:PMICHLAUCCM01, ComponentName:CM_A01 SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    SQL Server is on the same box as the Site Server. So, no need to communicate to the SQL backup agent. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = F:\MSSQL2012\DATA\MSSQLSERVERCM_A01.mdf [Recursive: no] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume F:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    FileGroupFile = D:\MSSQL2012\DATA\MSSQLSERVERCM_A01_log.LDF [Recursive: no] SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Volume D:\ (that contains the file(s)) is marked as a candidate for snapshot. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    After GatherWriterMetadata SQL Writer status = STABLE. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    After GatherWriterMetadata SMS Writer status = STABLE. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Starting Prepare for backup. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    The System Provider VSS ID is 0,000,00E,402,175,058 SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Added volume containing E:\ to the snapshot set. SMS_SITE_BACKUP 7/16/2019 12:01:25 AM 30668 (0x77CC)
    Added volume containing F:\ to the snapshot set. SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Added volume containing D:\ to the snapshot set. SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Info: Starting Asynchronous PrepareForBackup... SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Info: Asynchronous PrepareForBackup finished... SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    After PrepareForBackup SQL Writer status = STABLE. SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    After PrepareForBackup SMS Writer status = STABLE. SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Starting to clean the backup location F:\SMSBackup\A01Backup. SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Cleanup of backup location done. SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Info: Starting Asynchronous DoSnapshotSet... SMS_SITE_BACKUP 7/16/2019 12:01:26 AM 30668 (0x77CC)
    Info: Asynchronous DoSnapshotSet finished. SMS_SITE_BACKUP 7/16/2019 12:03:07 AM 30668 (0x77CC)
    After DoSnapshotSet SQL Writer status = WAITING_FOR_BACKUP_COMPLETION. SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    After DoSnapshotSet SMS Writer status = WAITING_FOR_BACKUP_COMPLETION. SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    Starting the backup complete phase. SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    STATMSG: ID=5056 SEV=I LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:03:08.065 2019 ISTR0="" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    StateTable::CState::Handle - (5056:1 2019-07-15 22:03:08.065+00:00) >> (5048:3 2019-07-14 22:18:08.826+00:00) SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    Inbox source is local on PMICHLAUCCM01 SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    CStateMsgReporter::DeliverMessages - Queued message: TT=1401 TIDT=0 TID='EF736CF9-7214-4796-9C85-2549A9056D8D' SID=5056 MUF=0 PCNT=2, P1='A01' P2='2019-07-15 22:03:08.065+00:00' P3='' P4='' P5='' SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    CStateMsgReporter::DeliverMessages - Created state message file: E:\Program Files\Microsoft Configuration Manager\inboxes\auth\statesys.box\incoming\aq5su113.SMX SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    Successfully send state change notification EF736CF9-7214-4796-9C85-2549A9056D8D SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    LogEvent(): Successfully logged Event to NT Event Log. (4 - 48 - 1,073,746,880) SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    FinalSnapshotPath = \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf. SMS_SITE_BACKUP 7/16/2019 12:03:08 AM 30668 (0x77CC)
    Error: Failed to backup \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf up to F:\SMSBackup\A01Backup\SiteDBServer: ERROR: CopyFile to F:\SMSBackup\A01Backup\SiteDBServer failed: [error code: 21, error message: The device is not ready.]. SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    STATMSG: ID=5043 SEV=E LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:18:33.242 2019 ISTR0="\\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf" ISTR1="F:\SMSBackup\A01Backup\SiteDBServer" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    Failed to copy file(s) A01Backup\SiteDBServer. SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    Error: Backup Failed  for Component - CM_A01. SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    STATMSG: ID=5059 SEV=E LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:18:33.770 2019 ISTR0="" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    LogEvent(): Successfully logged Event to NT Event Log. (4 - 48 - 3,221,230,531) SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    Info: Starting asynchronous BackupComplete... SMS_SITE_BACKUP 7/16/2019 12:18:33 AM 30668 (0x77CC)
    Info: Asynchronous BackupComplete finished. SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    ERROR: BackupComplete failed. Error message - ERROR: CopyFile to F:\SMSBackup\A01Backup\SiteDBServer failed: [error code: 21, error message: The device is not ready.] SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    STATMSG: ID=5048 SEV=E LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:18:35.478 2019 ISTR0="" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    StateTable::CState::Handle - (5048:3 2019-07-15 22:18:35.478+00:00) >> (5056:1 2019-07-15 22:03:08.065+00:00) SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    Inbox source is local on PMICHLAUCCM01 SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    CStateMsgReporter::DeliverMessages - Queued message: TT=1401 TIDT=0 TID='EF736CF9-7214-4796-9C85-2549A9056D8D' SID=5048 MUF=0 PCNT=2, P1='A01' P2='2019-07-15 22:18:35.478+00:00' P3='' P4='' P5='' SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    CStateMsgReporter::DeliverMessages - Created state message file: E:\Program Files\Microsoft Configuration Manager\inboxes\auth\statesys.box\incoming\wi7ila71.SMX SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    Successfully send state change notification EF736CF9-7214-4796-9C85-2549A9056D8D SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    LogEvent(): Successfully logged Event to NT Event Log. (1 - 48 - 3,221,230,520) SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    SMS_SITE_BACKUP failed. Please see previous errors. SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    STATMSG: ID=5060 SEV=E LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:18:35.505 2019 ISTR0="ERROR: BackupComplete failed. Error message - ERROR: CopyFile to F:\SMSBackup\A01Backup\SiteDBServer failed: [error code: 21, error message: The device is not ready.]" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    SMS_SITE_BACKUP service is stopping. SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    STATMSG: ID=502 SEV=I LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:18:35.509 2019 ISTR0="SMS_SITE_BACKUP" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    Raised backup task failure alert. SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    SMS_SITE_BACKUP service stopped. SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)
    STATMSG: ID=501 SEV=I LEV=M SOURCE="SMS Server" COMP="SMS_SITE_BACKUP" SYS=PMICHLAUCCM01.PMINTL.NET SITE=A01 PID=36452 TID=30668 GMTDATE=Mon Jul 15 22:18:35.579 2019 ISTR0="SMS_SITE_BACKUP" ISTR1="" ISTR2="" ISTR3="" ISTR4="" ISTR5="" ISTR6="" ISTR7="" ISTR8="" ISTR9="" NUMATTRS=0 SMS_SITE_BACKUP 7/16/2019 12:18:35 AM 30668 (0x77CC)

    Tuesday, July 16, 2019 10:52 AM
  • Hello, 
     
    From the log, "ERROR: CopyFile to F:\SMSBackup\A01Backup\SiteDBServer failed: [error code: 21, error message: The device is not ready.]
     
    The device is not ready, so where is your F drive located?
     
    Error code 21 means that Windows is in the process of removing the device. However, the device has not yet been completely removed. This error code is temporary, and exists only during the attempts to query and then remove a device.
     
    Error codes in Device Manager in Windows
      
    Best Regards,
    Ray
     

    Please remembers to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Tuesday, July 16, 2019 11:19 AM
  • Hello Ray,

    F drive is located locally. what needs to be done now to get this solved?

    Tuesday, July 16, 2019 11:31 AM
  • From your log you posted it seems you have the Database on the Primary Site Server. You also configured a local path for your backup, correct ?

    From:
    https://docs.microsoft.com/en-us/sccm/core/servers/manage/backup-and-recovery

    Local drive on site server for site data and database: Specifies that the task stores the backup files for the site and site database in the specified path on the local disk drive of the site server. Create the local folder before the backup task runs. The Local System account on the site server must have WriteNTFS file permissions to the local folder for the site server backup. The Local System account on the computer that's running SQL Server must have WriteNTFS permissions to the folder for the site database backup.

    Check the permissions on the folder and/or rename the folder. Then start the SMS_SITE_BACKUP service and wait for it to stop again.


    I'm not entirely sure, but if you run the SQL service under a specific account, i think you may need to grant that account modify permissions on the folder too.
    Tuesday, July 16, 2019 12:14 PM
  • Hello Matthijis,

    Yes its configured locally.

    What can be done to fix the error 21?

    Tuesday, July 16, 2019 12:35 PM
  • Check the permissions on the folder where it stores the backup. You're missing something there, that's almost always the case with errors such as these. Your log says it can't copy the database:

    Error: Failed to backup \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy166\MSSQL2012\DATA\MSSQLSERVER\CM_A01.mdf up to F:\SMSBackup\A01Backup\SiteDBServer: ERROR: CopyFile to F:\SMSBackup\A01Backup\SiteDBServer failed: [error code: 21, error message: The device is not ready.].

    So check what account runs your SQL service, and grant it modify permission on F:\SMSBackup\A01Backup\

    Then let your backup run again (schedule it 5 minutes into the future or so).
    Tuesday, July 16, 2019 12:43 PM
  • Hello,
     
    Are there errors in the smswriter.log?
     
    Best Regards,
    Ray

    Please remembers to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Tuesday, July 16, 2019 12:58 PM
  • Hello Matthijis,

    The SQL backup service runs on local system account and the system account has full permissions granted to the folder.

    Tuesday, July 16, 2019 1:24 PM
  • Hello Ray,

    There are no errors in the smswriter.log

    Tuesday, July 16, 2019 1:24 PM
  • Hello Kalyan,

    There are no files and folders in it. Have NTFS permissions already

    Tuesday, July 16, 2019 1:25 PM
  • Do you have any antivirus running an on-access scan or so?

    If so, check that both source and target locations are excluded.

    For details, see also:
    https://blogs.technet.microsoft.com/systemcenterpfe/2017/05/24/configuration-manager-current-branch-antivirus-update/

    Wednesday, July 17, 2019 8:50 AM
  • Hello Matthijis,

    The source and target locations are already excluded in Antivirus. The manual backup succeeds but only the scheduled backup fails and its wierd.

    Wednesday, July 17, 2019 10:00 AM
  • Honestly, stop using the built-in backup task and use a native SQL backup task which is far more flexible and capable in combination with an enterprise backup solution to backup the SQL backup file as well as other complementary items from the file system like cd.latest, the content library, source files, etc. It'll work far better and easily grabs everything you need while the backup task only grabs part of what you need.

    Jason | https://home.configmgrftw.com | @jasonsandys

    • Marked as answer by Thang Raj Thursday, July 18, 2019 8:22 AM
    Wednesday, July 17, 2019 8:22 PM