VOGONS


First post, by marooned_on_mars

User metadata
Rank Member
Rank
Member

Regardless of what type of disk writing action I do (from copying to directory creation) DosBox hangs, and the HDD file bloats (gets over 2GB in size)

Here's the creation in bximage

========================================================================
bximage
Disk Image Creation Tool for Bochs
$Id: bximage.c 10933 2012-01-04 19:34:08Z vruppert $
========================================================================

Do you want to create a floppy disk image or a hard disk image?
Please type hd or fd. [hd]

What kind of image should I create?
Please type flat, sparse or growing. [flat]

Enter the hard disk size in megabytes, between 1 and 129023
[10] 200

I will create a 'flat' hard disk image with
cyl=406
heads=16
sectors per track=63
total sectors=409248
total size=199.83 megabytes

What should I name the image?
[c.img]

Writing: [] Done.

I wrote 209534976 bytes to c.img.

The following line should appear in your bochsrc:
ata0-master: type=disk, path="c.img", mode=flat, cylinders=406, heads=16, spt=63

ImgMount in DosBox (before formatting):

imgmount 2 C:\Portable\Games\DosBox\c.img -t hdd -size 512,63,16,406 -fs none

ImgMount in DosBox (after formatting with FreeDos's FDISK):

imgmount c C:\Portable\Games\DosBox\c.img -t hdd -size 512,63,16,406 -fs fat

When I load DosBox all that I can see as a hint to the problem is in the console:

Using Partition 0 on drive; skipping 63 sectors
Loaded image has no valid magicnumbers at the end!
Mounted FAT volume is FAT32 with 17395994 clusters

The weird thing is that I formatted the partition as FAT12 not 32, as I assumed FAT32 wouldn't work.

Last edited by marooned_on_mars on 2012-08-28, 15:43. Edited 1 time in total.

Reply 2 of 13, by Joey_sw

User metadata
Rank Oldbie
Rank
Oldbie

well FAT12, max cluster = 2^12 about 4K cluster,
max sectors/cluster = 2^16 = 64K sectors
1 sector = 512 byes
so, max bytes/cluster = 32 KB

32KB * 4K = 128 MB

and your HDD image size was ?

-fffuuu

Reply 3 of 13, by marooned_on_mars

User metadata
Rank Member
Rank
Member

@Dominus

That being?

@Joey_sw
Does that mean FAT12 partitions cannot exceed 128MB in size, or that I need to re-calculate the clusters?
Was 200MB BTW

Reply 5 of 13, by marooned_on_mars

User metadata
Rank Member
Rank
Member

Thanks, but seems to have no effect whatsoever, same message in the console, and still hangs up. Tried formatting to FAT32 and that doesn't seem to help.

Reply 6 of 13, by Joey_sw

User metadata
Rank Oldbie
Rank
Oldbie

FAT12 can't exceed 128 MB (about 134 million bytes)
as mount with "imgmount (letter) -t hdd" that mean you can only have 1 partition on it.

how about formating to FAT16?
-max 2GB,
-max 63 sectors per tracks
-max 1024 cyls per heads
-max 255 heads

the limitation are based on INT 13h specs, and FAT16 limitation.

please tell, how the hdd image was partioned.

-fffuuu

Reply 7 of 13, by marooned_on_mars

User metadata
Rank Member
Rank
Member

Apparently the partition is FAT16 instead of FAT32 and there's only one primary partition.

Reply 8 of 13, by Jorpho

User metadata
Rank l33t++
Rank
l33t++

Wait a second:

marooned_on_mars wrote:

ImgMount in DosBox (after formatting with FreeDos's FDISK):

Did you actually run FORMAT.COM , or did you only run FDISK?

Admittedly I have never used FreeDOS FDISK, but I would not be surprised if, after partitioning a drive with FDISK, you still need to format it.

Joey_sw wrote:

FAT12 can't exceed 128 MB

Wikipedia says 32 MB, which at least fits with my memories of DOS 3.3.

Reply 9 of 13, by marooned_on_mars

User metadata
Rank Member
Rank
Member

When I try to format, this is reported:

  Boot Sector contents implausible, disk not yet FAT formatted

Win98? Default BPB *FAT1x* 65535 sectors/FAT, 0 root size. FAT32 forced.
GENIOCTL/4860 error 0D. No FAT32 kernel?
FAT1x FAT size 65535 sectors?

[Error 55]

Have no idea what's the problem. FDISK reports the partition as FAT16 😖

Reply 11 of 13, by marooned_on_mars

User metadata
Rank Member
Rank
Member

Which ones specifically? By the way, I'm not interested in installing Win98 in DosBox, I only want to format the HDD image and just use DOS.

Reply 12 of 13, by Jorpho

User metadata
Rank l33t++
Rank
l33t++

If I am not mistaken, 2GBpartitioned.zip, 2GBFreeDOS.zip, and 2GBFAT16NO-OS.zip are all completely empty disk images which should mount fine in DOSBox, and onto which you can install anything you like.

marooned_on_mars wrote:

When I try to format, this is reported:

What were you typing when you mounted the image, and what were you typing when you ran Format?

Alternatively, apparently the Megabuild version of DOSBox includes a utility called Imgmake which might work a little better than bximage. There is a very old thread about it at Patch: Imgmake - creates floppy or harddisk images ; the Megabuild is available at http://home.arcor.de/h-a-l-9000/ . (You need to run Imgmake after starting that version of DOSBox.)

Reply 13 of 13, by marooned_on_mars

User metadata
Rank Member
Rank
Member

2GB is a bit too much for me. I intend to make the image "portable"

Mount command:

imgmount c C:\Portable\Games\DosBox\c.img -t hdd -fs fat

Format command:

format C:

I'll try that custom build that you suggested

EDIT: Works like a charm, thanks! ^^