LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 11-11-2004, 02:52 PM   #1
dertien
LQ Newbie
 
Registered: Nov 2004
Posts: 10

Rep: Reputation: 0
Unhappy mounting an NTFS extended partition on Fedora 2


Hello there boys and girls,

I am new to Linux Fedora, and up until now I have no regrets of having dumped my mickeysoft OS for Fedora core 2.

This is my problem at the moment:

I am trying to access the other active NTFS partitions, and I installed the correct RPM to have NTFS support, which works on my 2 smaller partitions.

this is what I get when typing '# fdisk -l' in the terminal:

Disk /dev/hda: 46.1 GB, 46103371776 bytes
255 heads, 63 sectors/track, 5605 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 622 4996183+ b W95 FAT32
/dev/hda2 1276 5604 34772692+ f W95 Ext'd (LBA)
/dev/hda3 1021 1024 32130 83 Linux
/dev/hda4 822 825 32130 83 Linux
/dev/hda5 1276 3187 15358108+ c W95 FAT32 (LBA)
/dev/hda6 3188 5604 19414521 83 Linux

Partition table entries are not in disk order

Disk /dev/hdb: 123.5 GB, 123522416640 bytes
16 heads, 63 sectors/track, 239340 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

Device Boot Start End Blocks Id System
/dev/hdb1 * 1 162547 81923436 7 HPFS/NTFS
/dev/hdb2 162547 239334 38700585 7 HPFS/NTFS

I got the two partitions (/dev/hda1 and /dev/hda5) working and readable/writeable in Linux.
If however I want to mount the hda2 partition with this command:

mount -t ext2 /dev/hda2 /mnt/E

it gives me the error :

mount: wrong fs type, bad option, bad superblock on /dev/hda2,
or too many mounted file systems
(aren't you trying to mount an extended partition,
instead of some logical partition inside?)

what command do I need to run in the terminal to mount it to the /mnt/E directory ?

I don't quite understand why Linux recognizes this as a f W95 Ext'd (LBA) because I have win 98 installed and it doesn't read that drive, so its definitely not a Fat drive.

Can anybody help ?

Thank you
 
Old 11-11-2004, 03:12 PM   #2
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 58
hi there

2 options

1. either compile ur kernel with NTFS support
2. or visit linux-ntfs.sourceforge.net
to install the modules

regards
 
Old 11-11-2004, 04:15 PM   #3
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
Code:
mount -t ext2 /dev/hda2 /mnt/E
this is for mounting ext2 partitions
use -t ntfs for mounting ntfs partitions
and -t vfat for mounting Fat32 partitions

see man mount
 
Old 11-11-2004, 04:17 PM   #4
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
maybe ext3 ?
 
Old 11-11-2004, 04:30 PM   #5
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,759

Rep: Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719
An extended partition can not be mounted.

In a nut shell an extended partition is a container for logical partitions. The extended / logical scheme is the method used to create more then 4 partitions on a drive.

Primary partitions are IDs 1-4
Logical partitions are any IDs >=5.

http://www.pcguide.com/ref/hdd/file/...titions-c.html
 
Old 11-11-2004, 05:08 PM   #6
dertien
LQ Newbie
 
Registered: Nov 2004
Posts: 10

Original Poster
Rep: Reputation: 0
Hello there,

Thanks for all the input, but I am still getting nowhere.

I installed the modules from linux-ntfs.sourceforge.net before I submitted this post. As I pointed out in my first post, I can successfully read the 'small' partitions by mounting them, however this partition

dev/hda2 1276 5604 34772692+ f W95 Ext'd (LBA)

doesn't want to load and gives me this error:

mount: wrong fs type, bad option, bad superblock on /dev/hda2,
or too many mounted file systems
(aren't you trying to mount an extended partition,
instead of some logical partition inside?)

this command line: mount -t ext2 /dev/hda2 /mnt/E gives me the same error

If I don't specify the filetype, like this : mount /dev/hda2 /mnt/E

I get: mount: error while guessing filesystem type
mount: you must specify the filesystem type

however, I do not know how to pinpoint the correct file system, as windows 2000 server isn't starting up anymore.

how can I know if the system is ext2 or ext3 ?, both lines

mount -t ext2 /dev/hda2 /mnt/E
mount -t ext3 /dev/hda2 /mnt/E

give the same error:

mount: wrong fs type, bad option, bad superblock on /dev/hda2,
or too many mounted file systems
(aren't you trying to mount an extended partition,
instead of some logical partition inside?)

do I need to resize them, in order to mount them, and if I do, will it be safe (no data loss) ?
Furthermore, if I resize them, what RPM will I need to do that ?

thank you

XIII
 
Old 11-11-2004, 05:11 PM   #7
dertien
LQ Newbie
 
Registered: Nov 2004
Posts: 10

Original Poster
Rep: Reputation: 0
Hello michaelk, you were faster than me to post the reaction that I was intending for this post:

so what do I need to do to access the files on this extended partition in linux ? Can I do anything to retreive them, or access them via fedora core 2 ? or have I lost all this data ?

do I need to resize ?

please help

XIII
 
Old 11-11-2004, 05:27 PM   #8
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
Quote:
An extended partition can not be mounted.

In a nut shell an extended partition is a container for logical partitions. The extended / logical scheme is the method used to create more then 4 partitions on a drive.

Primary partitions are IDs 1-4
Logical partitions are any IDs >=5.

http://www.pcguide.com/ref/hdd/file...rtitions-c.html

__________________
All I need to know I could have learned in Kindergarten
... if I'd just been paying attention.
That's true!

The extended patition is not a "real" mountable partision.
if you look at your table:

Code:
/dev/hda1 * 1 622 4996183+ b W95 FAT32
/dev/hda2 1276 5604 34772692+ f W95 Ext'd (LBA)
/dev/hda3 1021 1024 32130 83 Linux
/dev/hda4 822 825 32130 83 Linux
/dev/hda5 1276 3187 15358108+ c W95 FAT32 (LBA)
/dev/hda6 3188 5604 19414521 83 Linux
you 'll see that the extended partition starts from block 1276 and ends at 5604

it contains hda5 & hda6
 
Old 11-11-2004, 05:59 PM   #9
Junior41180
Member
 
Registered: Dec 2003
Location: Florida
Posts: 157

Rep: Reputation: 30
here is what my fstab looks like in MDK 10.1, maybe it will help.

/dev/hdb1 / ext3 defaults 1 1
none /dev/pts devpts mode=0620 0 0
/dev/hdb6 /home ext3 defaults 1 2
/dev/hdc /mnt/cdrom auto umask=0022,user,iocharset=iso8859-1,codepage=850,noauto,ro,exec,users 0 0
/dev/hdd /mnt/cdrom2 auto umask=0022,user,iocharset=iso8859-1,codepage=850,noauto,ro,exec,users 0 0
none /mnt/floppy supermount dev=/dev/fd0,fs=ext2:vfat,--,umask=0022,iocharset=iso8859-1,sync,codepage=850 0 0
/dev/hda1 /mnt/win_c ntfs umask=0022,nls=iso8859-1,ro 0 0
/dev/hde1 /mnt/win_c2 ntfs umask=0022,nls=iso8859-1,ro 0 0
/dev/hda2 /mnt/win_d ntfs umask=0022,nls=iso8859-1,ro 0 0
none /proc proc defaults 0 0
none /tmp tmpfs defaults 0 0
/dev/hdb5 swap swap defaults 0 0


win_c2 is an extended partition of win_c and mounts with no problem.

hope this helps.

I believe NTFS is compiled as a module in the kernel. So you will of course need the ntfs module before you can mount it.

Good luck.
 
Old 11-11-2004, 06:24 PM   #10
dertien
LQ Newbie
 
Registered: Nov 2004
Posts: 10

Original Poster
Rep: Reputation: 0
Ok, so you are telling me that

/dev/hda2 1276 5604 34772692+ f W95 Ext'd (LBA)

is actually

/dev/hda5 1276 3187 15358108+ c W95 FAT32 (LBA) +
/dev/hda6 3188 5604 19414521 83 Linux

but where has my D drive in windows gone then ? and how can I mount

hda 3 and 4 ? what filetype should I add for them in the mount command line ?

XIII
 
Old 11-11-2004, 06:27 PM   #11
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,759

Rep: Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719
Quote:
win_c2 is an extended partition of win_c and mounts with no problem.
I question this statement. Look at the ouput of the fdisk command
fdisk -l /dev/hde (that is a small L)
 
Old 11-11-2004, 06:39 PM   #12
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,759

Rep: Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719Reputation: 719
Quote:
Originally posted by dertien
Ok, so you are telling me that

/dev/hda2 1276 5604 34772692+ f W95 Ext'd (LBA)

is actually

/dev/hda5 1276 3187 15358108+ c W95 FAT32 (LBA) +
/dev/hda6 3188 5604 19414521 83 Linux

but where has my D drive in windows gone then ? and how can I mount

hda 3 and 4 ? what filetype should I add for them in the mount command line ?

XIII
Bascially yes. The d drive is /dev/hda5.

Look at the /etc/fstab file. This shows where each filesystem is mounted. However, since Fedora uses volume labels it isn't always easy to figure mount points out from the fstab file.
Type in the command mount with out any options. This will also show all mounted filesystems with their options.

/dev/hda3 1021 1024 32130 83 Linux
/dev/hda4 822 825 32130 83 Linux
dev/hda6 3188 5604 19414521 83 Linux

The default install creates 3 partitions for /boot, / (root) and a swap. Neither hda3 or hda4 are very big. hda3 is probably the /boot partition. hda6 is probably your / partition. These partitions will already be mounted during botup and you do not need to mount them yourself.

Last edited by michaelk; 11-11-2004 at 06:40 PM.
 
Old 11-11-2004, 08:40 PM   #13
perfect_circle
Senior Member
 
Registered: Oct 2004
Location: Athens, Greece
Distribution: Slackware, arch
Posts: 1,783

Rep: Reputation: 52
Code:
Disk /dev/hdb: 123.5 GB, 123522416640 bytes
16 heads, 63 sectors/track, 239340 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

Device Boot Start End Blocks Id System
/dev/hdb1 * 1 162547 81923436 7 HPFS/NTFS
/dev/hdb2 162547 239334 38700585 7 HPFS/NTFS
this is a hard drive.

Have you mounted hdb?
this is your 123.5GB hard disk.
This is an NTFS drive
if not then your D: is hdb1
 
Old 11-11-2004, 10:37 PM   #14
masand
Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 58
have a look at this small tutuorial i wrote for my LUG
-------------


First of all you need to see which partition you want to mount
YOU can see that by running the following command at bash# prompt

#fdisk /dev/hda

If your hard disk is use

Primary master hda
Primary slave hdb
Secondary master hdc
Secondary slave hdd

If you use wrong device then you may get error message such as
"Cannot open device hdc"
If command is successful you get

[root@gaurav qmail]# fdisk /dev/hda

The number of cylinders for this disk is set to 4865.
There is nothing wrong with that, but this is larger than 1024,
And could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)

Command (m for help):


At this prompt run p single character to see your partition table

Here is the result of my partition table


Command (m for help): p

Disk /dev/hda: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 * 1 561 4506201 b Win95 FAT32
/dev/hda2 562 3939 27133785 f Win95 Ext'd (LBA)
/dev/hda3 3940 4385 3582495 a5 FreeBSD
/dev/hda4 4386 4865 3855600 83 Linux
/dev/hda5 562 1096 4297356 7 HPFS/NTFS
/dev/hda6 1097 1606 4096543+ b Win95 FAT32
/dev/hda7 1607 3008 11261533+ b Win95 FAT32
/dev/hda8 3009 3872 6940048+ b Win95 FAT32
/dev/hda9 3873 3939 538146 b Win95 FAT32


You can easily recognize which drive you want to mount
Here I have my windows partitions as

devices Windows Partitions

/dev/hda1 C
/dev/hda5 D
/dev/hda6 E
/dev/hda7 F
/dev/hda8 G
/dev/hda9 H


Do not confuse with /dev/hda2
It is my extended partition you cannot mount that whole partition but you can only mount the logical drives in this partition

Here say if I want mount my E drive in Linux
I need to have an empty folder somewhere to mount.
We can make a folder anywhere but as going by the convention we make all the folders and mount them in
/mnt folder
So, go to the mnt folder under root directory
Make a new folder in mnt directory say win_e

If you want to mount it temporarily (till the system is running)
You can mount it by the following command

#mount /dev/hda6 /mnt/win_e

The syntax of the command is easy to interpret
/dev/hda6 gives the device you want to mount
/mnt/win_e gives the path of folder you want to mount


------------

regards
 
Old 11-11-2004, 11:47 PM   #15
Junior41180
Member
 
Registered: Dec 2003
Location: Florida
Posts: 157

Rep: Reputation: 30
Quote:
Originally posted by michaelk
I question this statement. Look at the ouput of the fdisk command
fdisk -l /dev/hde (that is a small L)
hde is my 200 gig drive. hda is my windows drive, hdb is my linux drive, linux is only installed on one drive, not sharing any other partition.

my windows drive is partitioned in two partitions using partition magic. 1 is 14.6 GB's, my second partition off of hda is 78.5 GB's

hde is on an ATA133 card, so what's to question? I know my own drives.

edit:

/dev/hde = storage for windows

[root@34 junior]# fdisk -l /dev/hde

Disk /dev/hde: 200.0 GB, 200049647616 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hde1 * 1 24321 195358401 7 HPFS/NTFS
[root@34 junior]#

/dev/hda = windows

/dev/hda1 * 1 30473 15358360+ 7 HPFS/NTFS
/dev/hda2 30474 193821 82327392 7 HPFS/NTFS

/dev/hdb = linux

[root@34 junior]# fdisk -l /dev/hdb

Disk /dev/hdb: 20.0 GB, 20020396032 bytes
16 heads, 63 sectors/track, 38792 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

Device Boot Start End Blocks Id System
/dev/hdb1 * 1 12190 6143728+ 83 Linux
/dev/hdb2 12191 38792 13407408 5 Extended
/dev/hdb5 12191 14790 1310368+ 82 Linux swap
/dev/hdb6 14791 38792 12096976+ 83 Linux
[root@34 junior]#

Last edited by Junior41180; 11-12-2004 at 12:00 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Extended Partition damica Linux - Hardware 2 01-15-2004 09:02 AM
Mounting extended windows partition silkmaze Linux - Newbie 5 08-20-2003 06:18 AM
Mounting Extended XP Partition silkmaze Linux - General 4 08-20-2003 06:03 AM
mounting a extended partition ntfs CleonII Linux - General 3 05-17-2003 10:02 PM
Mounting mounting extended partition and its Logical drives desbyleo Linux - Newbie 10 02-18-2002 03:13 PM


All times are GMT -5. The time now is 08:25 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration