PDA

View Full Version : !! Can't access file in mounted file system.



john7sp
21st December 2008, 06:41 PM
Hi,
I have installed Fedora 10 in a external USB hard Disk. I boot it from USB drive of my Hp laptop(With Ms Vista,ntfs file system ). Everything works fine. But problem is that , even though I mount my internal 160 Gb HDD of my laptop (/dev/sda1 with windows,ntfs, filesystem) to some folder with read/Write permision in fedora. I can not copy any file from that drive(/dev/sda1) to my linux system(running as USB HDD), although I can browse the directory structure,already existing there.
while opening a file ,It says "Eror Opening file: permission Denied."
i have tried with mounting as root ... nothing works.. any Help Please !!

Vector
21st December 2008, 06:48 PM
Try:
mount /dev/your_drive /your_mountpoint -o users,rw -t ntfs

or:
mount /dev/your_drive /your_mountpoint -o uid=501,rw,exec -t ntfs

or something like that...

john7sp
21st December 2008, 07:06 PM
still not working ..I executed the following command as super user(root)
#mount /dev/sda1 /root/windows -o root,rw -t ntfs
then in windows directory while opening a file gives:-
" you do not have the permission necessary to open the file".

I checked the file permission all are root with read/write. but I can not change the file permission also ....surprisingly. and can not open the file !!!! never I saw such thing... is it the problem of fedora 10 or something else ?

john7sp
21st December 2008, 07:16 PM
Hi,
I have installed Fedora 10 in a external USB hard Disk. I boot it from USB drive of my Hp laptop(With Ms Vista,ntfs file system ). Everything works fine. But problem is that , even though I mount my internal 160 Gb HDD of my laptop (/dev/sda1 with windows,ntfs, filesystem) to some folder with read/Write permision in fedora. I can not copy any file from that drive(/dev/sda1) to my linux system(running as USB HDD), although I can browse the directory structure,already existing there.
while opening a file ,It says "Eror Opening file:permission Denied."
i have tried with mounting as root ...

I have tried the following command also:

#mount /dev/sda1 /root/windows -o root,rw -t ntfs

nothing works.. any Help Please !!

Vector
21st December 2008, 07:20 PM
No, it's the way it's being mounted. You will probably need to use setuid,setgid
Also, another problem that you (may/are going to) have, is that you are mounting a *GB filesystem into a *mb/gb flash drive. But i could be wrong on how that works. That may not be an issue at all; but one of the more experienced members here would know for sure.

Vector
21st December 2008, 07:24 PM
Mount options for ntfs
...
uid=value, gid=value and umask=value
Set the file permission on the filesystem. The umask value is
given in octal. By default, the files are owned by root and not
readable by somebody else.

Also, you explicitly mounted as root ;) (See it in your mount command below?)
mount /dev/sda1 /root/windows -o root,rw -t ntfs

Try this:
mount /dev/sda1 /root/windows -o uid=501,gid=501,umask=002,rw,exec -t ntfs

That assumes that your user id is 501. To find out for sure, look at it in the system-config-users dialogue to see what it says.

Sauron
21st December 2008, 07:25 PM
(random thought - shouldn't we be using type cifs by now?)

Vector
21st December 2008, 07:26 PM
I have no clue what that is... lol (will google it later, when i have more free time)

Sauron
21st December 2008, 07:30 PM
I thought it was the newer replacement for NTFS (it's part of the Samba tools). I'm likely getting confused with mounting a NTFS volume via samba and via locally attached. Nevermind....

Vector
21st December 2008, 07:33 PM
CIFS currently redirects here, even though CIFS and SMB do not exactly equate to each other.[citation needed]

In computer networking, Server Message Block (SMB) operates as an application-level network protocol mainly used to provide shared access to files, printers, serial ports, and miscellaneous communications between nodes on a network. It also provides an authenticated Inter-process communication mechanism. Most usage of SMB involves computers running Microsoft Windows, where it is often known simply as "Microsoft Windows Network".
...
...
At around the time when Sun Microsystems announced WebNFS [1], Microsoft launched an initiative in 1996 to rename SMB to Common Internet File System (CIFS), and added more features, including support for symbolic links, hard links, larger file sizes, and an initial attempt at supporting direct connections over TCP port 445 without all the NetBIOS trimmings (a largely experimental effort that required further refinement). Microsoft submitted some partial specifications as Internet-Drafts to the IETF,[2] though these submissions have expired.

I thought that i recognized the acronym from networking...