Can't connect to Samba running on Raspbian from Windows 7 Home Premium

SeanieOS

New member
Local time
5:11 PM
Messages
16
Hello,

I've spent days on this and hours researching what others have tried but no joy.

I've got Samba 4.5.8-Debian running on Raspbian [GNU/Linux 9.1 (stretch)]. I am trying to connect to a shared folder on the Raspbian OS by connecting from Windows 7 (Home Premium). I get a pop up username/password log-in box but it never authenticates me. I've tried dozens of permutations of the settings in smb.conf and even made registry changes. Nothing has worked!

I have tested accessing the share from an Ubuntu machine and it does authenticate.

Here is my smb.conf file. It does allow an Ubuntu machine access the share but not a Win 7 Home Premium client:

Code:
# Global parameters
[global]
        log file = /var/log/samba/log.%m
        max log size = 1000
        syslog = 0
        panic action = /usr/share/samba/panic-action %d
        usershare allow guests = Yes
        map to guest = Bad User
        obey pam restrictions = Yes
        pam password change = Yes
        passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
        passwd program = /usr/bin/passwd %u
        server role = standalone server
        unix password sync = Yes
        dns proxy = No
        idmap config * : backend = tdb

[NextCloudPi]
        path = /var/www/nextcloud/data/admin/files
        create mask = 0770
        directory mask = 0771
        force create mode = 0660
        force directory mode = 0770
        force group = www-data
        read only = No
        valid users = pi

If I put [guest = ok] in the [NextCloudPi] share definition it lets me straight in to the share without prompting for username/pwd and I can then browse the files in the share but I want to get the authentication working.

I checked with smbpasswd and the [pi] Samba user does exist both in Samba and in the Raspbian OS and I even changed the pwd to be sure I am using the correct one from the Windows log-in pop up.

Here is the error I get:

31300356-32b415de-aaeb-11e7-8656-d7a2190a1db5.jpg


Other things I tried:
1. Updated the /etc/hosts file in Win 7 to map the (fixed) ip address of the pi to its hostname: nextcloudpi
2. Open regedit and navigate to HKLM\SYSTEM\CurrentControlSet\Control\Lsa then choose to create DWORD named LmCompatibilityLevel then set the value to 2 although value 1.
3. HKLM\System\CCS\Services\LanmanWorkstation\Parameters
DWORD DomainCompatibilityMode = 1
DWORD DNSNameResolutionRequired = 0

I have also turned on Network discovery, File and Printer sharing with 128 bit encryption.

From my reading there could be a hundred different things that would work for someone else but not for my setup. Nevertheless I would be very grateful for any help or assistance.

Cheers,

SeanieOS
 

My Computer My Computer

At a glance

Windows 7 Home Premium 64-bit
OS
Windows 7 Home Premium 64-bit
Problem Solved

Have I added them to the Samba list? By "them" I suppose you mean the user I am trying to log in to the Samba share with.

From my original post:

I checked with smbpasswd and the [pi] Samba user does exist both in Samba and in the Raspbian OS and I even changed the pwd to be sure I am using the correct one from the Windows log-in pop up.

Still though, thank you for responding. I'm surprised at how quiet these forums are. I guess people are slowly migrating to Windows 10.

I had set the DWORD: LmCompatibilityLevel value in HKLM\SYSTEM\CurrentControlSet\Control\Lsa to 2 which made the Win 7 client connect to Samba server on the Raspberry Pi with NTLM encryption but Samba is using SMB3 version of the Samba protocol which only deals with NTLMv2. By setting that Win 7 registry setting to 3 it started working again.

Full details in this far more helpful forum... Can't connect to Samba running on Raspbian from Windows 7 Home Premium

Cheers,

Flex
 

My Computer My Computer

At a glance

Windows 7 Home Premium 64-bit
OS
Windows 7 Home Premium 64-bit

My Computer My Computer

At a glance

Windows 7 Ultimate x64
OS
Windows 7 Ultimate x64
I'm surprised at how quiet these forums are. I guess people are slowly migrating to Windows 10.

In my case, if I haven't posted an answer to someone's question, it's because I don't know the answer.

Your question is about an unusual topic, and perhaps a difficult one. Sometimes networking between Linux and Windows, or Linux and Linux, can be difficult. This is something I'm trying to do on my own network, but so far without success.

I will be keeping up with your question, and any responses, however, because maybe the answer I need will be included in someone's response.

Good luck.

Jim
 

My Computer My Computer

At a glance

Linux Mint 18.2 xfce 64-bit (VMWare host) / W...Haswell4 GB
Computer type
PC/Desktop
Computer Manufacturer/Model Number
Dell
OS
Linux Mint 18.2 xfce 64-bit (VMWare host) / Windows 8.1 Pro 32-bit (VMWare guest)
CPU
Haswell
Memory
4 GB
Monitor(s) Displays
Acer 23"
Screen Resolution
1920 x 1080
Hard Drives
Two hard drives, 1TB each: One for Linux, one for my data.
Keyboard
IBM Model M
Antivirus
Sophos (Linux), Trend Micro (Windows)
Browser
Firefox, Opera
Other Info
I use Samba to share my data drive with the other computers at my house and with my guest session in VMWare Workstation Player.
Back
Top