PCem requests for a Win9x Project

Support and general discussion.
Post Reply
eXo
Posts: 5
Joined: Thu 30 Jul, 2015 6:27 pm

PCem requests for a Win9x Project

Post by eXo » Tue 08 Jan, 2019 3:13 pm

Hello everyone. I go by eXo and spend a lot of time building retro game packs. I started with DOS, and then a few years back I tackled Windows 3.1.

I've had requests for years to start a Win9x preservation project. At one point I was working closely with a fellow who maintained the dosbox-x port, however he left, and the guy who took over ended up stripping the code in order to rebuild the core (don't ask me... that is what he said).

As I've been working on updating my DOS and Win3x projects, I've messed around with Win9x capabilities here and there. I decided to give PCem a go last summer and was really impressed by it. I believe PCem will be at the center of any Win9X project I create going forward, as dosbox simply isn't designed for such a thing. I mean, I am aware that Win98 can be run under dosbox, but the amount of limitations in doing so creates a lot of problems when you look at it from a perspective of preserving a large number of games.

Anyways, I've identified a handful of things that prevent a project like this from going forward at this time. Please understand, I am by no means asking Sarah to add anything specifically for me. I do believe the following things would be beneficial for many people. I am simply hoping that at some point they are added.

Also, I'm going to explain things as though anyone reading this has never heard of any of these things before, for simplicity sake. I am very aware that there are many technical geniuses here that know way more about it than myself. Please do not be offended by my over-explanations of anything.

One huge boon would be parent\child images. Lets say you have 50 Windows 98 games. Different games like different resolutions, drivers, etc. They also use different versions of third party software, like quicktime. There is a good chance that if you install 50 games to the same image, you will eventually start breaking some of the first games you installed. Not only that, but some games wrote files to silly places like the OS folder or the root drive, and in general it gets messy when you have a lot of games installed. This becomes an exponentially bigger issue when you are dealing with 1,000 games. Or 5,000 games..... The solution is for each game to use it's own windows install. This not only accomplishes the goal of each game having a pristine environment to run in, it makes it so each game is portable. If you want to copy Blade Runner over to a different computer, you just grab the blade runner image versus some win98 image that has 50 other games also installed to it.

A parent child image relationship would allow there to be a single clean win98 install. Then, when installing a game it gets installed to a child image. This child image would contain all of the new files, as well as modifications to the parent image. It is more commonly called "differencing". At one point we had this function in Dosbox-X using qcow2 images, however that left with the old dev.

This also saves *tons* of space compared to each game having it's own OS install. My math has shown that a Win98 install takes up about 200mb. Across a thousand games that is 200 gigabytes. I'm guessing there are closer to 5,000 win9x games, which would be a terrabyte of duplicated OS data.

The second major hurdle is a need for dynamic images. As it stands, I don't know how much space a particular game will require for an install until I've begun the process. At which point the install image has to be generated with this much space, plus a buffer for scratch disk and save games and such. This is a pretty time consuming process. I approached it with my Win3x pack by creating dozens of pre-made images in 50mb increments. Then, after I started installation and saw how much I needed, I would drop out and grab the image that was just above my space needs. This worked at the time because less than 50 games required booting real dos. The rest were able to run within dosbox w/out a disk image.

A dynamic disk system would allow a child install image to be created to report, say, 2 gigs of free space. However it would only take up as much space on your actual hard drive as there was actual data in it. That sounds confusing when I read it back, so here is a brief example. Currently if I create a 2gb image, then that image actually takes up 2gb. In a dynamic image scenario, if there is only 50mb worth of data in that image, then it would only take up about that much space on the disk (50mb + whatever amount of space the header info uses).

I may be way off base, but I would think that dynamic disk image support would be beneficial for just about anyone who uses PCEm, as it cuts down on the amount of wasted space being used by empty space in your disk images. And while parent\child images may not be as universally beneficial, they are key for folks who want to have a base setup and then use different apps\games\etc with that setup without each app\game\etc touching the other ones.

For me, personally, Win9x has become my "wild west" of PC gaming. When I first started these projects there were a few DOS collections around, but nothing that attempted to take them, clean it all up, put it into a front end, and make them playable for people who didn't have knowledge of DOS, dosbox, or emulation in general. When I tackled Win3x I spent years just acquiring disks online. Connection speed limitations at the time meant that if a win3x game did make its way onto BBS's or the early net, it was likely heavily ripped. Befoe you know it, the rip copies were more common than the real ones. It was important to me to preserve the *real* copies of these games. And while I haven't, and never will, have a complete DOS or Win3x preservation set, I simply try to get what I can in there. I've been at this for over 10 years and second to "thank you" messages, the most common question I get is, "Are you going to do a Win9x project".

Many 9x games are difficult to emulate, especially for people who don't understand emulation. It will likely take me another decade, but it's something I would really love to be able to do. PCem is *very* close to being able to be a platform I can use to accomplish this. If there is any interest in adding dynamic images and image differencing, then please let me know if there is anything I can do to encourage or support the process.

In the mean time, I have a lot of respect for what is being done here. I hope my message here is taken with the same goodwill it was intended with.

Thanks,
eXo

eXo
Posts: 5
Joined: Thu 30 Jul, 2015 6:27 pm

Re: PCem requests for a Win9x Project

Post by eXo » Tue 08 Jan, 2019 3:17 pm

follow up: someone at my discord has just informed me that maybe dynamic disk support is already in the works? If so, yay =)

User avatar
omarsis81
Posts: 645
Joined: Thu 17 Dec, 2015 6:20 pm

Re: PCem requests for a Win9x Project

Post by omarsis81 » Tue 08 Jan, 2019 5:23 pm

Good idea, but I don't think I'm understanding how it may work.
Let's say we have a C dynamic partition with only Windows 9x and then another partition where a specific game is installed?

If that's the case, then we'd need at least two images for each game. One for the CD-ROM image, and another for the installed game.

Am I right?

Laucian
Posts: 6
Joined: Mon 28 Nov, 2016 6:49 pm

Re: PCem requests for a Win9x Project

Post by Laucian » Tue 08 Jan, 2019 6:28 pm

omarsis81 wrote:
Tue 08 Jan, 2019 5:23 pm
Good idea, but I don't think I'm understanding how it may work.
Let's say we have a C dynamic partition with only Windows 9x and then another partition where a specific game is installed?

If that's the case, then we'd need at least two images for each game. One for the CD-ROM image, and another for the installed game.

Am I right?
PCem mainline only supports fixed disk images which are as big as the total size of the hard disk, so a 10GB image with a 200MB Windows install would be 10GB.
Dynamic images as supported by shermanp's patch allow images to be as big as used space, so a 10GB image with a 200MB Windows install would be around 200MB.
Differencing images are attached to a parent image and are only as big as the new content. So if it is based on the aforementioned dynamic image and you install a 20MB game, it would be around 20MB.

Because the parent image is never written to, you can use a single Windows install as the parent image for, say, 1000 games, each on their own child image, saving some 200 gigabytes of disk space.

eXo
Posts: 5
Joined: Thu 30 Jul, 2015 6:27 pm

Re: PCem requests for a Win9x Project

Post by eXo » Tue 08 Jan, 2019 7:07 pm

omarsis81 wrote:
Tue 08 Jan, 2019 5:23 pm
Good idea, but I don't think I'm understanding how it may work.
Let's say we have a C dynamic partition with only Windows 9x and then another partition where a specific game is installed?

If that's the case, then we'd need at least two images for each game. One for the CD-ROM image, and another for the installed game.

Am I right?
You would have:

C: Parent Image (Has Win98 installed)
C: Child Image (Has installed game files)
D: CD Image(s) (optional, depending on if game has a CD)

Laucian correctly describes how they would interact with each other. Apparently this is already possible in an unofficial build that was sent to me, however if I were to start my project based on such a thing, then I would be precluding myself from all of the advancements made on the main version.

However, typing this up has made me wonder if PCem can handle multi disc games via command line or some form of automation, or if the user has to use the menu to load a second disc manually.

terub56
Posts: 21
Joined: Mon 23 Jan, 2017 12:31 pm

Re: PCem requests for a Win9x Project

Post by terub56 » Tue 08 Jan, 2019 7:43 pm

eXo wrote:
Tue 08 Jan, 2019 7:07 pm
omarsis81 wrote:
Tue 08 Jan, 2019 5:23 pm
Good idea, but I don't think I'm understanding how it may work.
Let's say we have a C dynamic partition with only Windows 9x and then another partition where a specific game is installed?

If that's the case, then we'd need at least two images for each game. One for the CD-ROM image, and another for the installed game.

Am I right?
You would have:

C: Parent Image (Has Win98 installed)
C: Child Image (Has installed game files)
D: CD Image(s) (optional, depending on if game has a CD)

Laucian correctly describes how they would interact with each other. Apparently this is already possible in an unofficial build that was sent to me, however if I were to start my project based on such a thing, then I would be precluding myself from all of the advancements made on the main version.

However, typing this up has made me wonder if PCem can handle multi disc games via command line or some form of automation, or if the user has to use the menu to load a second disc manually.
Regarding using multiple media for one game could be done by mounting a Hard Disk with all the media inside and using a Daemon Tools like in guest. Loading always in the Start Menu a BAT in root of the E: drive, for example, with the CD and the installed game. The media and the installation folder of the game should be always in E:. But I'm not sure if a shortcut for changing CDs like the one in DOSBox could be possible.

About the child/incremental images could be a very nice feature. In SVN DOSBox, there's the option of ZIP mount that combines the contents of a folder with the ZIP itself, but I don't think that, if possible, would be easy to add to PCem.

eXo
Posts: 5
Joined: Thu 30 Jul, 2015 6:27 pm

Re: PCem requests for a Win9x Project

Post by eXo » Tue 08 Jan, 2019 8:01 pm

For my project to maintain its current build standards, it has to be portable. Which means not relying on third party software that requires a manual install (eg: daemon tools). DOSBox handles this by taking all mountable images up front, and then switching through them via a hotkey (ctrl-f4). It would be neat if PCem could be pointed to either a single image or a series of images, with a series being handled by a hotkey as well. However, that is a fairly bluesky wish.

I'm glad to see others would appreciate the parent\child image feature =)

shermanp
Posts: 111
Joined: Sat 18 Feb, 2017 2:09 am

Re: PCem requests for a Win9x Project

Post by shermanp » Tue 08 Jan, 2019 8:01 pm

Hi,

As stated, I have have been creating VHD support for PCem. I think I have dynamic images pretty well sorted, and I'm currently trying to get differencing support working (reading works, but I haven't got creation support yet, nor any of the parent/child integrity checks).

The original VHD format is very simple, and is probably not the most suitable format for differencing images, as there is no robust mechanism for checking if the parent image has been written to/modified since the relationship was created. The specification uses the file modified date property (yes, really), and some software (*cough* Windows 10 *cough*) doesn't even bother to set this date field in the child image.

If I get differencing VHD support into PCem, I will probably look at setting the parent image "read-only" (or the linux equivalent) when a child image is created, but short of verifying the parent by doing some checksum verifications (which could take a long time for a large image), I'm not sure if there's a lot else that can be done.

VHDX, or maybe qcow2, would be more robust image formats, but they're too complicated for my poor little noggin at this time :p

Here is the thread where we've been discussing VHD support => http://pcem-emulator.co.uk/phpBB3/viewt ... ?f=2&t=178

terub56
Posts: 21
Joined: Mon 23 Jan, 2017 12:31 pm

Re: PCem requests for a Win9x Project

Post by terub56 » Tue 08 Jan, 2019 8:09 pm

eXo wrote:
Tue 08 Jan, 2019 8:01 pm
For my project to maintain its current build standards, it has to be portable. Which means not relying on third party software that requires a manual install (eg: daemon tools). DOSBox handles this by taking all mountable images up front, and then switching through them via a hotkey (ctrl-f4). It would be neat if PCem could be pointed to either a single image or a series of images, with a series being handled by a hotkey as well. However, that is a fairly bluesky wish.

I'm glad to see others would appreciate the parent\child image feature =)
Sure, I was referring to install Daemon Tools in the guest, Windows 98. I think in older versions you could mount an image by command line. But if you don't want to use Virtual CD-ROM software, I think it's not possible in PCem load multiple CDs in the same drive. Sarah (or anyone) should implement it.

eXo
Posts: 5
Joined: Thu 30 Jul, 2015 6:27 pm

Re: PCem requests for a Win9x Project

Post by eXo » Tue 08 Jan, 2019 8:18 pm

Ah, that makes sense. However the drawback here is the CD images are now inside a hard disk file. So from a preservation standpoint, they are not easily accessible anymore. That is probably a nitpick, but my project serves to both provide the original media as well as a way to use the media. I try not to do things on either side that make the other difficult.

Post Reply