Samba no longer accepting credentials

Having issues with your DietPi installation, or, found a bug? Post it here.
Post Reply
CrossmenX
Posts: 13
Joined: Thu Dec 13, 2018 8:42 am

Samba no longer accepting credentials

Post by CrossmenX »

My fresh DietPi install has been running smooth for about a week on a Raspberry PI 3b. I was accessing files this morning on my desktop pc via a Samba share, but when I returned this evening I found that I'm unable to connect to any of the samba shares from any device (windows 10 desktop, and an android phone). Both devices state authentication errors, but I can verify the password is accurate via SSH, VNC, and generally accessing the Pi directly. I've changed the password, but the issue remains.

Troubleshooting:
* Rebooted the Pi, and all devices connecting to the Pi.
* Reinstalled Samba multiple times via the dietpi-software interface. (Uninstall, reboot, install, reboot)
* Added a second user to linux and the smb.conf file.
* Cleared the stored credentials in win10
* Checked the samba logs, but most are blank and the ones that are not, do not seem to have any evidence of my attempts to connect other than the existence of a empty log that has my deskotp machine name or IP address. Perhaps the default level of logging is insufficient?
* Ran the dietpi update that was made available today (issue began before update)
* Googled extensively before posting here.

Noticed Quirks:
In the network browser of win10, I can see DIETPI, but could not connect to it as the user dietpi (Error: The user name or password is incorrect). However after adding a second user, and trying the new ID/pswd combo, I was able to see the two shares I have defined. Accessing either directory gives me an an Error: Access denied, despite the user being a member of the group that owns the directory of at least one of the two directories.

If I return to using the dietpi ID now that I'm able to view the top level shares, I get the following message: "\\DIETPI\rhodar is not accessible. You might not have permissions to use this network resource...[contact admin]... Multiple connections to a server or shared resource by the same user, using more than one user name are not allowed. Disconnect all previous connections to the server or shared resource and try again." Which I'm presuming I am getting because I've access the top level via one ID, and am attempting to access the next level in with another.

The three Backup smb.conf files in /etc/samba were all dated as last modified this afternoon, and are seemingly identical from what is currently in the main conf. No other backups were created.

Specifics:
The crucial share is a external USB drive, and is accessible directly from the OS if I'm connected via SSH or VNC'd into the desktop. This mounted as /mnt/rhodar - I'm using the default samba config that the dietpi-software control panel users, with the addition of the 'rhodar' share.

[rhodar]
path = /mnt/rhodar/
valid users = dietpi crossmenx
read only = no
browsable = yes
create mask = 0775
directory mask = 0775
writeable = yes

--

I'm struggling to find why the previously working ID/Password stopped working seemingly mid-day. And why any new account has a similar but not quite the same issues.

I'm up way too late as it is, but I'll respond tomorrow to any suggestions or requests for further information.

Thank you for your time.
CrossmenX
Posts: 13
Joined: Thu Dec 13, 2018 8:42 am

Re: Samba no longer accepting credentials

Post by CrossmenX »

After more poking around, I am still unable to connect with the original account (dietpi), but I did find some success with the secondary account created last night. I had to force SMB3 via instructions I found here: https://dzone.com/articles/fixing-broke ... r-linux-ho

Using the command: sudo sed -i "/\\[global\\]/a client min protocol = SMB3" /etc/samba/smb.conf

While this doesn't solve the mystery, I am able to now access the share without having to resort to a complete re-install.
User avatar
WarHawk
Posts: 623
Joined: Thu Jul 20, 2017 8:55 am

Re: Samba no longer accepting credentials

Post by WarHawk »

Anything in logs?

I believe they should be in /var/smbd.log and /var/nmbd.log in /usr/local/samba
https://unix.stackexchange.com/question ... mba-events
CrossmenX
Posts: 13
Joined: Thu Dec 13, 2018 8:42 am

Re: Samba no longer accepting credentials

Post by CrossmenX »

I don't have access to the Pi right now, but the only thing I ever saw on those logs were the service started/listening entries. I changed logging to level 2, but still didn't get anything new. I can check again this evening now that there's been some progress with the forcing of SMB3.
Post Reply