LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-06-2011, 12:26 AM   #1
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Rep: Reputation: 17
Can't create partition using fdisk


Hi,

I recently expanded the RAID on an iSCSI device which is shared out to a linux server. Fdisk correctly sees the new size but it won't let me add a third partition. It complains about overlapping partitions whenever I try to add it.

If I 'remove' the partition, the overlapping error goes away. The interesting thing here is that when attempting to use the default sizes to setup the partition the printed screen shows completely different results (which I can understand is why its complaining about overlapping)

I'm not sure why its not accepting the cylinder sizes I want. Anyone have any ideas as to what's wrong here?

Code:
Disk /dev/sde: 5495.3 GB, 5495280467968 bytes
255 heads, 63 sectors/track, 668096 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: 0x1f75ee7d

   Device Boot      Start         End      Blocks   Id  System
/dev/sde1               1      267349  2147480811   83  Linux
/dev/sde2          267350      485888  1755414517+  83  Linux
root@srv-ub-01:/data# fdisk /dev/sdc

WARNING: The size of this disk is 5.5 TB (5495280467968 bytes).
DOS partition table format can not be used on drives for volumes
larger than (2199023255040 bytes) for 512-byte sectors. Use parted(1) and GUID
partition table format (GPT).


WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').

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

Command (m for help): p

Disk /dev/sdc: 5495.3 GB, 5495280467968 bytes
255 heads, 63 sectors/track, 668096 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: 0x1f75ee7d

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1               1      267349  2147480811   83  Linux
/dev/sdc2          267350      485888  1755414517+  83  Linux
/dev/sdc3          218539      400747  1463585760   83  Linux

Partition table entries are not in disk order

Command (m for help): v
Warning: partition 1 overlaps partition 3.
Warning: partition 2 overlaps partition 3.
Remaining 2927179004 unallocated 512-byte sectors
 
Old 05-06-2011, 10:34 AM   #2
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Original Poster
Rep: Reputation: 17
anyone have any ideas?
 
Old 05-06-2011, 02:37 PM   #3
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Original Poster
Rep: Reputation: 17
bump
 
Old 05-06-2011, 05:03 PM   #4
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Original Poster
Rep: Reputation: 17
bump again
 
Old 05-06-2011, 05:07 PM   #5
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
Did you read the error message in your first post? It says that you have to use parted to manipulate the partitions and you have to use GPT partition tables instead of MBR style partition tables because the disk is larger than 2 TB.

Last edited by stress_junkie; 05-06-2011 at 05:08 PM.
 
Old 05-06-2011, 08:18 PM   #6
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Original Poster
Rep: Reputation: 17
I did see that message. but the 2 partitions that are already on that disk are either 2TB or 1 TB, totaling 3TB. The extra disk space is also less than 2TB. I don't understand why I can't add that all of a sudden when I created the other two partitions without a problem.

How difficult is it to covert to GPT without blowing away the data that's already on there? Or can I create the desired partition using parted with GPT and leave the other partitions as msdos?
 
Old 05-07-2011, 06:19 AM   #7
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
Quote:
Originally Posted by NetAX View Post
How difficult is it to covert to GPT without blowing away the data that's already on there? Or can I create the desired partition using parted with GPT and leave the other partitions as msdos?
I believe that the two methods are completely incompatible. The MSDOS style MBR disk structure uses 512 bytes at the beginning of the disk while the GPT uses 4096 bytes at the beginning of the disk.

I believe that you will have to back up the data on the disk, then start over using the GPT style disk disk partitions, then restore the backed up data.

I have read about GPT on large disks but I haven't worked with GPT or large disks. I'm just telling you what I've read.
 
Old 05-10-2011, 12:44 PM   #8
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Original Poster
Rep: Reputation: 17
I will backup the data most definitely. There appears to be a way to convert the MSDOS partition table to GPT without inccuring any data loss, but that's up for discussion as to whether or not that truly is the case. How likely is it that performing the conversion will correct the issue with the partitions overlapping?
 
Old 05-11-2011, 03:43 AM   #9
shqnayaz
LQ Newbie
 
Registered: Sep 2009
Location: Bangalore
Distribution: RedHat Fedora Centos
Posts: 9

Rep: Reputation: 1
Hi there!, I have faced Similar problem (Overlapping of Partitions), when you have GPT taken over precedence for Disk Tables, You can use the GUI Mode to Do this or if you have any appliance like NAS-SAN Filers you can make partitions from their, any further creation of partitions using fdisk will not be replicated upon volumes creation.

Do Back-up of the data, or you will lose it when changing partition modes
 
Old 05-18-2011, 05:02 PM   #10
NetAX
Member
 
Registered: Mar 2004
Location: Boston, MA
Distribution: SuSE Linux Open/Enterprise, Red Hat, Ubuntu
Posts: 147

Original Poster
Rep: Reputation: 17
For anyone who's looking for an answer to this, I solved it by installing gdisk and running a "transformation" on the partition table for the disk. I didn't lose any data but I did back it all up as a precaution, since this tool may or may not do the task for you. It ended up fixing the overlapping somehow and allowed me to add a new partition without any problems.

Basically you run the tool on the disk in question and navigate to the menu which allows you to convert the table. I basically ran the following commands to convert from MBR to GPT.

run # gdisk /dev/sde
1) ? for help
2) p to print partition table
3) r to run conversion process
4) ? for help again
5) f to run conversion
6) p to print partition table
7) v to verify partition table
8) w to write table
 
  


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
If i deleted a partition using fdisk , will that delete the data on this partition? wmasry Linux - Newbie 13 11-27-2024 01:45 AM
use fdisk to create partition aclhkaclhk Linux - Hardware 1 08-20-2009 03:03 AM
fdisk fails to create partition, but drive has free space whysyn Linux - Software 3 04-17-2007 02:13 PM
FDISK does not let me create partitions millikin691@hotmail. Slackware - Installation 54 08-28-2006 07:04 PM
Create a bootable disk containing fdisk manudath Linux - Software 1 03-14-2005 12:27 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

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