Windows 10: VssExpressWriter fails to add a folder non monitored files into restore point

Discus and support VssExpressWriter fails to add a folder non monitored files into restore point in Windows 10 Network and Sharing to solve the problem; I'm trying to use VSS Express Writer to include all the files in specific folder in the restore point when it is conducted which are crucial for my app... Discussion in 'Windows 10 Network and Sharing' started by Zohar cabeli, Aug 13, 2019.

  1. VssExpressWriter fails to add a folder non monitored files into restore point


    I'm trying to use VSS Express Writer to include all the files in specific folder in the restore point when it is conducted which are crucial for my app to run.

    Some of the files have extensions (mostly .txt) that is not automatically monitored (see https://docs.microsoft.com/en-us/windows/win32/sr/monitored-file-extensions for all auto monitored extensions).

    So I've wrote a special vssWriter for those files (see https://docs.microsoft.com/en-us/windows/win32/vss/writers) and expected that the OS would call its requester which would add the files at the writer to the restore set..

    After running my code, the writer created successfully and is visible from `vssadmin list writers`. However, the folder isn't kept once i go back to restore point (the files aren't there..)

    Currently my flow goes as follow:

    1. Register using the following code (see below).
    2. Create system restore point.
    3. Delete my folder.
    4. Restart
    5. Restore my system.

    Unfortunately, I dont get my folder back..

    I've tried to summarize the code in the following block :

    int main()
    {
    ::CoInitialize(NULL);

    createAndRegister();

    }

    int createAndRegister()
    {
    CComPtr<IVssExpressWriter> spExpressWriter;
    CComPtr<IVssCreateExpressWriterMetadata> spMetadata;

    CreateVssExpressWriter(&spExpressWriter);

    spExpressWriter->CreateMetadata(EXPRESS_WRITER_SAMPLE_GUID, L"Sample Express Writer", VSS_UT_USERDATA, 1, 0, 0, &spMetadata);

    PCWSTR wszComponent = L"myExpressWriter";


    spMetadata->SetRestoreMethod(
    VSS_RME_RESTORE_AT_REBOOT, ////I've also tried it with different option of this enum
    NULL,
    NULL,
    VSS_WRE_NEVER,
    false),
    L"SetRestoreMethod failed");

    spMetadata->AddComponent(
    VSS_CT_FILEGROUP,
    NULL,
    wszComponent,
    wszComponent,
    NULL,
    0,
    false,
    false,
    false);

    spMetadata->AddFilesToFileGroup(
    NULL,
    wszComponent,
    L"c:\\ProgramData\\myFolder",
    L"*.*",
    true,
    NULL,
    NULL),


    spExpressWriter->Register();
    }



    I am wondering if there is a need to implement a requester to add the files to restore properly (https://docs.microsoft.com/en-us/windows/win32/vss/requestors).

    Perhaps anyone can tell me where did i go wrong in my flow ? Maybe there are higher level API (C#, powershell) to do so ?

    Thanks

    :)
     
    Zohar cabeli, Aug 13, 2019
    #1
  2. Anne Ros Win User

    Windows 10 System Restore Show More Restore Points Box Missing and Restore Points Being Deleted or Missing

    Hi Steven,

    There are several reasons why the Show more restore points check box is missing. Some of these are the following:

    • You run out of disk space on the system drive or on any one of the available non-system drives, and System Restore stops responding and stops monitoring your system.
    • You manually turn System Restore off.
    • You upgrade from one operating system to another or you reinstall the operating system

    In your case, as you have reinstalled Windows, it's possible that all restore points are deleted, that's why the
    Show more restore points check box is not appearing. Did you delete all the partitions when you reinstall Windows? If yes, then all the manually and automatically created restore points will disappear. For further isolation of the issue, we suggest that
    you create a new restore point and monitor if it will disappear in a few days just like the others.

    We'll wait for your response.
     
    Anne Ros, Aug 13, 2019
    #2
  3. Rose Cal Win User
    File History Full Restore Fails Due To Shortened User Folder Name

    We appreciate your response. If you have files or folders elsewhere that you want backed up, you can add them to one of these folders.

    Meanwhile, we suggest that you follow these steps on how to restore files and folders using File History:

    • Swipe in from the right edge of the screen, tap Search (or if you're using a mouse, point to the upper-right corner of the screen, move the mouse pointer down, and then click Search), enter restore your files in
      the search box, and then select Restore your files with File History.
    • Enter the name of file you're looking for in the search box, or use the left and right arrows to browse through different versions of your folders and files.
    • Select what you want to restore to its original location, and then select the Restore button.

    If you want to restore your files to a different location than the original, press and hold or right-click the Restore button, select Restore To, and then choose a new location.

    You may also check this article for more information about backing up and restoring files.

    Let us know if you need further assistance.
     
    Rose Cal, Aug 13, 2019
    #3
  4. VssExpressWriter fails to add a folder non monitored files into restore point

    Windows Restore failed to extract the file xxxx from the restore point

    After selecting the restore point the system attempts to recover but fails with the above error then states an unspecified error 0x8007025d has occurred.

    I have checked the file name given in the first error and it is present in the \Windows\WinSxS\Backup folder but I don't know how to verify it's contents. Running sfc reports no errors. I've tried disabling AV software and running from safemode but I always
    get the same error, I have tried different restore points too.

    Can anyone suggest what else to try?

    Thanks

    Gary
     
    GaryMordue, Aug 13, 2019
    #4
Thema:

VssExpressWriter fails to add a folder non monitored files into restore point

Loading...
  1. VssExpressWriter fails to add a folder non monitored files into restore point - Similar Threads - VssExpressWriter fails add

  2. Restore point failed

    in Windows 10 Gaming
    Restore point failed: Hello.i try to restore point after unistallation of asus armoury crate and the process stack for hours to restore windows registry.I have norton 360 and disable tamber protection...
  3. Restore point failed

    in Windows 10 Software and Apps
    Restore point failed: Hello.i try to restore point after unistallation of asus armoury crate and the process stack for hours to restore windows registry.I have norton 360 and disable tamber protection...
  4. System Restore failed to extract the file C:\$Extend\$Deleted from the restore point.

    in Windows 10 Gaming
    System Restore failed to extract the file C:\$Extend\$Deleted from the restore point.: System Restore failed to extract the file C:\$Extend\$Deleted from the restore point.An unspecified error occurred during System Restore. 0x80070005im getting these errors when trying to go back to a restore point, what do i do?...
  5. Restore Windows when restore point failed

    in Windows 10 Gaming
    Restore Windows when restore point failed: My laptop is caught in the automatic repair loop, and when I tried to restore a restore point, that method somehow failed. I planned to give it another try but the system showed no restore point was made.Is there another way to restore my Windows apart from the restore point?...
  6. Restore Windows when restore point failed

    in Windows 10 Software and Apps
    Restore Windows when restore point failed: My laptop is caught in the automatic repair loop, and when I tried to restore a restore point, that method somehow failed. I planned to give it another try but the system showed no restore point was made.Is there another way to restore my Windows apart from the restore point?...
  7. Restore Windows when restore point failed

    in Windows 10 Installation and Upgrade
    Restore Windows when restore point failed: My laptop is caught in the automatic repair loop, and when I tried to restore a restore point, that method somehow failed. I planned to give it another try but the system showed no restore point was made.Is there another way to restore my Windows apart from the restore point?...
  8. Restore point failing

    in Windows 10 Installation and Upgrade
    Restore point failing: Topic says it all. I am trying to restore to an earlier point and it never gets past “initializing” the VERY second it attempt to begin, the PC reboots and give me an error “could not restore from earlier point”My reason for doing this is I followed a guide that was suppose...
  9. System Restore point failed

    in Windows 10 BSOD Crashes and Debugging
    System Restore point failed: I tried doing system restore point, In the process I got stuck so I did force shutdown, later laptop turned on, but I can't install any software and not even able to open Microsoft office. I tried sfc /scannow and DISM.exe /Online /Cleanup-image /Restorehealth also but there...
  10. "System Restore failed to extract the file (...\OneDrive) from the restore point."

    in Windows 10 BSOD Crashes and Debugging
    "System Restore failed to extract the file (...\OneDrive) from the restore point.": Since updating to Windows 1803, system protection does not work. Restore will not restore from the restore point created during the update. Nor will it restore from any new restore point I create. I get the message: System Restore did not complete successfully. Your...