Results 1 to 6 of 6

Thread: How to restrict user access to automounted ntfs Windows partition?

  1. #1
    Join Date
    May 2010
    Beans
    26

    How to restrict user access to automounted ntfs Windows partition?

    Sorry for being a little lazy, but my Googling so far has been fruitless...

    I want my Windows partition to automatically mount on boot--I've done that--BUT I want it to be accessible ONLY to the primary user...the "guest" account I have set up for my students or whoever to screw around on my computer should not be able to access or modify the contents of my Windows partition. But I still want it to be automatically mounted and have complete access to it when I'm logged in on my account. How can I do this?

    When I look at "permissions" in Nautilus for my Windows directories, it says only root can use it, even though I have complete read/write access to it. Which is fine--I set the fstab options that way intentionally--but I want only my primary account to have that access, not the secondary account.

    Thanks!

  2. #2
    Join Date
    Dec 2009
    Beans
    6,767

    Re: How to restrict user access to automounted ntfs Windows partition?

    Post the output of fstab please:
    Code:
    cat /etc/fstab

  3. #3
    Join Date
    May 2010
    Beans
    26

    Re: How to restrict user access to automounted ntfs Windows partition?

    # /etc/fstab: static file system information.
    #
    # Use 'blkid -o value -s UUID' to print the universally unique identifier
    # for a device; this may be used with UUID= as a more robust way to name
    # devices that works even if disks are added and removed. See fstab(5).
    #
    # <file system> <mount point> <type> <options> <dump> <pass>
    proc /proc proc nodev,noexec,nosuid 0 0
    # / was on /dev/sdb5 during installation
    UUID=bbac80f5-58a7-4d92-8f33-3b03a130d787 / ext4 errors=remount-ro 0 1
    # swap was on /dev/sdb1 during installation
    UUID=365fa9c5-2f00-4ff8-b1bc-2d93b9fb1a59 none swap sw 0 0

    #Manually added - automount windows partition LMR Sat 10 Sep 2011 08:18:53 PM KST
    /dev/sda2 /media/OS ntfs user,fmask=0111,dmask=0000 0 0

    Thanks!

  4. #4
    Join Date
    May 2007
    Location
    DR
    Beans
    1,345
    Distro
    Ubuntu Development Release

    Re: How to restrict user access to automounted ntfs Windows partition?

    i think you could also try mount manager in the software center
    When close to achieving you quit! If you don't try you failed. Real Winners are not afraid of losing.
    ubuntu newsletter ; Report Papercuts (small annoyances/bugs) ; beginners guide and video http://youtube.com/watch?v=Z0tNpt5RZYI

  5. #5
    Join Date
    Dec 2009
    Beans
    6,767

    Re: How to restrict user access to automounted ntfs Windows partition?

    Change this:
    /dev/sda2 /media/OS ntfs user,fmask=0111,dmask=0000 0 0
    To this:
    /dev/sda2 /media/OS ntfs defaults,uid=1000,fmask=0177,dmask=0077 0 0
    Then unmount the partition:
    Code:
    sudo umount /media/OS
    And run the following command to test for errors and mount the new partition settings:
    Code:
    sudo mount -a
    uid=1000 will make the owner you.
    All those "7"'s in fmask and dmask because of their position will make it unavailable to anyone but you.

  6. #6
    Join Date
    May 2010
    Beans
    26

    Re: How to restrict user access to automounted ntfs Windows partition?

    Quote Originally Posted by Morbius1 View Post
    Change this:
    To this:
    Thanks! That accomplished exactly what I wanted to do!

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
  •