Cannot connect to Windows share with SMB

English Support for Syncovery on Linux etc.
Post Reply
patanne
Posts: 12
Joined: Wed Mar 10, 2021 2:51 pm

Cannot connect to Windows share with SMB

Post by patanne »

I am trying to use Syncovery Linux to perform a pull backup from a few Windows machines. I cannot get the profile to login to the remote Windows machine using SMB. Eventually we will use SSH but for now SMB is the only way.

Names below have been sanitized, but the construct is accurate. The domain is an internal domain. We manage the top level domain.

Given...
  • libsmbclient has been installed.
  • The remote machine is named, sm-er.customer.hh.
  • The netbios name of the domain is HHC.
  • There is a hidden share on the Windows machine, 'backup$'.
  • The username is 'syncovery'. It is a domain user, not machine-local.
  • The remote machine is Windows 2019 server, which is just Windows 10 1809.
  • I have validated that I can connect to the share from another Windows 10 machine.
  • I have not tried to connect via the SMB client - smbclient is not installed - from the machine running Syncovery as I want the install to be as minimal as possible. I assume nothing else needs to be loaded for your code, other than libsmbclient. I don't see much documentation for the Linux version. Maybe I am missing it.
I have tried this:
url: smb://sm-er.customer.hh
folder: backup$

and this...
url: smb://sm-er.customer.hh/backup$
folder: <blank>

for the user name I have tried... No matter what I do I cannot connect. I get the following message:
20210316-0001.png
20210316-0001.png (20.55 KiB) Viewed 6254 times

tobias
Posts: 1589
Joined: Tue Mar 31, 2020 7:37 pm

Re: Cannot connect to Windows share with SMB

Post by tobias »

Hello,
I think that libsmbclient works only if a full samba client installation is present and configured. Maybe you can try to make the connection with a mounted smb folder first. If that works, it should work in Syncovery too.

The syntax is DOMAIN\username.

patanne
Posts: 12
Joined: Wed Mar 10, 2021 2:51 pm

Re: Cannot connect to Windows share with SMB

Post by patanne »

So actually the syntax is DOMAIN/username. libsmbclient follows the same as smbclient. I should have known.

FWIW, protocol settings need to be correct in smb.conf. For me it is...

Code: Select all

client min protocol = SMB2
client max protocol = SMB3
On to the next problem. I am now getting an error on the call to GetTreeData.

If I login from the machine with smbclient installed, I can list everything by first issuing the recurse command, then ls. I get everything. It works fine. Within syncovery, If I try to list folders it kicks another error.

If I hit the ellipsis on the connection config page I get this.
20210316-0003.png
20210316-0003.png (29.7 KiB) Viewed 6251 times

If I save the config and hit "choose folders and files" on the profile I get this.
20210316-0002.png
20210316-0002.png (36.43 KiB) Viewed 6251 times

Thoughts???

tobias
Posts: 1589
Joined: Tue Mar 31, 2020 7:37 pm

Re: Cannot connect to Windows share with SMB

Post by tobias »

Hello,
just avoid using any browse buttons in Syncovery. Complete the profile by typing paths, then run it. If there are still problems, that will get you a useful log file (although I can't decypher any of the smb error codes for you).

patanne
Posts: 12
Joined: Wed Mar 10, 2021 2:51 pm

Re: Cannot connect to Windows share with SMB

Post by patanne »

The version of OS I am using is Armbian based on Debian Stretch. Hoping that another version of Debian might provide clearer codes I installed everything on Debian Jessie and it paid off. The message led me to the possibility that the SMB URI was malformed.

Based on info at the link https://en.wikipedia.org/wiki/List_of_URI_schemes, the separator between username and domain is not a slash or backslash, rather a semi-colon.

So the username box needed to be in the format below. After that everything began to work.
domain;username

Additionally, smbclient does not need to be installed, only libsmbclient.

tobias
Posts: 1589
Joined: Tue Mar 31, 2020 7:37 pm

Re: Cannot connect to Windows share with SMB

Post by tobias »

Hello,
many thanks, and sorry for not knowing these things myself.

patanne
Posts: 12
Joined: Wed Mar 10, 2021 2:51 pm

Re: Cannot connect to Windows share with SMB

Post by patanne »

That is what the forums are for. I have worked one-on-one with you on certain issues over the years. Great products! Great service! No complaints!

Post Reply