Symbolic Links: Restore completed without errors but no files were restored


I found no corresponding post here.

I backuped a WIN10 directory with regular files.

One files in this dir is a symbolic link to another local file on a different drive.

Trying to restore this file in an alternate directory I get:

2021-12-31 12:10:12 +01 - [Verbose-Duplicati.Library.Main.Operation.RestoreHandler-MappingRestorePath]: Mapping restore path prefix to “” to “d:\TMP\Duplicati”
2021-12-31 12:10:12 +01 - [Verbose-Duplicati.Library.Main.Database.LocalRestoreDatabase-RestoreSourceSize]: Restore list contains 0 blocks with a total size of 0 Bytes
2021-12-31 12:10:13 +01 - [Warning-Duplicati.Library.Main.Operation.RestoreHandler-NoFilesRestored]: Restore completed without errors but no files were restored

The alternate directory dide not contain this file already!


Did you specify the --symlink-policy = Follow option?
Symlink in the manual for a bit more info

I’ll check it.
Fact is, “Store” is the default and should restore the link as link following the documentation. This should occur as well, when I restore in another folder. But, that does not happen.

“Follow” is not what I want. It restores the file as real file.

Can you confirm it’s definitely a symlink and not a junction point? The two have varying limitations, so it could be important.

If it’s a symlink, I believe elevation is required to create them. Is Duplicati running elevated?

Yes. I need the snapshot feature.

The properties tell me, the type is a symlink.

Ok great, thanks for confirming. Let me do some testing and I’ll get back to you!

Thanks a lot and best wishes for the New Year!

Happy Near Year to you as well!

I tested backing up a file symlink, a directory symlink, and a directory junction point. I then restored to a different location and it completed successfully in my test, for the most part.

Only issue I had was that Duplicati doesn’t properly differentiate junction points from directory symlinks, so when it restores it creates junctions as directory symlinks.

It’s easier to see the different types in CMD. Here was the source:

And after I restored to a different blank folder:

If I restore ONLY the symlinks I do get a message that no files were restored.

Also I did confirm that you must have elevated rights to create even these symlinks. I tried restoring as a regular limited user and got the error “A required privilege is not held by the client.”

Thank you very much for confirming!

You have already more experience with dulpicati and perhaps with bug reports on github. Do you think this issue is a valid case for a bug report?

It couldn’t hurt to file one. I’m not sure if it’s actually a bug though. I think the same message is displayed if you restore just an empty directory. Duplicati creates the empty directory but will ultimately give the “no files restored” message if no data files were restored. I am guessing it doesn’t count symlinks as a data file.

If you file a bug report on github then the devs can make that determination.

That’s right.
I think about to create a report.