Can't configure android SMB client for SMB v2/v3 protocol

This is not an openSUSE problem, but I couldn’t find any decent help for this android client named AndSMB.

As most older mobile apps it is practically unsupported, with an outdated site, meager FAQ, etc:

http://www.lysesoft.com/products/andsmb/index.html

It supposedly supports SMB v2/v3, at least it can be configured for it, but I can only connect to oS server with SMB v1.

If I change the client config to v2/v3 the app fails with "cannot change directory to <share name>.

So when I block v1 in /etc/samba/smb.conf with:

[global]
        workgroup = WORKGROUP
        passdb backend = tdbsam
        printing = cups
        printcap name = cups
        printcap cache time = 750
        cups options = raw
        map to guest = Bad User
        logon path = \\%L\profiles\.msprofile
        logon home = \\%L\%U\.9xprofile
        logon drive = P:
        usershare allow guests = No
        wins support = No
        netbios name = bruno-0
        wins server = 
        **min protocol = SMB2**

I can’t access anything.

Windows 10 can access these shares, using v3.11:

# smbstatus             

Samba version 4.9.5-git.210.ab0549acb05lp151.2.9.1-SUSE-oS15.0-x86_64
PID     Username     Group        Machine                                   Protocol Version  Encryption           Signing              
----------------------------------------------------------------------------------------------------------------------------------------
15217   nobody       nobody       192.168.1.4 (ipv4:192.168.1.4:50186)      **SMB3_11**           -                    -                    

Guest is enabled in smb.conf:

[Publico]
        comment = All users
        **guest ok = Yes**
        inherit acls = Yes
        path = /home/shares/Gravados/Publico
        read only = No
        veto files = /aquota.user/groups/shares/

Now, there is one change in the app configuration options when I switch protocols:

Using SMB v1 that works:


Version:   SMB v1
Hostname:  192.168.1.1
Username:  optional
Password:  optional
Domain:    optional
(anonymous checkbox is checked)
(local folder path)
(remote share)

With SMB v2/v3 that doesn’t work:


Version:   SMB v2/v3
Hostname:  192.168.1.1
Username:  optional
Password:  optional
**Share:**     (?)
Domain:    optional
(anonymous checkbox is checked)
(local folder path)
(remote share)

I don’t know what this Share option refers to, as the server share name is given in the (remote share) entry.

I’ve tried repeating the share name, putting the workgroup name there, leave it blank, to no avail.

My feeling is the solution is simple, but I can’t begin to imagine what.

Thanks

Hi
Perhaps define that it’s a server in smb.conf, restart samba…


server min protocol = SMB2_02

This thread might be helpful…
https://www.ghisler.ch/board/viewtopic.php?f=3&t=47898&sid=5f998078fdbe83eaf127e2ab78db2c2f&start=15
It appears that there may be a later version which is SMB2 capable.

Another thought - would Android Samba Client perhaps be another viable option for you?
https://f-droid.org/en/packages/com.google.android.sambadocumentsprovider/

Hi Deano,

Thanks for the links, there’s been some progress, maybe.

I first added a smb user/password with #smdbpasswd -a and confirmed it with #pdbedit -L

Now when trying to connect I get a pop-up saying

Cannot change directory to Publico

and a notification at the bottom of the screen:

USER <my user> PASS *******
STATUS_BAD_NETWORK_NAME(3221225676/3221225676): Could not connect

I’m still puzzled by what could the “Share” field in the app configuration be. It’s like this now:

Version:   SMB v2/v3
Hostname:  192.168.1.1
Username:  <my user>
Password: *********
Share:**     (required) <-- what the F is that???
Domain:    optional
(anonymous checkbox is **un**checked)
Local folder:/storage/emulated/0/Download)
Remote folder: Publico

I still don’t see what this Share option refers to, I’ve tried repeating the share name, putting the workgroup name there, leave it blank, to no avail.

Any idea?

P.S.: I’ve installed fdroid to try the client you recommended, at first fdroid showed the repos, but it asked to update, and after that the screen is empty. I’ll try to fix this later.

My smb.conf is currently this:

~> cat /etc/samba/smb.conf
# smb.conf is the main Samba configuration file. You find a full commented
# version at /usr/share/doc/packages/samba/examples/smb.conf.SUSE if the
# samba-doc package is installed.
[global]
        workgroup = WORKGROUP
        passdb backend = tdbsam
        printing = cups
        printcap name = cups
        printcap cache time = 750
        cups options = raw
        map to guest = Bad User
        logon path = \\%L\profiles\.msprofile
        logon home = \\%L\%U\.9xprofile
        logon drive = P:
        usershare allow guests = No
        wins support = No
        netbios name = bruno-03
        min protocol = SMB2
        add machine script = /usr/sbin/useradd  -c Machine -d /var/lib/nobody -s /bin/false %m$
        domain logons = No
        domain master = No
        security = user
        wins server = 

[Publico]
        comment = All users
        guest ok = Yes
        inherit acls = Yes
        path = /home/shares/Gravados/Publico
        read only = No
        veto files = /aquota.user/groups/shares/

Hi malcolm,

It is already working as a server, as I can access the share from W10 - even without giving the name/password I created today. Because the share allow guests, I believe.

In one of the links deano posted someone commented that this SMB2_02 didn’t work, s/he had to use SMB2. But I didn’t experiment further.

try adding the name of the server share. Is it ‘Publico’ perhaps?

And… That was it!

I thought the remote directory name what the same as the share name, and it isn’t, it is just a directory under the share. If set to / is is the same as the share.

That was a real noob mistake! :stuck_out_tongue:

Thank you all very much!

Glad to have been of assistance!