Mounting CIFS network share in linux
Monday, April 13, 2009 1:19
This is a simple sub-tutorial on mounting network shares in linux – not only fedora. These network shares can be mounted with SMB and CIFS but in this tutorial, I am talking about CIFS mounts. This, Common Internet File System (CIFS) is a proposed standard protocol that lets programs make requests for files and services on remote computers on the Internet. (I got this definition from http://searchcio-midmarket.techtarget.com/sDefinition/0,,sid183_gci213851,00.html).
To mount a network share in linux, make sure you have smbfs daemon running.
The example given below talks about ad-hoc mounting a network share. This is not a permanent mount.
mount -t cifs -o username=username,password=password //192.168.2.18/share_name /path_to/mount_point
This will mount the network share at 192.168.2.18 to /path_to/mount_point. After this you can access the network folder from /path_to/mount_point
This is useful mounting a windows share in linux. (Yes there are other ways too, but this is handy!)
A little explanation
mount – Everyone knows about the mount command
-t – filesystem type (vfat, nfs, cifs etc. )
-o – optionsusername – owner username in network share
password – password for the same
//192.168.2.18/share_name – A publicly available share name.
/path_to/mount_point – A local mount point. That is where to mount the network share
Try it once. Happy reading
















