On 13/09/2022 06:00, Christiaan Heerze wrote:
> I'm trying to backup files that reside in
> C:\USERS\{USERNAME}\AppData\Local\VirtualStore but somehow it's not
> copying the files to my desired location. Same goes for C:\Windows\.
> Other files and folders are being backuped.
The VirtualStore folder is subject to automatic filesystem redirection.
You can disable some of this by enabling 64-bit installation mode, and
ensuring that the installer doesn't have a generic name like "setup.exe".
> I'm also trying to empty C:\Windows\Temp but this is unsuccesfull and
> the same goes for C:\Windows\SoftwareDistribution.
The temp folder likely has files in use, and the SoftwareDistribution
folder is restricted so that even admins can't fiddle with it, since
it's used for Windows Update.
> I'm running setup with admin privileges.
It's not recommended to use software running as admin to access per-user
folders. There are some circumstances under which this will work as
expected, but others where it will not.
> If anyone has any sollution or another program that I can use, that
> would be great.
It sounds like you should be using actual backup software designed for
that purpose. There are specific flags passed to the OS to indicate
that the access is intended for backup purposes, which changes behaviour.
Remember, just making the backup itself is not sufficient; you need to
be able to selectively restore individual files (and possibly to
alternative locations), otherwise recovery may cause more damage than it
solves.
If you're determined to avoid using the correct tools, you could at
least look into using RoboCopy, which has some backup features available.