Mount.CIFS - Unable to mount to share - Need example

Posted on 2012-08-14
Last Modified: 2012-09-05
I just installed CIFS from the Debian package directory. When I look at the help, it looks like the mount command starts with mount.cifs <remotetarget>...etc.. I just cant seem to get the command working. Can anyone help me?

I have a Windows 7 share I am trying to mount. Is there anything I need to do on my Windows side as well?

Usage:  mount.cifs <remotetarget> <dir> -o <options>

Mount the remote target, specified as a UNC name, to a local directory.


Less commonly used options:
        directio,nounix,cifsacl,sec=<authentication mechanism>,sign

Options not needed for servers supporting CIFS Unix extensions
        (e.g. unneeded for mounts to most Samba versions):

Rarely used options:

Options are described in more detail in the manual page
        man 8 mount.cifs

To display the version number of the mount helper:
        mount.cifs -V
Question by:LeviDaily
    LVL 23

    Accepted Solution

    Here is an example:

    mount.cifs // /mnt/cifs -o username=windowsuser,password=windowspassword

    If the share is avaiable to anyone and you don't need permissions you can skip the options:

    mount.cifs // /mnt/cifs

    Of course remember you have to create the mount point first:
    mkdir /mnt/cifs
    LVL 2

    Author Comment

    Ok, when I run it, I get this error...

    mount error: cifs filesystem not supported by the system
    mount error(19): No such device
    Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
    LVL 44

    Expert Comment

    The mount.cifs program is called by mount if you use the '-t cifs' switch with it.

    You say you installed the cifs package... which cifs package[s]?
    It's usually installed with samba, since that's the mount type samba uses for shares by default.

    try it like this
    $ sudo mount -t cifs // /mnt/cifs --verbose -o rw,user=MyUserName,password=MyPassWord

    Open in new window

    That should give you extra messages (though it looks like you're getting lots of messages already :) at every step of the process.

    Once you get it to mount like that, you can put a line in the /etc/fstab file (without the -t and -o switches) and it should mount automatically at every restart.
    LVL 2

    Author Comment

    Weird -  still not mounting.. I installed cifs -utils & verified that samba-commons is installed.. Weird??

    mount error: cifs filesystem not supported by the system
    mount error(19): No such device
    Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
    LVL 2

    Expert Comment

    Use as below

    mount -t cifs // -o username=myusername,password='mypassword' /your/mount/point

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    What Is Threat Intelligence?

    Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

    If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
    Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
    Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
    Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    13 Experts available now in Live!

    Get 1:1 Help Now