Find the answer to your Linux question:
Results 1 to 6 of 6
OK here is the problem. As root I mount the shared windows drive; mount -t smbfs //[IP]/f /mnt/nas -o username=[?],workgroup=[?] This mounts the drive fine. As root I'm able to ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2006
    Posts
    4

    trouble mounting a Windows drive


    OK here is the problem.

    As root I mount the shared windows drive;

    mount -t smbfs //[IP]/f /mnt/nas -o username=[?],workgroup=[?]

    This mounts the drive fine. As root I'm able to browse and edit files on this drive. great.

    However, I don't want to access this drive as root. I want to access the drive as a normal user. I can navigate to /mnt/nas and view the directories and files. However, I cannot create or delete any of the files or directories!

    I log back in as root and try a chmod 777 /mnt/nas -v

    This tells me it has worked.

    a ls -l on the other hand tells me it hasn't worked.

    How can I allow normal users to edit files on this share?

  2. #2
    Linux Guru sdousley's Avatar
    Join Date
    Feb 2004
    Posts
    1,790
    2 things:

    1. Does the drive mount with read/write permissions (check this with the command mount on it's own) If not, change the "-o username=[?],workgroup=[?]" and add "rw" like: "-o username=[?],workgroup=[?],rw"

    2. Does the server allow write access to the folder? If you mapped it on a windows computer, can you write to the share?
    "I am not an alcoholic, alcoholics go to meetings"
    Registered Linux user = #372327

  3. #3
    Just Joined!
    Join Date
    Oct 2006
    Posts
    4
    Quote Originally Posted by sdousley
    2 things:

    1. Does the drive mount with read/write permissions (check this with the command mount on it's own) If not, change the "-o username=[?],workgroup=[?]" and add "rw" like: "-o username=[?],workgroup=[?],rw"

    2. Does the server allow write access to the folder? If you mapped it on a windows computer, can you write to the share?
    1) Tried this and it still didn't set the permissions to 777

    2) The drive on the Windows machine has full access granted to everyone. Anyone can read or write to it. Except Linux users it seems...

    I'm assuming this is a problem with SAMBA not picking up the permissions from the Windows box correctly.

  4. $spacer_open
    $spacer_close
  5. #4
    Just Joined! Alex Stan's Avatar
    Join Date
    Aug 2006
    Location
    Hamilton, Ontario
    Posts
    90
    Can you write to the share as root? if not, you should check the share permissions(from the windows computer).

  6. #5
    Just Joined!
    Join Date
    Oct 2006
    Posts
    4
    Quote Originally Posted by Alex Stan
    Can you write to the share as root? if not, you should check the share permissions(from the windows computer).
    As root it works fine. I can create and destory directories, copy files. But I don't want to use the drive as root. I try and set the permissions in root using chmod so that all users can enjoy the same level of access but it doesn't work.

  7. #6
    Linux Guru sdousley's Avatar
    Join Date
    Feb 2004
    Posts
    1,790
    In this case, also try setting the share and file/directories to the groups "users" with "-o username=[?],workgroup=[?],rw,gid=users"
    That may well help.

    If not, can you post the current permissions of files in this share
    "I am not an alcoholic, alcoholics go to meetings"
    Registered Linux user = #372327

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •