LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 12-23-2012, 04:39 PM   #1
da1
Member
 
Registered: May 2007
Distribution: FreeBSD
Posts: 110

Rep: Reputation: 16
CentOS 6.3 x64 - cannot create a second size-identical partition (fdisk)


Hi guys,

The box is a P4, 3GHz CPU, with 2x WD 80GB S-ATA identical disks. The OS was installed during a time when there was only 1x disk available and now, having inserted a 2nd HDD, I want to migrate to a mirrored setup. The current installation has a /boot partition and the rest is LVM based.

The problem is that if I want to create a /boot partition on the second disk that is identical to the /boot partition from the first one (same Start cylinder and End cylinder), I do not get the same Blocks on the second disk.

First disk:
Code:
[root@test ~]# fdisk -l /dev/sda

Disk /dev/sda: 80.0 GB, 80000000000 bytes
255 heads, 63 sectors/track, 9726 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: 0x000b4ee9

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          64      512000   83  Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2              64        9726    77611008   8e  Linux LVM
Second disk:
Code:
Command (m for help): n
Command action
   e   extended
   p   primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-9726, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-9726, default 9726): 64

Command (m for help): p

Disk /dev/sdb: 80.0 GB, 80000000000 bytes
255 heads, 63 sectors/track, 9726 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: 0x90909090

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1          64      514048+  83  Linux
Having this problem, the raid1 for the /boot partition will not work.

I also tried setting the End cylinder to 63 but that didn't work either.

Any suggestions?

Last edited by da1; 12-23-2012 at 06:16 PM.
 
Old 12-23-2012, 06:16 PM   #2
da1
Member
 
Registered: May 2007
Distribution: FreeBSD
Posts: 110

Original Poster
Rep: Reputation: 16
Solved by using the "-u" flag for fdisk.
 
  


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 On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Can't create partition using fdisk NetAX Linux - Server 9 05-18-2011 05:02 PM
use fdisk to create partition aclhkaclhk Linux - Hardware 1 08-20-2009 03:03 AM
Is there a way to partition with fdisk and specify size in MB? Thaidog Linux - General 3 03-19-2009 05:30 AM
unable to specify size for new partition using fdisk fedora_user Linux - Software 3 05-14-2007 11:09 AM
fdisk partition size differs from mounted partition size jimieee Linux - General 3 10-15-2003 03:10 AM


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