And for tracking purposes, I updated the FDISK bug at https://sourceforge.net/p/freedos/bugs/300/
Jim On Sun, Feb 21, 2021 at 6:30 PM Jim Hall <jh...@freedos.org> wrote: > > > On Sun, Feb 21, 2021 at 6:15 PM Jim Hall <jh...@freedos.org> wrote: > >> On the virtual get-together today, we tested the new FDISK 1.3.3 with a >> large virtual hard disk. I wanted to report a bug from that. >> >> Test setup: QEMU on Linux. "hda" (hard drive .. created with *qemu-img >> create 4gb.img 4G*) is set to a blank 4GB virtual disk file. "fda" >> (floppy) is set to a virtual floppy image with a copy of FDISK 1.3.3. >> "cdrom" is set to FreeDOS 1.3 RC3 (basically, the initial boot environment) >> >> Procedure: Boot QEMU using FreeDOS 1.3 RC3 and go into the installer, but >> immediately exit to DOS. This means the FreeDOS installer is on "A:" and >> the floppy image with FDISK 1.3.3 is on "B:" >> [...] >> Interestingly, things are quite different if I don't try to create that >> last 8MB logical drive. I'll send that in a follow-up. >> > > > Starting again with a completely new virtual hard drive image. > > Same process: boot into the installer, but immediately exit to DOS. Run > FDISK 1.3.3 (and yes, I said "Y" to "Do you want to use large disk (FAT32) > support") > > 1. "Create DOS partition or Logical DOS Drive" - "Create Primary DOS > Partition" - FDISK shows "Maximum space available for partition is 4103 > Mbytes" but I created the partition as only "3000" Mbytes. > > ... this creates a "3004" Mbytes partition > > 2. "Create DOS partition or Logical DOS Drive" - "Create Extended DOS > Partition" - FDISK shows "Maximum space available for partition is 1098 > Mbytes" and I used that default value to create the extended partition > > ... this creates a "1090" extended partition > > 3. FDISK lets me immediately set up a logical drive in the extended > partition. Set the first partition to "500" Mbytes > > ... this creates a "502" Mbytes partition > > 4. FDISK lets me immediately set up another logical drive. The "Maximum > space available for partition is 596 Mbytes" so I set the second partition > to that default value of "596" Mbytes > > ... this creates a "588" Mbytes partition > > 5. FDISK lets me immediately set up another logical drive - but in this > case, I back out to the main FDISK menu (but don't exit FDISK) > > 6. "Create DOS partition or Logical DOS Drive" - "Create Logical DOS > Drive(s) in the Extended DOS Partition" and I can see the "D:" logical > drive is "502 Mbytes" and the "E:" logical drive is "588 Mbytes" - and > FDISK says "All available space in the Extended DOS Partition is assigned > to logical drives" > > ... I am unable to create new partitions now (which is correct because > there's no more free space) > > > And that leaves me with a usable hard drive. > > If I shut down QEMU, and use Linux fdisk to examine the virtual drive > image, I see this: > > $ fdisk -l 4gb.img >> Disk 4gb.img: 4 GiB, 4294967296 bytes, 8388608 sectors >> Units: sectors of 1 * 512 = 512 bytes >> Sector size (logical/physical): 512 bytes / 512 bytes >> I/O size (minimum/optimal): 512 bytes / 512 bytes >> Disklabel type: dos >> Disk identifier: 0x00000000 >> Device Boot Start End Sectors Size Id Type >> 4gb.img1 63 6152894 6152832 2.9G b W95 FAT32 >> 4gb.img2 6152895 8385929 2233035 1.1G 5 Extended >> 4gb.img5 6152958 7181054 1028097 502M 6 FAT16 >> 4gb.img6 7181118 8385929 1204812 588.3M b W95 FAT32 > > > > There's some wasted space here, but it's a perfectly valid partition table. > > > So it seems there's a problem in FDISK when creating partitions. It's not > calculating available space correctly. > > > > Jim > >
_______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel