QEMU/Guests/Windows NT 3.x-4.0 (MIPS): Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
'''Windows NT 4''', along with Windows NT 3.51 and 3.5, can successfully run and install in QEMU's MIPS emulation. Windows NT 3.1 BSODs on setup, so it is not installable. Service Pack 1 was the last supported service pack on MIPS Windows NT 4. Currently, the PowerPC and Alpha ports of Windows NT 3.x & 4 do not run, though there is a currently active project to run PowerPC NT 4 on QEMU.
 
While these instructions are for NT 4, they will also work the same for NT 3.51 and NT 3.5.
 
==Notes==
First, download the following file and extract it somewhere: http://web.archive.org/web/20150809205748if_/http://hpoussineau.free.fr/qemu/firmware/magnum-4000/setup.zip
 
One of the files will be called <code>NTPROM.RAW</code>. Rename this to <code>mipsel_bios.bin</code>.
 
Now we're going to makeOpen a hardcommand drive.prompt Theand maximumrun sizethe youfollowing cancommand make it is 2 gigabytes, so weto create the disk like thisimage:
 
<pre>qemu-img create -f qcow2 ntmips.img 2G</pre>
 
The Magnum machine doesn't support more than 2 GB of space, so don't go over this.
Next, we start QEMU with the following arguments. Take note to not set the memory above 128 or 64 MB, because the Magnum machine can't run more than 128 MB of RAM.
 
Next, start QEMU with the following command:
 
<pre>qemu-system-mips64el -hda ntmips.img -M magnum -nic user,model=dp83932 -cdrom win_nt_4_iso.iso -m 128 -global ds1225y.filename=nvram -global ds1225y.size=8200</pre>
 
We set the memory to 128 MB of RAM since this is the most supported by the Magnum machine. Only <code>128</code> and <code>64</code> are valid values (it won't boot with any others).
A break down of this command: <code>qemu-system-mips64el</code> is the name of the QEMU emulator, obviously. <code>-hda ntmips.img</code> tells the emulator to use the hard drive we just created. <code>-M magnum</code> tells QEMU to emulate the Magnum machine. There are multiple MIPS machines emulated by QEMU, you can type <code>-M ?</code> for a full list. <code>-nic user,model=dp83932</code> adds a virtual NIC (in this case, the 10 mb/s SONIC DP83932 network NIC). If you don't want internet you can remove this flag. <code>-cdrom win_nt_4_iso.iso</code> inserts a Windows NT 4 into the emulated cd-rom. If you have a physical copy of NT 4 you could change it to i.e. <code>-cdrom /dev/sr0</code>. <code>-m 128</code> sets the memory, in this case, 128 MB. And finally, <code>-global ds1225y.filename=nvram -global ds1225y.size=8200</code> adds a persistent nvram which is vital for saving the system state.
 
Now that all that's done, let's get the OS installed.
 
==Installation==
When you start the machine a problem you'll likely notice is that the date is set to the year 2033. The clock also might be set to "8:85:00", or something similar. This is a bug in the emulation that can be easily fixed. There are two ways to fix it - the first is to add something like <code>-rtc "base=1995-07-08T11:12:13,clock=vm"</code> to the QEMU command line. The second is to go to "Initialize system", "Set time", and set the proper date. An important note: If you don't properly set the clock, Windows NT will claim the date is invalid and set it to January 1, 1601 at 12:00 AM.
 
This is a "bug" in the emulation that can be really easily fixed. There are two ways to fix it. The first is to add something like <code>-rtc "base=1995-07-08T11:12:13,clock=vm"</code> to the QEMU command line. The second is to go to "Initialize system", "Set time", and then set the proper date. An important note: If you don't properly set the clock, Windows NT will set the date to January 1, 1601 at 12:00 AM.
 
Now we'll set the environment variables. Choose the following variables:

Navigation menu