I am currently trying to mount a cifs file server. I can do if I give my password manually:
root# mount -v -t cifs //server.mydomain/homes$/user.NAME /mnt -o username=user.NAME@mydomain
Password for user.NAME@mydomain@//server.mydomain/homes$/user.NAME: ************
mount.cifs kernel mount options: ip=10.9.99.99,unc=\\server.mydomain\homes$,user=user.NAME@mydomain,prefixpath=user.NAME,pass=********
But if I replace the username option with credentials option, I can not mount the cifs:
root# mount -v -t cifs //server.mydomain/homes$/user.NAME /mnt -o credentials=/root/smbcredential
,prefixpath=user.NANE,pass=********.24.29,unc=\\server.mydomain\homes$,user=user.NAME
mount error(13): Permission denied
/root/smbcredential
is a text file consisting of two lines
username=user.NAME@mydomain
password=1234#abc
and its permission is 600.
Question: Why is the credentials option not working?
Notes:
#
. I also tried to replace it with %23
, but it has no effect.I also tried to add the third line. i.e. domain, but it has no effect, neither.
username=user.NAME
password=1234#abc
domain=mydomain
dmesg
says Status code returned 0xc000006d STATUS_LOGON_FAILURE
, so I could give the wrong credential. python:3.7-slim-buster
. Because the first command works, Doker does not cause this problem. User contributions licensed under CC BY-SA 3.0