Practical steps to mount Windows and SMB network shares on Linux using mount.cifs. 13.04.2026 | reading time: 3 min Mounting SMB/CIFS shares on Linux gives a Linux host transparent access to Windows file shares and NAS devices; this guide shows what mount.cifs does and why you would use it. Quick lab: connect a share Run these commands as root to create credentials, mount a share, and verify it is available; adjust IP, share name, and UID/GID to your environment. ``` # create local mountpoint mkdir -p /mnt/share # create a credentials file with restricted permissions cat > /root/.smbcredentials <<'EOF' username=myuser password=SecretPass domain=WORKGROUP EOF chmod 600 /root/.smbcredentials # mount the SMB share (force SMB 3.0 in this example) mount.cifs //192.168.1.50/shared /mnt/share -o credentials=/root/.smbcredentials,uid=1000,gid=1000,file_mode=0644,dir_mode=0755,vers=3.0 # verify the mount mount | grep /mnt/share # sample output //192.168.1.50/shared on /mnt/share type cifs (rw,relatime,vers=3.0,...) ``` Options and caveats Key options you will use include "credentials", "uid/gid", "file_mode", "dir_mode", "vers" to set the SMB protocol version and "sec" to choose authentication like ntlmssp; ensure the package cifs-utils is installed, the kernel CIFS module is loaded, and remember mount.cifs must be run as root or via an entry in /etc/fstab or systemd unit; for persistent mounts add a secure credentials file and a line like "//192.168.1.50/shared /mnt/share cifs credentials=/root/.smbcredentials,uid=1000,gid=1000,vers=3.0 0 0" but beware of network dependencies at boot and prefer systemd automount where appropriate. Useful companions Tools that complement mount.cifs include "smbclient" for interactive SMB operations and troubleshooting, "smbget" or curl for retrieving files, and autofs or systemd automount for on-demand mounting; use /var/log/syslog and dmesg to diagnose low-level CIFS errors and check kernel messages for authentication failures or protocol mismatches. Next steps Try different "vers" values if the server rejects connections, test guest mounts with the "guest" option, and practice automating mounts with systemd or autofs; deepen skills by studying Samba, network filesystems, and pursuit of certifications such as CompTIA Linux+ or LPIC-1 and consider intensive exam preparation at bitsandbytes.academy to consolidate practical knowledge. Join Bits & Bytes Academy First class LINUX exam preparation. filesystem network utilities storage