SMB file shares not connecting - Duplicati as Service

Just spotted this thread and it reminded me I needed to set up a backup on my main machine that was local and not just to the cloud. I too am on Win 10 build 2004, and my destination is a Windows 2019 core server, on my AD domain and the SMB share is running on a ReFS formatted Storage Spaces volume.

Duplicati is build 2.0.5.107_canary_2020-05-26 and is running as a service under Local System. The backup job specifies a domain username/passsword for access.

All is running well so far and I have no issues - files are being created in the share as I write. Will update this once the job is finished either way.

Iā€™m wondering if domain membership is a factor. Itā€™s possible the security change only affects non-domain joined machines.

I believe the reason your scenario works is because of the known-device relationships implicit in domain membership. If you were to back up from/to non-joined machines on a fresh Windows install, such as from an non-joined fresh Windows install to a non-joined Linux machine via Samba, I believe you would have a different experience. Something changed in version 2004 that has created problems. If you can try that, would you please let us know what happens?

Just did that, workgroup installation, used the same domain account as on my main PC for the credentials to the same SMB share just a different sub-folder, although Iā€™m all Windows here for the most part so no Samba, and still works:

{
  "DeletedFiles": 0,
  "DeletedFolders": 0,
  "ModifiedFiles": 0,
  "ExaminedFiles": 3,
  "OpenedFiles": 2,
  "AddedFiles": 2,
  "SizeOfModifiedFiles": 0,
  "SizeOfAddedFiles": 23928494,
  "SizeOfExaminedFiles": 23928668,
  "SizeOfOpenedFiles": 23928494,
  "NotProcessedFiles": 0,
  "AddedFolders": 1,
  "TooLargeFiles": 0,
  "FilesWithError": 0,
  "ModifiedFolders": 0,
  "ModifiedSymlinks": 0,
  "AddedSymlinks": 0,
  "DeletedSymlinks": 0,
  "PartialBackup": false,
  "Dryrun": false,
  "MainOperation": "Backup",
  "CompactResults": null,
  "VacuumResults": null,
  "DeleteResults": null,
  "RepairResults": null,
  "TestResults": {
    "MainOperation": "Test",
    "VerificationsActualLength": 3,
    "Verifications": [
      {
        "Key": "duplicati-20200630T162909Z.dlist.zip",
        "Value": []
      },
      {
        "Key": "duplicati-ie2ef0103578642eb8ba2917d74d8772c.dindex.zip",
        "Value": []
      },
      {
        "Key": "duplicati-bb21f094b8fbb421087f6d030c763c402.dblock.zip",
        "Value": []
      }
    ],
    "ParsedResult": "Success",
    "Version": "2.0.5.107 (2.0.5.107_canary_2020-05-26)",
    "EndTime": "2020-06-30T16:29:11.8085959Z",
    "BeginTime": "2020-06-30T16:29:11.2923968Z",
    "Duration": "00:00:00.5161991",
    "MessagesActualLength": 0,
    "WarningsActualLength": 0,
    "ErrorsActualLength": 0,
    "Messages": null,
    "Warnings": null,
    "Errors": null,
    "BackendStatistics": {
      "RemoteCalls": 8,
      "BytesUploaded": 22925071,
      "BytesDownloaded": 22925071,
      "FilesUploaded": 3,
      "FilesDownloaded": 3,
      "FilesDeleted": 0,
      "FoldersCreated": 0,
      "RetryAttempts": 0,
      "UnknownFileSize": 0,
      "UnknownFileCount": 0,
      "KnownFileCount": 6,
      "KnownFileSize": 22927657,
      "LastBackupDate": "2020-06-30T18:29:09+02:00",
      "BackupListCount": 2,
      "TotalQuotaSpace": 5994633494528,
      "FreeQuotaSpace": 1910532800512,
      "AssignedQuotaSpace": -1,
      "ReportedQuotaError": false,
      "ReportedQuotaWarning": false,
      "MainOperation": "Backup",
      "ParsedResult": "Success",
      "Version": "2.0.5.107 (2.0.5.107_canary_2020-05-26)",
      "EndTime": "0001-01-01T00:00:00",
      "BeginTime": "2020-06-30T16:29:09.5267385Z",
      "Duration": "00:00:00",
      "MessagesActualLength": 0,
      "WarningsActualLength": 0,
      "ErrorsActualLength": 0,
      "Messages": null,
      "Warnings": null,
      "Errors": null
    }
  },
  "ParsedResult": "Success",
  "Version": "2.0.5.107 (2.0.5.107_canary_2020-05-26)",
  "EndTime": "2020-06-30T16:29:11.8242474Z",
  "BeginTime": "2020-06-30T16:29:09.5267385Z",
  "Duration": "00:00:02.2975089",
  "MessagesActualLength": 17,
  "WarningsActualLength": 0,
  "ErrorsActualLength": 0,
  "Messages": [
    "2020-06-30 18:29:09 +02 - [Information-Duplicati.Library.Main.Controller-StartingOperation]: The operation Backup has started",
    "2020-06-30 18:29:09 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: List - Started:  ()",
    "2020-06-30 18:29:09 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: List - Completed:  (3 bytes)",
    "2020-06-30 18:29:10 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Put - Started: duplicati-bb21f094b8fbb421087f6d030c763c402.dblock.zip (21.85 MB)",
    "2020-06-30 18:29:10 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Put - Started: duplicati-20200630T162909Z.dlist.zip (979 bytes)",
    "2020-06-30 18:29:10 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Put - Completed: duplicati-20200630T162909Z.dlist.zip (979 bytes)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Put - Completed: duplicati-bb21f094b8fbb421087f6d030c763c402.dblock.zip (21.85 MB)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Put - Started: duplicati-ie2ef0103578642eb8ba2917d74d8772c.dindex.zip (15.98 KB)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Put - Completed: duplicati-ie2ef0103578642eb8ba2917d74d8772c.dindex.zip (15.98 KB)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: List - Started:  ()",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: List - Completed:  (6 bytes)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Get - Started: duplicati-20200630T162909Z.dlist.zip (979 bytes)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Get - Completed: duplicati-20200630T162909Z.dlist.zip (979 bytes)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Get - Started: duplicati-ie2ef0103578642eb8ba2917d74d8772c.dindex.zip (15.98 KB)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Get - Completed: duplicati-ie2ef0103578642eb8ba2917d74d8772c.dindex.zip (15.98 KB)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Get - Started: duplicati-bb21f094b8fbb421087f6d030c763c402.dblock.zip (21.85 MB)",
    "2020-06-30 18:29:11 +02 - [Information-Duplicati.Library.Main.BasicResults-BackendEvent]: Backend event: Get - Completed: duplicati-bb21f094b8fbb421087f6d030c763c402.dblock.zip (21.85 MB)"
  ],
  "Warnings": [],
  "Errors": [],
  "BackendStatistics": {
    "RemoteCalls": 8,
    "BytesUploaded": 22925071,
    "BytesDownloaded": 22925071,
    "FilesUploaded": 3,
    "FilesDownloaded": 3,
    "FilesDeleted": 0,
    "FoldersCreated": 0,
    "RetryAttempts": 0,
    "UnknownFileSize": 0,
    "UnknownFileCount": 0,
    "KnownFileCount": 6,
    "KnownFileSize": 22927657,
    "LastBackupDate": "2020-06-30T18:29:09+02:00",
    "BackupListCount": 2,
    "TotalQuotaSpace": 5994633494528,
    "FreeQuotaSpace": 1910532800512,
    "AssignedQuotaSpace": -1,
    "ReportedQuotaError": false,
    "ReportedQuotaWarning": false,
    "MainOperation": "Backup",
    "ParsedResult": "Success",
    "Version": "2.0.5.107 (2.0.5.107_canary_2020-05-26)",
    "EndTime": "0001-01-01T00:00:00",
    "BeginTime": "2020-06-30T16:29:09.5267385Z",
    "Duration": "00:00:00",
    "MessagesActualLength": 0,
    "WarningsActualLength": 0,
    "ErrorsActualLength": 0,
    "Messages": null,
    "Warnings": null,
    "Errors": null
  }
}

{
  "CreatedByVersion": "2.0.5.107",
  "Schedule": null,
  "Backup": {
    "ID": "1",
    "Name": "Test SMB Backup",
    "Description": "",
    "Tags": [],
    "TargetURL": "file://\\\\LISA\\NELSON\\DUPLICATI\\TEST\\?auth-username=star-one\\administrator",
    "DBPath": "C:\\Windows\\system32\\config\\systemprofile\\AppData\\Local\\Duplicati\\PRWBADBPGD.sqlite",
    "Sources": [
      "C:\\Users\\Public\\Downloads\\",
      "C:\\Users\\TestAccount\\Desktop\\Downloads\\"
    ],
    "Settings": [
      {
        "Filter": "",
        "Name": "encryption-module",
        "Value": "",
        "Argument": null
      },
      {
        "Filter": "",
        "Name": "compression-module",
        "Value": "zip",
        "Argument": null
      },
      {
        "Filter": "",
        "Name": "dblock-size",
        "Value": "50mb",
        "Argument": null
      },
      {
        "Filter": "",
        "Name": "--no-encryption",
        "Value": "true",
        "Argument": null
      }
    ],
    "Filters": [],
    "Metadata": {
      "LastBackupDate": "20200630T162909Z",
      "BackupListCount": "2",
      "TotalQuotaSpace": "5994633494528",
      "FreeQuotaSpace": "1910532800512",
      "AssignedQuotaSpace": "-1",
      "TargetFilesSize": "22927657",
      "TargetFilesCount": "6",
      "TargetSizeString": "21.87 MB",
      "SourceFilesSize": "23928668",
      "SourceFilesCount": "3",
      "SourceSizeString": "22.82 MB",
      "LastBackupStarted": "20200630T162909Z",
      "LastBackupFinished": "20200630T162911Z",
      "LastBackupDuration": "00:00:02.2975089",
      "LastCompactDuration": "00:00:00.0312446",
      "LastCompactStarted": "20200630T162656Z",
      "LastCompactFinished": "20200630T162656Z"
    },
    "IsTemporary": false
  },
  "DisplayNames": {
    "C:\\Users\\Public\\Downloads\\": "Downloads",
    "C:\\Users\\TestAccount\\Desktop\\Downloads\\": "Downloads"
  }
}

There is another thread reporting the same problem here: Working NAS folder suddenly not accessible - Duplicati thinks it does not exist

I dont have this setup but could someone try using the IP Address rather then the dns name. Seems to be DNS issues as well with this update
eg set destination to
\192.168.1.1\sharename

I tried that, as well as the hosts file addition, and neither of those made a difference.

This probably needs narrowing down or finding better info on the failure.

Windows appears to put Connectivity events in event log below, which you can view as an Administrator:

Windows Logs --> Applications and Services Logs --> Microsoft --> Windows --> SMBClient
You can look at all the logs there to look for any information on the error.

If you have a different SMB server (even Windows), does it work better?

Because this appears sensitive to the account, testing it as SYSTEM in a human-friendly way might help.

PsExec run from an Administrator account will let you run many things as SYSTEM, but not File Explorer.

Something like psexec -s -i cmd.exe runs Command Prompt. Run whoami to verifyy system account.
From there you see if things like net use work, and if they donā€™t, do they (or event log) report their issues?

powershell.exe is reported to do UNC well, unlike cmd.exe, so maybe try something like this as SYSTEM:
Get-ChildItem <UNC path>

I may have a work around for this.
Tested on Windows 10 2004 to Centos 6 systems. Samba 3.6.1 with SMB1 disabled and using SMB2

As suggested when running net use under system with psexec no joy in creating the share. Ran a wire shark trace noticed that the username was not been populated on the NTLM Auth response

Entered the full user name as HOSTNAME\User and it worked. Tried the same in Duplicati and it then came back with a successful test connection.

2 Likes

That worked for me.

Duplicati machine is Win 10 Pro 2004, target is a Debian server running SMB2. I stopped the service, went to properties and switched it to Local System, applied the changes, and ran the service. I verified in Task Manager that it was running under the system account. Then I edited the credentials from just ā€œuser1ā€ to ā€œDEBIANSERVERHOSTNAME\user1ā€, and it worked.

Might be good to clarify the help tip in the UI to advise users to try hostname\username format in the credentials.

Thank you for your help!

SERVERNAME\user works for me also! Thanks