Upgrading to latest version

Hello,

Duplicati repeatedly fails to upgrade from version 2.0.5.110_canary_2020-08-10

The message is the same each time, here’s the latest log:

6 oct. 2020 22:50: Error in updater
System.UnauthorizedAccessException: L’accès au chemin d’accès ‘C:\ProgramData\Duplicati\updates\current’ est refusé.
à System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
à System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
à System.IO.FileStream…ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
à System.IO.StreamWriter.CreateFile(String path, Boolean append, Boolean checkHost)
à System.IO.StreamWriter…ctor(String path, Boolean append, Encoding encoding, Int32 bufferSize, Boolean checkHost)
à System.IO.File.InternalWriteAllText(String path, String contents, Encoding encoding, Boolean checkHost)
à Duplicati.Library.AutoUpdater.UpdaterManager.DownloadAndUnpackUpdate(UpdateInfo version, Action`1 progress)

Thanks for any help, I’d like to avoid uninstalling/reinstalling Duplicati…

I personally don’t use the auto updater so I can’t comment on your issue, but you can download the latest MSI for 2.0.5.111 and upgrade that way. It’s how I always do upgrades.

Uninstalling doesn’t remove any Duplicati configuration or backup data, if that’s what you’re worried about. Uninstalling isn’t necessary when upgrading with a newer MSI.

Welcome to the forum @allp

Was your 2.0.5.110 your initial install (by running the .msi installer) or an earlier autoupdate?

I can’t think of how 2.0.5.111 is any different an autoupdate, but autoupdate itself is different.

Your user requires permission to the indicated file. Can you drag it into notepad and save it?

I think I spot a potential problem if your user account is not the one that did prior autoupdate.
You might not have write permission to the file because ProgramData defaults to not give it.

Right-click C:\ProgramData\Duplicati\updates\cuurent --> Properties --> Security --> Advanced
will show the file Owner near the top, then say what they and other parties are allowed to do.

If there’s an issue with the autoupdater when Duplicati user changes, it’d be nice to know it.
From a how-to-get-going view, the .msi reinstall should work. I don’t think it touches that file.

Thanks drwtsn32 for the suggestion and for confirming that uninstalling doesn’t remove any configuration or backup data, I used the MSI and now have the latest version installed.

Thanks ts678 for the welcome, I appreciate the quick support.

Now to your questions: Duplicati upgrades via autoupdate worked fine until 2.0.5.109 or 110, so last Aug, and there was no user account change.
I had noticed the permissions message, tried to remove the folder which was empty I think, didn’t resolve anything.

I’ll confirm back after the next upgrade if autoupdater worked correctly.

Permission question still needs checking. both by rewriting the file and looking at permissions on file.
Duplicati is denied for some reason (maybe permissions), and it would be helpful to understand why.
Although my users theory is weakening, here’s what C:\ProgramData starts with. This inherits down:

In the lower right corner of the permission entries box, you see ordinary unrelated users can’t write file. unlike the file Owner (generally its creator) or Administrators (as opposed to Standard User accounts).

2.0.5.109 had some file handling changes to handle strange Windows paths ending with space or dot acceptably. There have been a few reports of the fix causing problems on some systems. I hope your access problem is some quirk of how the Windows permissions are set up, and not anything weirder.

It gets better, I don’t have a “current” folder currently, as I deleted it when trying to get autoupdater to work, and thinking it would be recreated if needed. That didn’t work, and this folder wasn’t recreated by the MSI either, and Duplicati seems to run fine without it.

Here’s what I have, folders from each version since Dec 2019:

Hope that helps…

According to the Downgrading / reverting to a lower version article, you have a Windows service install.
Does that sound correct? It would be visible as a service, run at boot, and allow access to all accounts.
You would have had to run Duplicati.WindowsService.exe by hand after a .msi install to get that set up.

If you do in fact run as a service as SYSTEM user, then that would have permissions for almost anything, however updates can get there in other setups. Does Task Manager show Duplicati.WindowsService? What user is it? On Database screen, is yours in your own user profile, or in a C:\Windows subfolder?

It’s not a folder, it’s a file. If it was a folder, that would also have created a problem when editing as a file.

Hello,

Does Task Manager show Duplicati.WindowsService? no

image

You would have had to run [Duplicati.WindowsService.exe] by hand after a .msi install to get that set up: definitely did not do that

I don’t have a “current” folder currently / It’s not a folder, it’s a file.:
it was definitely a folder which I deleted, it’s still in the trash bin

On Database screen, is yours in your own user profile, or in a C:\Windows subfolder? It’s in C:\Users\Antoine\AppData\Local\Duplicati\LORRXTTSIS.sqlite

Hope that helps