LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 10-25-2006, 11:15 PM   #1
jgombos
Member
 
Registered: Jul 2003
Posts: 256

Rep: Reputation: 32
[solved] Using dd to clone an NTFS partition from a strange partition table


hda1 is the source partition, and hdb1 is the destination. The partitions appear to be the same when I ask for a basic listing:
Code:
root@1[knoppix]# fdisk -l

Disk /dev/hda: 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/hda1   *           1         561     4506201    7  HPFS/NTFS
/dev/hda2             562       24321   190852200    f  W95 Ext'd (LBA)
/dev/hda5             562       24191   189807943+   7  HPFS/NTFS
/dev/hda6           24192       24321     1044193+   7  HPFS/NTFS

Disk /dev/hdb: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/hdb1               1         561     4506201    7  HPFS/NTFS
root@1[knoppix]#
But I get some strange output when I list hda1 seperately:
Code:
root@1[knoppix]# fdisk /dev/hda1

Command (m for help): p

Disk /dev/hda1: 4614 MB, 4614349824 bytes
255 heads, 63 sectors/track, 560 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

This doesn't look like a partition table
Probably you selected the wrong device.

     Device Boot      Start         End      Blocks   Id  System
/dev/hda1p1   ?       13578      119522   850995205   72  Unknown
Partition 1 has different physical/logical beginnings (non-Linux?):
     phys=(368, 111, 45) logical=(13577, 238, 11)
Partition 1 has different physical/logical endings:
     phys=(371, 101, 51) logical=(119521, 238, 60)
Partition 1 does not end on cylinder boundary.
/dev/hda1p2   ?       45382       79243   271987362   74  Unknown
Partition 2 has different physical/logical beginnings (non-Linux?):
     phys=(67, 115, 32) logical=(45381, 70, 3)
Partition 2 has different physical/logical endings:
     phys=(299, 114, 44) logical=(79242, 34, 29)
Partition 2 does not end on cylinder boundary.
/dev/hda1p3   ?       10499       10499           0   65  Novell Netware 386
Partition 3 has different physical/logical beginnings (non-Linux?):
     phys=(114, 111, 32) logical=(10498, 56, 41)
Partition 3 has different physical/logical endings:
     phys=(353, 115, 52) logical=(10498, 56, 40)
Partition 3 does not end on cylinder boundary.
/dev/hda1p4          167628      167631       25817+   0  Empty
Partition 4 has different physical/logical beginnings (non-Linux?):
     phys=(0, 0, 0) logical=(167627, 190, 52)
Partition 4 has different physical/logical endings:
     phys=(0, 0, 0) logical=(167630, 245, 26)
Partition 4 does not end on cylinder boundary.

Partition table entries are not in disk order
The first partition was created the XP Pro SP2 installer, and the rest by the XP Pro SP2 GUI disk manager. Here is what the destination partition looks like (created with Knoppix 4.0's fdisk):
Code:
root@1[knoppix]# fdisk /dev/hdb1

The number of cylinders for this disk is set to 8940.
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): p

Disk /dev/hdb1: 4614 MB, 4614349824 bytes
16 heads, 63 sectors/track, 8940 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes

This doesn't look like a partition table
Probably you selected the wrong device.

     Device Boot      Start         End      Blocks   Id  System
/dev/hdb1p1   ?      216399     1904881   850995205   72  Unknown
Partition 1 does not end on cylinder boundary.
/dev/hdb1p2   ?      723265     1262922   271987362   74  Unknown
Partition 2 does not end on cylinder boundary.
/dev/hdb1p3   ?      167316      167316           0   65  Novell Netware 386
Partition 3 does not end on cylinder boundary.
/dev/hdb1p4         2671568     2671619       25817+   0  Empty
Partition 4 does not end on cylinder boundary.

Partition table entries are not in disk order
Neither of these tables look right, and even worse, they don't appear to match. There should not even be a /dev/hdb1p2, /dev/hdb1p3, or /dev/hdb1p4, so that's also mysterious.

Any clues? Should I expect problems cloning the first NTFS partition, if I use the command "dd if=/dev/hda1 of=/dev/hdb1"?

Last edited by jgombos; 10-31-2006 at 03:43 PM. Reason: tag as solved
 
Old 10-25-2006, 11:37 PM   #2
haertig
Senior Member
 
Registered: Nov 2004
Distribution: Debian, Ubuntu, LinuxMint, Slackware, SysrescueCD
Posts: 2,004

Rep: Reputation: 304Reputation: 304Reputation: 304Reputation: 304
Your problem is that you are trying to run fdisk on a partition. fdisk works on disks. That's why, for example, fdisk /dev/hda would work, but fdisk /dev/hda1 would not. /dev/hda is a disk, /dev/hda1 is the first partition on that disk.
 
Old 10-26-2006, 12:10 AM   #3
jgombos
Member
 
Registered: Jul 2003
Posts: 256

Original Poster
Rep: Reputation: 32
Yup, I think you're right on the money. I almost stopped myself from running fdisk /dev/hda1, but then I thought, naw, fdisk will error if it can't operate on a single partition. Well, it didn't. I'm glad to know that I was just chasing a ghost. dd ran fine.
 
  


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
"No partition table or unknown signature on partition table" 10.1 install madcow007 Slackware 4 02-09-2009 11:04 AM
NTFS partition/file table spontaneously corrupted lm317t Linux - Software 3 01-05-2006 09:11 AM
Slack 10: S-ATA = "No partition table or unknown signature on partition table"? dissolved soul Slackware - Installation 11 08-05-2004 02:12 PM
strange partition table - boot partition empty etanter Linux - General 0 12-23-2003 09:46 AM
Strange error reffering partition table and swap Thetargos Linux - General 1 06-19-2003 10:59 AM


All times are GMT -5. The time now is 05:22 AM.

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