VIM4 Ubuntu 22 Desktop, unable to mount network cifs shared volume

What are the necessary modules and steps to mount a CIFS network share?

I never been this unsuccessful in getting this work would on other raspberry pi os or ubuntu systems.

sudo apt-get install samba
sudo apt install cifs-utils

seems the cifs kernel module is not installed, first step I tried:

khadas@Khadas:~$ sudo lsmod | grep cifs
khadas@Khadas:~$ sudo modprobe cifs
sudo mount -a
yields:

mount error(13): Permission denied

khadas@Khadas:~$ cat /proc/fs/cifs/SecurityFlags
0x85
khadas@Khadas:~$ sudo -s
root@Khadas:/home/khadas# echo 0x27 > /proc/fs/cifs/SecurityFlags
sudo mount -a
yields:

mount error(2): No such file or directory

I am using the identical mount directories and fstab entry from another ubuntu machine that mounts the volume fine, I have tried a number of different options on the fstab line with no results:

sudo mkdir /media/nas00

sudo vi /etc/fstab
//192.168.2.5/nas00 /media/nas00 cifs username=xyz,password=xyz,uid=khadas,gid=khadas,vers=1.0,comment=xsystemd.automount 0 0

Thank you for guidance!

I had this and was advised to do this:

$ sudo modprobe cifs
$ sudo modprobe md4
$ sudo mount.cifs //192.168.101.100/sharename /mnt/mountname -o username=shareuser,password=sharepassword,domain=domainname

I also had to install cifs-utils and append lines in /etc/modules to load cifs and md4 at startup

I can now mount SMB shares on my NAS using an entry in fstab.

3 Likes

Thank you @technodevotee I am going to do a complete reinstall of Ubuntu and give this a try.

Hello @numbqq ,

You are still not adding the needed kernel modules (cifs and md4) to /etc/modules to mount a network CIFS NAS? This seems like a basic thing to have ready to go in a linux image, is there some reason for not including? Kind of makes Linux for end users that much more difficult. At least you could add something in the documentation?

khadas@Khadas:~$ cat /etc/fenix-release
# PLEASE DO NOT EDIT THIS FILE
BOARD=VIM4
VENDOR=Amlogic
VERSION=1.2
ARCH=arm64
INITRD_ARCH=arm64
IMAGE_VERSION=1.2-221018
################ GIT VERSION ################
UBOOT_GIT_VERSION=khadas-vims-u-boot-2019.01-v1.2-release
LINUX_GIT_VERSION=khadas-vims-linux-5.4-v1.2-release
FENIX_GIT_VERSION=v1.2
#############################################

did you find an answer for this?

edit -
sudo modprobe cifs
sudo modprobe md4
sudo mount.cifs //192.168.12.34/movies /media/plexmovies -o credentials=/root/.creds

this worked, now i need to modify etc/modules as mentioned in the post above.

“I also had to install cifs-utils and append lines in /etc/modules to load cifs and md4 at startup”