I want to make creating a samba password automated but this command doesn't work:
echo "passwd"|smbpasswd -a -s $user
It shows this error:
Mismatch - password unchanged. Unable to get new password.
Could you please suggest any option to make my script automated?