f.zz.de
posts /

partitioning tools

Posted Sun 12 Aug 2007 10:51:43 PM CEST
in

This hackmeeting we successfully wrote a bootloader and mechanism for the SNI RM series. As a matter of fact all known partitioning tools are basically broken and multiple aspects. SGI or SNI partitions must start on a cylinder boundary and as those must even have the size which is a multiple of the cylinder. fdisk fails to create a volhdr which is a multiple of a cylinder. It does though create partitions which start on cylinder boundarys. It still ignores the real geometry of the disk and instead relys on the kernel and its HDIO_GETGEOM capability which basically gives back a DOS stripped view on the world which no one really shares (except the WinDOS world). And by trying around fdisk showed another really nasty bug: not beeing able to create a second partition.On the other hand parted is even worse. It fails to create any partition on a cylinder boundary. Everything is garbled to hell.

The problem is not existand on SGI as they decided to ignore the Cylinder/Head/Sector world and instead go the LBA aka Sector number way which is much easier. SNI instead used the same volume header format as SGI but were "very clever" by writing a second partition table to the very end of every disk. The problem is that the MipsPROM uses those SNI specific partition tables and not the volhdr ones. We now must ensure that those partition tables match which is impossible when those f*** tools decide to ignore the constrain of cylinder boundaries (which is valid for SGI too)