LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices


Reply
  Search this Thread
Old 05-31-2004, 03:38 PM   #1
tanktmf
LQ Newbie
 
Registered: May 2004
Distribution: Mandrake 10.0
Posts: 5

Rep: Reputation: 0
mounting issues with windows drives


I am trying to mount my old hdd (new drive, fresh install of mandrake 10) so i can get the info off of it, but i can only mount and view the files as root by using
"mount /dev/hdb1 /mnt/hdd"
but then only root can access it. I have been looking around on the fourm for this and have found a few threads but have not had any luck with it. I would like to be able to have it automount at start up.
this is my fstab

/dev/hda1 / xfs defaults 1 1
none /dev/pts devpts mode=0620 0 0
/dev/hda6 /home xfs defaults 1 2
/dev/hdc /mnt/cdrom auto umask=0,user,iocharset=iso8859-1,codepage=850,noauto,ro,exec 0 0
/dev/hdd /mnt/cdrom2 auto umask=0,user,iocharset=iso8859-1,codepage=850,noauto,ro,exec 0 0
none /mnt/floppy supermount dev=/dev/fd0,fs=ext2:vfat,--,umask=0,iocharset=iso8859-1,sync,codepage=850 0 0
none /proc proc defaults 0 0
/dev/hda5 swap swap defaults 0 0
/mnt/hd supermount dev=/dev/ide/host0/bus0/target1/lun0/part1,fs=ext2:vfat,--,umask=0,iocharset=iso8859-1,kudzu,codepage=850 0 0

end fstab

thanks for any help in advace.
 
Old 05-31-2004, 03:49 PM   #2
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
Add to /etc/fstab:
Code:
/dev/hdb1 /mnt/hdd ext2 defaults 0 0
Note that if you use a different filesystem, not Ext2, on the old disk, you should replace the third parameter with the right value.
I'd also remove the last line of your fstab (if you're not sure you need it) - it looks like a try to mount your old disk (target1/lun0/part1 is probably hdb1, but I'm not sure).
 
Old 05-31-2004, 04:16 PM   #3
tanktmf
LQ Newbie
 
Registered: May 2004
Distribution: Mandrake 10.0
Posts: 5

Original Poster
Rep: Reputation: 0
Mara,

Thank you for your help, I added that line into my fstab and it now auto mounts, but i am still unable to access it. I can only access it if i am logged in as root. Is there a way around this or do i have to do that every time i want to access the drive?
 
Old 06-01-2004, 05:23 PM   #4
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
Can you enter the directory when you're non-root? If not, please copy what this command returns you:
Code:
ls -l /mnt|grep hdd
 
Old 06-10-2004, 10:18 PM   #5
tanktmf
LQ Newbie
 
Registered: May 2004
Distribution: Mandrake 10.0
Posts: 5

Original Poster
Rep: Reputation: 0
brennan@localhost brennan]$ ls -l /mnt|grep hdd
dr-x------ 1 root root 8192 Jun 6 20:34 hdd/
 
Old 06-11-2004, 04:05 PM   #6
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
You need to change the directory permissions, because now obly root can read/enter it. The command is (when you're in /mnt):
chmod a+rx hdd
 
Old 06-11-2004, 06:57 PM   #7
tanktmf
LQ Newbie
 
Registered: May 2004
Distribution: Mandrake 10.0
Posts: 5

Original Poster
Rep: Reputation: 0
This is what i get

[root@localhost brennan]# cd /mnt
[root@localhost mnt]# chmod a+rx hdd
chmod: changing permissions of `hdd': Read-only file system
[root@localhost mnt]#


I also might want to add that this is an NTFS drive.
 
Old 06-11-2004, 08:52 PM   #8
Ph0enix2003
Member
 
Registered: Jun 2004
Posts: 101

Rep: Reputation: 15
Quote:
Originally posted by tanktmf
This is what i get

[root@localhost brennan]# cd /mnt
[root@localhost mnt]# chmod a+rx hdd
chmod: changing permissions of `hdd': Read-only file system
[root@localhost mnt]#


I also might want to add that this is an NTFS drive.
Here's what's in my /etc/fstab:

/dev/hda1 /mnt/windows ntfs umask=0,nls=iso8859-1,ro 0 0

You want the "ro" (read only) there. Writing to a Windows partition from Linux = trouble sooner or later.
I'd suggest unmounting the windows partition as root, running the chmod command as suggested above, then modifying fstab and rebooting.
 
Old 06-12-2004, 06:14 PM   #9
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
Do as Ph0enix2003 suggests or, for console, run
umount /mnt/hdd
cd /mnt
chmod a+rx hdd
mount /mnt/hdd
 
Old 07-04-2004, 07:53 AM   #10
cerebellum
LQ Newbie
 
Registered: Jun 2004
Location: Kuala Lumpur
Distribution: Redhat, Mandrake
Posts: 21

Rep: Reputation: 15
Quote:
Do as Ph0enix2003 suggests or, for console, run
umount /mnt/hdd
cd /mnt
chmod a+rx hdd
mount /mnt/hdd
i still see dr-x------ 1 root root as the file permission.

i have
Code:
/dev/hdb1 /mnt/hdd ext2 defaults,ro 0 0
in my fstab, but still i cannot access the file system as user (not root)

please advice.
 
Old 07-05-2004, 06:42 PM   #11
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
Try
Code:
/dev/hdb1 /mnt/hdd ext2 defaults,ro,umask=0 0 0
 
Old 07-06-2004, 12:27 AM   #12
cerebellum
LQ Newbie
 
Registered: Jun 2004
Location: Kuala Lumpur
Distribution: Redhat, Mandrake
Posts: 21

Rep: Reputation: 15
Quote:
Originally posted by Mara
Try
Code:
/dev/hdb1 /mnt/hdd ext2 defaults,ro,umask=0 0 0
thnx.. it works.
 
Old 07-06-2004, 07:09 AM   #13
cerebellum
LQ Newbie
 
Registered: Jun 2004
Location: Kuala Lumpur
Distribution: Redhat, Mandrake
Posts: 21

Rep: Reputation: 15
by the way.. care to explain what umask=0 0 0 means?
thnx.
 
Old 07-06-2004, 04:08 PM   #14
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
In fact, umask=0. Next two zeros are completely unrelated. But first umask. It's a mask on the permissions, a negative one. umask=0 means all permissions may be given. When umask is non-zero, not all permissions are possible and that's probably your case. You can see your current configuration (used for permissions of new files you create) using the command 'umask'.
It was probably not fully clear, so an example. Let's say that I've got umask set to 022. When I create a file with permissions 0666, I'll get 0644

The two zeros are: first one is used by dump, so it has probably no use for you. The second one is more interesing. It's used by fsck to get the order partitions should be checked during boot. If there's 0, the partition is not checked.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mounting Windows partition on sata drives TomalakBORG Linux - Hardware 6 08-19-2005 08:01 PM
mounting windows drives- help needed kudos Slackware 12 05-15-2003 10:45 PM
mounting windows drives madiyaan Linux - Newbie 3 05-15-2003 01:18 AM
mounting shared windows drives unexpected.tdb The Jesus Linux - Software 1 06-10-2002 10:02 PM
Mounting Windows Drives Across a Network Nyc0n Linux - Networking 4 08-20-2001 07:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva

All times are GMT -5. The time now is 03:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration