[haiku-bugs] Re: [Haiku] #8990: intel partiton addon allows creating partitions > 2TB (easy)

  • From: "pdziepak" <trac@xxxxxxxxxxxx>
  • Date: Mon, 26 Jan 2015 11:58:06 -0000

#8990: intel partiton addon allows creating partitions > 2TB (easy)
------------------------------------------+----------------------------
   Reporter:  luroh                       |      Owner:  bonefish
       Type:  bug                         |     Status:  new
   Priority:  normal                      |  Milestone:  R1
  Component:  Partitioning Systems/Intel  |    Version:  R1/Development
 Resolution:                              |   Keywords:
 Blocked By:                              |   Blocking:
Has a Patch:  1                           |   Platform:  All
------------------------------------------+----------------------------

Comment (by pdziepak):

 Replying to [comment:14 phoudoin]:
 > > If the sector size is 2kB nothing prevents MBR from supporting 8TB
 partitions.
 >
 > But mostly all software from BIOS to other operating systems and Disk
 tools will break hard using such MBR. And eventually corrupt data while
 doing it.

 Linux and Windows seem to support non-512 byte sectors even when using
 MBR.

 > Better be on the safe side when it comes to user's data.

 I can't see how not hardcoding 512 byte sectors makes anything safer.

 >
 > Even if someone in the future start to play with this partition add-on
 BlockSize() value, the more explicit check will stands on the safe side.
 >
 > The reality is not that MBR unit is sector, the reality is that most
 soft using MBR info assumes a 512 bytes sector and could do BAD thing if
 MBR was written with another size in mind. That's why 4k disk reports
 emulated 512 sizes sectors until everybody use GPT and/or operating
 systems supporting native 4K sectors.
 >
 > Again, it's not about code quality, it's about (your) data safety.

 I am sorry, but this is silly. You are basically saying that since there
 is some broken software with hardcoded 512 byte sectors we should, on
 purpose, break our code in the same way. If a user has a device with
 logical 4k sectors and for whatever reason wants to use MBR partitioning
 on it why disallow it?

--
Ticket URL: <https://dev.haiku-os.org/ticket/8990#comment:16>
Haiku <https://dev.haiku-os.org>
Haiku - the operating system.

Other related posts: