Monday, April 29, 2024
 Popular · Latest · Hot · Upcoming
7
rated 0 times [  7] [ 0]  / answers: 1 / hits: 3195  / 3 Years ago, fri, july 30, 2021, 12:21:49

I want to grant permission one specific standard Ubuntu 11.10 user to be able to mount a specific NTFS drive. How can I do that?


More From » 11.10

 Answers
7

You could create a command line to mount the partition into a script, than grant that user the privilege to run the script with sudo. For example



#!/bin/sh
# Filename: /usr/local/bin/mount-win

mount -o uid=john,gid=john /dev/sda1 /media/win


then



sudo chmod +x /usr/local/bin/mount-win


in /etc/sudoers add the line



john ALL = NOPASSWD: /usr/local/bin/mount-win


where john is the standard user's username.



For ease of use, you can create a launcher for the script with a line



Exec=gksu /usr/local/bin/mount-win

[#40252] Friday, July 30, 2021, 3 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
breadoules

Total Points: 212
Total Questions: 118
Total Answers: 120

Location: Dominica
Member since Mon, Jun 22, 2020
4 Years ago
;