LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
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 02-14-2011, 03:30 PM   #1
JeffC1
Member
 
Registered: May 2008
Posts: 89

Rep: Reputation: 15
Unable to Format brand new HPFS/NTFS drive


Hello all

I'm unable to format a new drive. I've tried commands, which complete without error, yet the drive is still listed as NTFS.


===========Ive tried the following

[root@server ~]# mke2fs -j -m1 /dev/sdb1
mke2fs 1.39 (29-May-2006)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
244203520 inodes, 488375992 blocks
4883759 blocks (1.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=0
14905 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848

Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 20 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.



=========also tried


[root@server ~]# mkfs.ext3 /dev/sdb1
mke2fs 1.39 (29-May-2006)
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
244203520 inodes, 488375992 blocks
24418799 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=0
14905 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848

Writing inode tables: done
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 27 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.


==============fdisk p output

The number of cylinders for this disk is set to 243199.
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)
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): p

Disk /dev/sdb1: 2000.3 GB, 2000388063744 bytes
255 heads, 63 sectors/track, 243199 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System



help?
 
Old 02-14-2011, 03:40 PM   #2
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007
Are you getting any errors or warnings about the drive itself? And have you tried using gparted?
 
Old 02-14-2011, 03:54 PM   #3
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
I dont have access to GUI on this system. I have not tried any other tools.
So far i haven't seen any warnings or errors. Where can I check them?
 
Old 02-14-2011, 03:59 PM   #4
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007
Post your /var/log/messages and the output of dmesg, hopefully we can resolve your issue. One more question though, is the drive accessible at all, and can you mount it?
 
Old 02-14-2011, 04:16 PM   #5
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
Quote:
==============fdisk p output

The number of cylinders for this disk is set to 243199.
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)
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)

Command (m for help): p

Disk /dev/sdb1: 2000.3 GB, 2000388063744 bytes
255 heads, 63 sectors/track, 243199 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
It would appear that you have not created the partition, judging from your fdisk output. So I have to ask the question:

Did you create a partition first?

Example:

Code:
$ fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0xa4838b04.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.

Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-19457, default 1): 
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-19457, default 19457): 
Using default value 19457

Command (m for help): p

Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xa4838b04

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1       19457   156288321   83  Linux

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.
The above example would show the required steps to create a partition using fdisk. If you've already done this then disregard the example. It just was not clear from your post whether or not you had created the partition first.

Regards,

Fordeck
 
Old 02-14-2011, 04:24 PM   #6
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
I didnt do that step! Thanks trying now
 
Old 02-14-2011, 04:32 PM   #7
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007Reputation: 1007
It's always the simple things....
 
Old 02-14-2011, 04:47 PM   #8
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
Calling ioctl() to re-read partition table.

WARNING: Re-reading the partition table failed with error 22: Invalid argument.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.

---------- Post added 02-14-11 at 05:47 PM ----------

The change didnt save.
 
Old 02-14-2011, 04:54 PM   #9
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
Could you post the output from:

Code:
fdisk -l
Regards,

Fordeck
 
Old 02-14-2011, 04:59 PM   #10
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
Disk /dev/sdb: 2000.3 GB, 2000396746752 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 1 243200 1953503968+ 7 HPFS/NTFS
 
Old 02-14-2011, 05:04 PM   #11
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
Is this disk mounted by any chance?

Also are you going to make the whole disk a single partition?

Regards,

Fordeck
 
Old 02-14-2011, 06:12 PM   #12
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
The disk may be mounted, yes.. I will double check.
It will also be a single partition.
 
Old 02-14-2011, 06:14 PM   #13
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
The disk isnt mounted
 
Old 02-14-2011, 06:39 PM   #14
fordeck
Member
 
Registered: Oct 2006
Location: Utah
Posts: 520

Rep: Reputation: 61
You should probably delete the existing HPFS/NTFS partition, and then create the new linux partition. This can all be done with fdisk, just use the 'd' command prior to creating the new partition.

Regards,

Fordeck
 
Old 02-14-2011, 07:12 PM   #15
JeffC1
Member
 
Registered: May 2008
Posts: 89

Original Poster
Rep: Reputation: 15
fdisk /dev/sdb1


Disk /dev/sdb1: 2000.3 GB, 2000388063744 bytes
255 heads, 63 sectors/track, 243199 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1p1 1 243199 1953495936 83 Linux


mount -l
Disk /dev/sdb: 2000.3 GB, 2000396746752 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sdb1 1 243200 1953503968+ 7 HPFS/NTFS



I'm getting conflicting results with a fdisk-l and fdisk
 
  


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
NTFS Configuration Tool Can Not Detect SATA drive in NTFS format jlconferido Linux - Newbie 7 06-30-2007 07:07 PM
Hpfs/ntfs Bobymc Linux - Software 2 04-22-2006 10:58 PM
HPFS / NTFS problem C: partition appears to be empty thk33 Linux - Software 2 08-11-2004 10:22 AM
Lost XP HPFS/NTFS partition ajkhan Linux - General 3 09-19-2003 07:54 AM
how to moutn hpfs/ntfs farhan Linux - General 3 03-10-2003 08:08 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:47 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