Re: Linux partitions

From: wolfgang kern (nowhere_at_nevernet.at)
Date: 05/12/04


Date: Wed, 12 May 2004 12:45:15 +0200


Hi Beth,

[]
| > and where to find what's behind this partitions
| > (BootRecord-interpretation and DirStructures).
| > I don't like to read many books,
| > I'd prefer compact tables with the needed info.

| Ralf Brown's has a compact table under "int 19h - bootstrap loader"
| (there is a table near it which lists all of the types)...those that
| relate to Linux in my now rather old version of Ralf's list are:
| 81h Linux
| 82h Linux Swap partition
| 83h Linux native file system (ext2fs/xiafs)
| [ Copied from Ralf Brown's Interrupt List ]

Yes my RBIL (DnLd end of 2003) shows the same,
but I thought there 'must' be more.

| One thing to pay attention to, wolfgang...technically, the byte in the
| MBR is the _OS indicator_ and NOT a "partition type indicator"...
[]
| So, looking at this, you'll have to use some other means to determine
| the specific FS...actually reading some sectors and looking to see if
| certain bytes and formats are being used...

Right, I realised this.
I always check the bootsector from a partition as well.

May I rely on at least the partition entries are uniform structures?
If so I could skip over unknown/unsupported parts in the chain.

| ...implement a "cheap hack" (rather than teaching the FS drivers to
| "hide" things? Nah, we'll just change its number! That'll "hide" it!
| ;)...

KESYS isn't much different here ;)
1994 I did not check if '4B'="K" is already in use by someone else.
It's more by coincidence that this partition-type is still 'owned' by me.
The identification-story is found in the boot-record anyway,
which is part of the partition-sector on KESYS formatted media.

| ...especially because if you
| misdiagnose the FS and then start _writing_ anything, you're just
| going to screw things up big-time that you might ruin it permanently
| ;)...

That's the point.

| They probably should have set up some "authority" by which you
| "register" the OS indicator, who keeps track of it and prevents
| clashes and abuse of the system...but, well, they didn't...

And now it's too late.

[]
| ...the documentation for an FS might, in fact,
| helpfully even suggest how Linux itself works it out or whatever (and,
| of course, if you copy the "official" method of detection, then it
| should be trustworthy, as that's what the OS itself probably uses
| ;)...

Yes.

Thanks Beth
__
wolfgang

-------------
While I fixed some bugs in my M$-FAT-export module, I got the idea
to add HPFS, NTFS and Linux (at least) import-modules to KESYS.

partition-types:
LINUX:
81h old linux
82h swap
83h primary /reisnerFS /JFS/ XFS
85h ext /ext2 /ext3
8eh LVM

FAT: (the hidden, and 0e weren't supported yet)
01 FAT12 <16MB 11 hidden
04 FAT16 <32MB 14 hidden
05 ext.
06 FAT16 <8GB 16 hidden
0b FAT32 1b hidden
0c FAT32 LBA 1c hidden
0e FAT16 LBA 1e hidden
0f FAT32 '0b'ext 1f hidden



Relevant Pages

  • Re: Windows multiboot (aaargh!)
    ... >> The Linux boot floppy is a bit more tricky. ... So I tried adding cfdisk to a spare Debian Woody boot ... > I reduced all the partition sizes by a third. ...
    (Debian-User)
  • Re: Linux, XP, Win2003 Server multi-boot
    ... Go to PC magazine's web site and do a search on "partitioning for linux" to see articles and reviews about partitioning philosophy and tools. ... Tools are now available in many bootable CD based Linux distributions to resize the C: partition of your disk drive to make room for Linux. ... I finally got the new machine - it came with one of those 'recovery' disks - and a 5 gig recovery partition that isn't supposed to be deleted. ... Once I feel I have everything in order - always lose something when I get a new computer - I'll format that disk and install Linux & Win2003 on it I guess. ...
    (alt.os.linux.redhat)
  • Re: Linux Windows dual boot not restoring properly
    ... Linux is showing the Windows folders in its file manager under the name of what effectively was drive C. ... decreases that Windows partition size in order to make a partition ... And at startup, can scan the hard drives, for partition types it ...
    (alt.comp.hardware.pc-homebuilt)
  • Re: Panasonic HD Recorders - What disk format?
    ... The earlier part of this is more about what may be Linux partitioning, ... might be possible to present the recorder with a larger disk already ... Most DOS/Windows utilities such as FDisk, Ghost, and Partition Magic Pro ... prompts to format it. ...
    (alt.os.linux)
  • Disc Partitioning for Multi-Boot (long)
    ... We need to get the data off of the NTFS partition. ... But the next question is how to partition the drive so Windows and Linux ... The fdisk supplied with Windows 98 cannot manage that disc. ... How shall I make a multi-boot system out of that machine, ...
    (Fedora)