What does cifs_mount failed w/return code = -22 indicate

Adi Pandit picture Adi Pandit · Jul 18, 2011 · Viewed 68.6k times · Source

I am trying

sudo mount -t cifs //<server>/<share> -o username=user@domain,password=**** /mnt/<mountpoint>

error message:

mount: wrong fs type, bad option, bad superblock on //server/share,
       missing codepage or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

The syslog has

 CIFS VFS: cifs_mount failed w/return code = -22

I am able to mount the same share on another centos system. I can ping the server, mount point directory has been created.

Answer

akame picture akame · Nov 9, 2012

I ran into this problem when using a host name and solved it by using an IP address. E.g.:

use

mount -t cifs //192.168.1.15/share

rather than

mount -t cifs //servername/share

Another possible solution is to install

cifs-utils

.