FFS hanging on Volume Shadow Copy when not actively using my Windows account

Get help for specific problems
Posts: 4
Joined: 11 Mar 2021

SteveMagruder

This may be a problem I've solved but I want to explain what I did as a sounding board to see if I did the right thing.

On my Windows main account with administrator privileges, I'm running a FFS batch from Task Scheduler to mirror a number of folders on an external backup drive. As part of this, I have "Copy locked files" checked, which appears to do a Volume Shadow Copy (VSC) to be able to handle that. It seems that periodically, when my account is signed in but not active (like the PC has been switched to another user), it gets stuck on the VSC and the task in Task Scheduler is stopped after an hour (which it's set to do). And then I'm stuck with locks on all the folders, both original and backup, which have to be deleted before I can run this FFS batch again. Also, this issue sometimes leaves my NVMe SSD in a state that needs to be repaired by Windows (oddly, I do a similar backup of another laptop with SATA SSD and this problem doesn't occur much if at all).

After poking around, I determined that my problem is likely that while I have always had the task run with highest privileges (necessary for VSC), I needed to check "Run whether user is logged on or not". So I checked that, and I will know soon if this solves the problem.

Does that sound like the correct fix or do I need to look at something else as well?
Last edited by SteveMagruder on 16 Jul 2021, 17:44, edited 1 time in total.
Posts: 4
Joined: 11 Mar 2021

SteveMagruder

I updated this post to say Task Scheduler rather than Task Manager. Whoops.
User avatar
Posts: 3551
Joined: 11 Jun 2019

xCSxXenon

Yes, you will need to check that for it to run when you aren't logged in. The odd thing is that it dirties the volume. Is this when another user is actively logged in or just when you are logged out?
Posts: 4
Joined: 11 Mar 2021

SteveMagruder

I'm not really sure as I haven't recorded what state the PC was in when FFS stalled. I just knew it was when I wasn't using my account.
User avatar
Site Admin
Posts: 7040
Joined: 9 Dec 2007

Zenju

When you select "Run whether user is logged on or not" this means the task is run under the SYSTEM account. Note that FFS saves/loads its global settings, one of which is Copy locked files, relative to the current active user: https://freefilesync.org/manual.php?topic=schedule-batch-jobs
For the SYSTEM account the location is: C:\Windows\System32\config\systemprofile\AppData\Roaming\FreeFileSync

In other words, when you select "Run whether user is logged on or not", then Volume Shadow Copy is very likely disabled, because this is the default value, and you never changed it (for this user).
User avatar
Site Admin
Posts: 7040
Joined: 9 Dec 2007

Zenju

It seems that periodically, when my account is signed in but not active (like the PC has been switched to another user), it gets stuck on the VSC and the task in Task Scheduler is stopped after an hour (which it's set to do). SteveMagruder, 16 Jul 2021, 16:07
It's possible the sync job is hanging because it's showing a popup dialog: https://freefilesync.org/manual.php?topic=schedule-batch-jobs

If it is hanging for any other reason, maybe you can manage to create a crash dump at that time? https://freefilesync.org/faq.php#crash
Posts: 4
Joined: 11 Mar 2021

SteveMagruder

My scheduled FFS batch job has seemed to run more smoothly, except for one hiccup, since selecting "Run whether user is logged on or not" but I recall I also recently set a couple more of its mirror processes to ignore errors. Perhaps if I ignore errors on all of the mirrors in the job, that will fully eliminate the hiccups. I'll try that before looking at dumps. At any rate, I like how the "Run whether..." setting makes the process less disruptive while I'm using the PC.

As for the task running under the SYSTEM account, nothing is showing up at C:\Windows\System32\config\systemprofile\AppData\Roaming\FreeFileSync. At any rate, the task for me, most of the time, is running to completion.