Solved

VBR and Nextcloud folders backup


Userlevel 1

Hey there. 

I use Community edition for my home lab and photo archive backup proposals. VBR is installed on my PC, it was added to Veeam as a File Server, some folders were added to the job, and everything was fine until I added these folders to sync with my Nextcloud (real files are always on device).

Now I faced this error:

08.01.2024 22:43:43 :: Unable to backup \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy12\Pict\Filmscan. Incorrect function.
Failed to read data from the file [\\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy12\Pict\Filmscan].

There are job logs from C:\ProgramData\Veeam\Backup.

Does anybody knows, how to resolve it?

 

icon

Best answer by Aleksej_Egorov 9 January 2024, 16:43

View original

10 comments

Userlevel 7
Badge +6

I’m assuming this is using the Veeam Agent for Windows, and not Veeam Backup & Replication, correct?

Userlevel 7
Badge +20

Is there a running application that keeps the file location open or reading them?

Userlevel 1

I’m assuming this is using the Veeam Agent for Windows, and not Veeam Backup & Replication, correct?

Seems no. Veeam Backup and Replication is installed on my desktop. I configured file share backup job, like described in this article and added the same PC as file server following this manual. If you mean file-level backup with agent policy, this was workaround for me, and it works, but I want to understand, why the first way fails. 

Is there a running application that keeps the file location open or reading them?

Nextcloud client is still running, when job started, yes. Do you think I must stop it with script before job starts?

Userlevel 7
Badge +20

I’m assuming this is using the Veeam Agent for Windows, and not Veeam Backup & Replication, correct?

Seems no. Veeam Backup and Replication is installed on my desktop. I configured file share backup job, like described in this article and added the same PC as file server following this manual. If you mean file-level backup with agent policy, this was workaround for me, and it works, but I want to understand, why the first way fails. 

Is there a running application that keeps the file location open or reading them?

Nextcloud client is still running, when job started, yes. Do you think I must stop it with script before job starts?

I would try to see if the backup will run with it turned off.  It could be locking the files and folders.

Userlevel 1

@Chris.Childerhose, thanks for the advice, but no luck. I found that the nextcloud client sets the archive attribute for synced folders, disabling it also has no effect. Process Explorer does not show any handles.

I found this string in Task.Computername.log: 

[08.01.2024 18:09:38.271] <23> Info                   [AP] (a460897b) output: --nasbackup:ErrorMessage;VW5hYmxlIHRvIGJhY2t1cCBcXD9cR0xPQkFMUk9PVFxEZXZpY2VcSGFyZGRpc2tWb2x1bWVTaGFkb3dDb3B5OVxQaWN0XEZpbG1zY2FuLiBJbmNvcnJlY3QgZnVuY3Rpb24uCkZhaWxlZCB0byByZWFkIGRhdGEgZnJvbSB0aGUgZmlsZSBbXFw/XEdMT0JBTFJPT1RcRGV2aWNlXEhhcmRkaXNrVm9sdW1lU2hhZG93Q29weTlcUGljdFxGaWxtc2Nhbl0uCi0tdHI6RXJyb3IgY29kZTogMHgwMDAwMDAwMQotLXRyOkZhaWxlZCB0byBpbnRpYWxpemUgZGF0YSBzdHJlYW0=;2

This base64 string is:

Unable to backup \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy9\Pict\Filmscan. Incorrect function.
Failed to read data from the file [\\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy9\Pict\Filmscan].
--tr:Error code: 0x00000001
--tr:Failed to intialize data stream

Maybe it will help? I have no ideas yet.

Userlevel 7
Badge +20

Hmmm corrupt data possibly?  Not sure what else to suggest at this point other than creating a support case for further assistance.  They will be able to read the logs much better. 😁

Userlevel 1

No, files are healthy.

  1. I can open, edit, view and save any of them as usual.
  2. And when I remove folder from sync — job succeed. 

 Still there are no ideas ¯\_(ツ)_/¯

 
Userlevel 7
Badge +20

No, files are healthy.

  1. I can open, edit, view and save any of them as usual.
  2. And when I remove folder from sync — job succeed. 

 Still there are no ideas ¯\_(ツ)_/¯

 

So when you remove the folder from sync the job works - that tells me something is locking it preventing the backup from running correctly.  That is the direction to investigate.

Userlevel 1

Okay, fixed.

Short answer is this button in Nextcloud client:

Long answer is that nextcloud client can work in 2 modes, with and without virtual files support. In the fist case directory is not regular directory, but reparse pont. The similar issue was discussed on nextcloud forums. We can see this with powershell (take a look on Mode property):

PS C:\> (gi 'L:\Pict\Filmscan\') | select *Mode*,*Target*,Attributes

Mode                : lar--
ModeWithoutHardLink : lar--
UnixFileMode        : -1
ResolvedTarget      : L:\Pict\Filmscan\
Target              :
LinkTarget          :
Attributes          : 525361

But, when we disable virtual files support, all files always stored locally, and mode changes from link to directory:

PS C:\> (gi 'L:\Pict\Filmscan\') | select *Mode*,*Target*,Attributes

Mode : dar--
ModeWithoutHardLink : dar--
UnixFileMode : -1
ResolvedTarget : L:\Pict\Filmscan\
Target :
LinkTarget :
Attributes : 524337

Now job runs without errors, thank you for your replies.

Userlevel 7
Badge +20

Glad to hear you fixed it and posted the answer. 👍🏼

Comment