0

I'm trying to use smbpasswd but it's not working like I expect. I try this:

sudo adduser --disabled-password --gecos "" username

sudo chpasswd < <( echo 'username:testpassword' )

sudo smbpasswd username

The last command is not working with this message:

Failed to find entry for user username

While the user certainly exists, I can log in with it without problems. what can I do to make this work? And why isn't this working as expected?

0

The user may exist for the system, but samba does not yet know this user. So have to use smbpasswd -a username to define this user for samba (i.e. to 'add' this user to the known samba users).

  • Indeed, I totally forgot the -a. Thanks man. – Mathias Maes Dec 14 '17 at 8:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.