16

Sometime ago I used to mount shared folders from my windows computer using the command :

sudo mount.cifs //computer/folder /mnt -o username=user

However now it bugs and yields :

mount error : cifs filesystem not supported by the system mount

error(19): No such device

Any idea on what might have happened in the meanwhile that prevents it from working ?

The package cifs-utils is installed..

zgrep -i cifs /proc/config.gz

Returns :

CONFIG_CIFS=m
CONFIG_CIFS_STATS=y
#CONFIG_CIFS_STATS2 is not set
CONFIG_CIFS_WEAK_PW_HASH=y
...

All yes except for STATS2 and DEBUG basically

ChiseledAbs
  • 2,193
  • 10
  • 28
  • 59

4 Answers4

12

CONFIG_CIFS=m means the CIFS functionality is compiled into a kernel module. If the cifs module isn't loaded after a reboot, you can append a line

cifs

to the file /etc/modules. The file lists modules which will be loaded automatically at boot time. To check if the module is already loaded type:

lsmod | grep cifs

If you don't see 'cifs' in the output, it isn't loaded. To load it manually without a reboot:

modprobe cifs
Hoov
  • 857
  • 7
  • 13
  • 2
    Also, if you've updated your kernel, the module changes. So `modprobe cifs` may fail and you have to reboot anyway as your running kernel version is not the same as the current module directory version. – Hendy Apr 26 '21 at 22:52
10

I had a similar problem, the module location was changed because of rolling release arch distribution, so path was different. Reboot

jimmij
  • 46,064
  • 19
  • 123
  • 136
user351921
  • 101
  • 1
  • 2
1

Here is yet another tip for mounting a Windows share:

sudo mount -t drvfs '\\your computer IP address or computername here\share'  /mnt

The key is to use the single quotes for the source drive.

Greenonline
  • 1,759
  • 7
  • 16
  • 21
user497032
  • 11
  • 1
0

your Ubuntu can not find cifs in filesystem. it is not necessary to add cifs.ko to kernel. you can treat it in menuconfig in kernel and choose cifs in filesystem. after that copy the new zImage.

finally

sudo mount -t cifs //computer ip/sharedfolder /mnt
Archemar
  • 31,183
  • 18
  • 69
  • 104
Alborz
  • 1