I am using Windows Virtual PC on a Windows 7 machine. I have created an MS-DOS 6.22 virtual machine with 16 MB RAM and a 2 GB hard disk. Whenever I minimize or otherwise deactivate the window, and then restore or reactivate it, I get an error message, the PC speaker beeps for a second, and the virtual machine completely stops working until I forcefully reboot it:
Internal stack overflow System halted
(Interestingly, the problem does not occur when I am running Windows 3.1, which runs on top of MS-DOS. I get the error immediately when I try to exit to MS-DOS from Windows.)
I also got a similar error when I tried to install Windows 9x-based operating systems during the first (text-based) phase of installation and performing the same actions, and when attempting to boot such an OS (in this case, Windows 98) into real-mode MS-DOS mode (though in that case I get the error immediately and do not have to perform the actions above to get it):
An internal stack overflow has caused this session to be halted. Check the STACKS setting in your CONFIG.SYS file, and then try again.
Why does this error occur, and is there any way to fix it?