System.Exception: 401 - access_denied

I"m getting the following failure every time I run Duplicati (2.1.0.5_stable_2025-03-04)

  • It runs for quite a while, but errors out before actually backing up any files.
  • I’m on an Intel Mac running Sequoia 15.5.
  • I backing up to BackBlaze (and the connection is verified)
  • I set Backup Retention = Keep all backups.

I’ve looked thru a bunch of forum posts, but haven’t found anything that seem related.

Any help would be much appreciated.

System.Exception: 401 - access_denied: Access Denied
at Duplicati.Library.Main.BackendManager.Delete(String remotename, Int64 size, Boolean synchronous)
at Duplicati.Library.Main.Operation.FilelistProcessor.RemoteListAnalysis(BackendManager backend, Options options, LocalDatabase database, IBackendWriter log, IEnumerable1 protectedFiles) at Duplicati.Library.Main.Operation.FilelistProcessor.VerifyRemoteList(BackendManager backend, Options options, LocalDatabase database, IBackendWriter log, IEnumerable1 protectedFiles, Boolean logErrors)
at Duplicati.Library.Main.Operation.BackupHandler.PreBackupVerify(String backendurl, Options options, BackupResults result)
at Duplicati.Library.Main.Operation.BackupHandler.RunAsync(String sources, IFilter filter, CancellationToken token)
at CoCoL.ChannelExtensions.WaitForTaskOrThrow(Task task)
at Duplicati.Library.Main.Operation.BackupHandler.Run(String sources, IFilter filter, CancellationToken token)
at Duplicati.Library.Main.Controller.<>c__DisplayClass17_0.b__0(BackupResults result)
at Duplicati.Library.Main.Controller.RunAction[T](T result, String& paths, IFilter& filter, Action`1 method)
at Duplicati.Library.Main.Controller.Backup(String inputsources, IFilter filter)
at Duplicati.Server.Runner.Run(IRunnerData data, Boolean fromQueue)

Welcome to the forum @sgerardkr

Is this an initial backup, an old backup that suddenly had trouble, or what?

I’ll assume that’s the storage type you chose. Backblaze also supports S3 these days.

If you mean the Test connection, it’s a very basic check, usually just login for file list.

RemoteListAnalysis would also be looking at the file list, and reacting to what’s seen.

Backblaze seems like it doesn’t like the file deletion. It can be set up to block those, but default for an application key would not do that. Did you configure key in a special way?

If it’s been awhile and you forgot, you could set up another key to see if it can do delete.

You can also test put and delete using BackendTool and some filename named so it doesn’t look like a Duplicati file (typically beginning with duplicati-). For a full test, the BackendTester can test an empty folder. Start with Export As Command-line for a URL.

For a better view of what leads up to the failed Delete, watch About → Show log → Live → Information. There’s presumably a reason for a delete, but why B2 refused is the mystery.

Specifically this part says that Duplicati does not have permissions to delete files on B2.

If a transfer fails, Duplicati will make a new filename (never overwrite) and repeat the upload.
In some cases the failure will leave a (partial) file on the remote storage that needs to be deleted.
Could it be the case here that Duplicati wants to delete that specific file, but you do not grant it permission to do so?