Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Stupid easy question, how to mount C: [solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Sugarat
Guru
Guru


Joined: 24 Jul 2002
Posts: 348

PostPosted: Sat Jan 01, 2005 12:58 pm    Post subject: Stupid easy question, how to mount C: [solved] Reply with quote

I am having trouble mount C: so that a non-root user can read the files on it. Its NTFS so naturally read only, but as soon as it's mounted nobody but root can access /mnt/c ..? What am I missing here..

This is my /etc/fstab

Code:

# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
#/dev/BOOT      /boot      ext2      noauto,noatime      1 1
/dev/hdb3      /      jfs      noatime         0 0
/dev/hdb1      none      swap      sw         0 0
/dev/cdroms/cdrom0   /mnt/cdrom   iso9660      noauto,ro      0 0
/dev/fd0      /mnt/floppy   auto      noauto         0 0
/dev/hda1      /mnt/c      auto      noauto,user,noatime   0 0
/dev/hdb2      /mnt/d      auto      noauto,user,noatime   0 0
# NOTE: The next line is critical for boot!
none         /proc      proc      defaults      0 0

# glibc 2.2 and above expects tmpfs to be mounted at /dev/shm for
# POSIX shared memory (shm_open, shm_unlink).
# (tmpfs is a dynamically expandable/shrinkable ramdisk, and will
#  use almost no memory if not populated with files)
# Adding the following line to /etc/fstab should take care of this:

none         /dev/shm   tmpfs      defaults      0 0


Code:

root@gingernut mnt # ls -al
total 8
drwxr-xr-x   6 root root    40 Jan  1 12:47 .
drwxr-xr-x  17 root root  4096 Dec 31 01:45 ..
-rw-r--r--   1 root root     0 Oct 27 22:32 .keep
drwxr-xr-x   2 root users    1 Jan  1 12:21 c
drwx------   2 root root     8 Oct 27 21:38 cdrom
drwxr-xr-x   2 root root     1 Jan  1 12:47 d
drwx------   2 root root     8 Oct 27 21:38 floppy

root@gingernut mnt # mount c

root@gingernut mnt # ls -al
total 24
drwxr-xr-x   6 root root    40 Jan  1 12:47 .
drwxr-xr-x  17 root root  4096 Dec 31 01:45 ..
-rw-r--r--   1 root root     0 Oct 27 22:32 .keep
dr-x------   1 root root 16384 Dec 31 18:14 c
drwx------   2 root root     8 Oct 27 21:38 cdrom
drwxr-xr-x   2 root root     1 Jan  1 12:47 d
drwx------   2 root root     8 Oct 27 21:38 floppy



Once /mnt/c is mounted the permissions all change so nobody but root can access it.

When the drive is mounted, /mnt/c suddenly belongs to root and not to the original owner. I can't change this as it just keeps saying 'read only file system'. How can I access this without being root?
_________________
--[ UltraSPARC ]--
Accept no imitations


Last edited by Sugarat on Sat Jan 01, 2005 1:49 pm; edited 1 time in total
Back to top
View user's profile Send private message
kd03
n00b
n00b


Joined: 21 Nov 2004
Posts: 69

PostPosted: Sat Jan 01, 2005 1:44 pm    Post subject: Reply with quote

This wiki article might be of some use.

-k
Back to top
View user's profile Send private message
mentok
n00b
n00b


Joined: 02 Nov 2003
Posts: 22
Location: Ontario, Canada

PostPosted: Sat Jan 01, 2005 1:45 pm    Post subject: Reply with quote

The ntfs partition gets the permissions of whoever mounts it. Try mounting it as a normal user. Also, try using the options uid=123 and gid=123 in fstab so that no matter who mounts the partition, it always has the same owner/group. Refer to the man page for mount for more information.
_________________
Code:
'emerge' is not recognized as an internal or external command,
operable program or batch file.

Click here for hardcore nudity!!!
Back to top
View user's profile Send private message
Sugarat
Guru
Guru


Joined: 24 Jul 2002
Posts: 348

PostPosted: Sat Jan 01, 2005 1:49 pm    Post subject: Reply with quote

Solved with the umask parameter. - Thank you!!
_________________
--[ UltraSPARC ]--
Accept no imitations
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum