Results 1 to 6 of 6

Thread: Mount a network share without being administrator

  1. #1
    Join Date
    Nov 2009
    Posts
    333

    Mount a network share without being administrator

    Hi
    I would allow a non-admin user to access a Windows network share. It must be mounted after boot because the wi-fi is not activated quickly enough. I do not want to make this user administrator, and the more I want to avoid any password in the clear. With an administrator account, I get to ride a good network share from a terminal with the command
    Code:
    sudo mount-t cifs / / 192.168.0.1/UnPartage / media / MyShare-o = MONUS user, iocharset = utf8
    It is obviously necessary that I give my password for sudo, then the password Samba / CIFS. To enable mounting deferred by a non-administrator, I understand the need to put in / etc / fstab line like
    Code:
    / media / MyShare / / 192.168.0.1/UnPartage smbfs utf8, user, noauto 0 0
    then ask him to type
    Code:
    mount-c / media / MyShare
    Problem 1: mount, only root user can do this
    Problem 2: Nothing happens when I try from my administrator account (no message, no editing).
    Code:
    sudo mount-c / home / MONUS: MyShare
    Can you help me?

  2. #2
    Join Date
    Apr 2008
    Posts
    3,424

    Re: Mount a network share without being administrator

    Hi
    mount-c / media / MyShare
    Problem 1: mount: only root user can do this
    A man mount tells us that the option -has is this,
    mounts all filesystems listed in fstab (or only those of the type indicated) By adding the option-F, fork (2) will be invoked for all file systems are mounted simultaneously.
    Now, not only your mount point is marked (Normally, you do not want it to be mounted at boot), but mount-a will try to mount any other mountpoints supposed to automatically mount. Hope this will help you.

  3. #3
    Join Date
    Nov 2009
    Posts
    333

    Re: Mount a network share without being administrator

    Hello
    1. Firstly, when I man mount I get this:
    -a Mount all filesystems (of the given types) mentioned in fstab.
    But there is no indication on the relationship between noauto and -a. But hey, if I ask a question here, it is because the aid does not solve my problem.
    2. if, with an administrator account, I mount / media / MyShare I get:
    error: improperly formatted UNC name. / media / frigate does not begin with \ \ or / /
    No ip address specified and hostname not found
    3. if I'm a non-administrator account, it is as already stated: mount: only root user can do this
    So, this is not what I want. Any more help will be appreciated.

  4. #4
    Join Date
    Apr 2008
    Posts
    3,424

    Re: Mount a network share without being administrator

    Hi
    I had not seen your property line in / etc / fstab
    Code:
    / media / MyShare / / 192.168.0.1/UnPartage smbfs utf8, user, noauto 0 0
    You must specify the target assembly in the first field, then the mount point in the second:
    Code:
    / / 192.168.0.1/UnPartage / media / MyShare  smbfs utf8, user, noauto 0 0
    But I stick by that, if you use the option -a. You do not go up your shares, unless the installation is automatic.

  5. #5
    Join Date
    Nov 2009
    Posts
    333

    Re: Mount a network share without being administrator

    Hi
    I have progressed a bit.
    So I corrected the / etc / fstab according to your instructions
    But if I do that
    Code:
    mount / media / frigate
    I get
    Code:
    mount error: permission denied or not superuser and mount.cifs not installed SUID
    What does that mean?
    Code:
    sudo mount / media / MyShare
    from an administrator account and providing two passwords, I get
    mount error (13): Permission denied
    Refer to the mount.cifs (8) manual page (egman mount.cifs) mount (where I found nothing relevant)
    Order without reference to fstab and it works fine
    Code:
    sudo mount-t cifs / / 192.168.0.1/UnPartage / media / MyShare-o user = MONUS, iocharset = utf8
    but I remember that the goal is to enable the assembly by a non-administrator. Any help on this.

  6. #6
    Join Date
    Jan 2006
    Posts
    3,792

    Re: Mount a network share without being administrator

    Hi,
    I think you can try this command, Not sure but just try it and see the results
    Code:
    smbmount / / server / share / localdir-o username = user, password = pass, uid = 500, gid = 500
    Any more help please do post back.

Similar Threads

  1. Apple mac book pro: Mount smaba share under Linux
    By Nammed Khuri in forum Portable Devices
    Replies: 8
    Last Post: 24-02-2011, 10:23 AM
  2. How to mount samba share in Linux Redhat?
    By Mishraji in forum Operating Systems
    Replies: 4
    Last Post: 13-11-2010, 02:32 AM
  3. Ubuntu failed to mount windows share
    By _Gentoo_Nile_ in forum Operating Systems
    Replies: 3
    Last Post: 14-08-2009, 09:41 PM
  4. backup SBS 2008 on remote share / network share
    By LAMONT D in forum Small Business Server
    Replies: 2
    Last Post: 30-05-2009, 01:19 AM
  5. Mount NFS-share on Windows Server 2003 x64
    By jens.wannenmacher@gmail.com in forum Windows Server Help
    Replies: 0
    Last Post: 15-04-2008, 03:35 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,714,115,617.57450 seconds with 17 queries