2

I have a new Western Digital My Book Live 3TB NAS drive and I need to mount it on my Ubuntu 12.10 laptop.

I have created a directory '/NASRichardsWorkLaptop' (changed its ownership and group to myself, and given it 777 access) and mounted the NAS drive onto that using the following line in fstab:

//10.0.0.14/RichardsWorkLaptop /NASRichardsWorkLaptop cifs  defaults 0 0

However, as soon as it mounts '/NASRichardsWorkLaptop' becomes owned by root with 755 permissions and then only root can write to it. I need it to be read write to other users not just root. Any idea who I can make that happen?

I tried sudo chmod 777 /NASRichardsWorkLaptop/ but the permissions remain at 755 even after this command (if its mounted), so I'm stuck!

1

If you look at the documentation for the mount.cifs, you will notice a uid parameter (or guid)

  • uid=arg

    sets the uid that will own all files or directories on the mounted filesystem when the server does not provide ownership information. It may be specified as either a username or a numeric uid. When not specified, the default is uid 0.

  • gid=arg

    sets the gid that will own all files or directories on the mounted filesystem when the server does not provide ownership information. It may be specified as either a groupname or a numeric gid. When not specified, the default is gid 0.

Adding the uid (or gid) of your user (or group) to the fstab line will grant you the needed rights.

  • @user118406 : Nice to have helped you. In the stackexchange world, a "thanks, that worked" is a +1 or an accepted answer ;) – Cédric Julien Jan 4 '13 at 10:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.