Linux+WindowsNT mini-HOWTO

Miroslav "Misko" Skoric, m.skoric@eunet.yu

v2.11, 2002-05-04

This mini-HOWTO covers some ways on how to install both Linux and Windows NT on the same computer and how to boot either of them from within LILO menu. There is also another mini-HOWTO "Linux+NT-Loader" that covers how to boot either of them from within NT Loader menu. As I consider Windows 2000 to be NT 5.0 this mini-HOWTO also covers upgrading from NT 4.0 to 2000.










Bill Wohler wrote in his v1.1 of The Linux+WindowsNT mini-HOWTO:

"Due to hardware or software problems or user headroom, I pulled my hair out for several days trying to get both NT and Linux happily settled on my new HP Vectra PC at work."

I could say that was true in my case too, but you really have a way to make both Linux and Windows NT co-existing on the same machine and to switch from one of them to another.

"Under no circumstances run the Disk Administrator from NT 3.51 to format partitions. It asks if it can write a signature "which will cause absolutely no harm." When it did this, it hosed my partition table until fixed by steps 3 and 7 below. Because of these problems, I was limited to one FAT NT partition. Also remember that even if you do get the Disk Administrator to work, you'll want at least one small FAT partition to use as a staging area for exchanging files between Linux and NT until Linux has an NTFS filesystem."

Well, NT's Disk Administrator is sufficient tool to check what situation on your hard disk(s) you have, before and after you used an utility called Partition Magic by Power Quest. This utility might be needed to 'shrink' your NT (either NTFS or FAT) partition, in order to get some free space for your further Linux' partitions. (After a while, I recognized that 'shrinking' used partition might not be needed. Actually, if you start from 'scratch', it might be the best way to re-format your whole disk(s) using FDISK command. You should make a DOS boot floppy diskete where DOS commands FDISK and FORMAT have to be also copied. More details later...)

"I installed Linux first and then NT, but based on my experience, I might now be able to install NT first and then Linux."

Of course you all are able to install Windows NT first and after that Linux. We'll see how to do that and how to use LILO (Linux Loader) to chose which operating system to boot. But, before that we'll see the procedure that Bill Wohler, the previous maintainer of this mini-HOWTO, has been using:


1. Install a minimal Linux (hold off on installing the rest until you win the Linux/NT battle). Do all your disk partitioning in Linux, including your NT partition (make it FAT). I was not successful at making more than one NT partition. I also made it the first partition, but I don't know if that is essential or not.

2. Edit /etc/lilo.conf and use boot=/dev/sda (I was not successful at installing LILO on the Linux partition--/dev/sda3 in my case) and run "lilo". You'll have to use the editor ae. You'll live.

3. Save the MBR with this: dd if=/dev/sda of=/dev/fd0 bs=512 count=1 Use a floppy. Trust me. Also do this each time you change the disk partition table.

4. Install NT, part 1. When it goes to reboot halfway through the process you'll boot into Linux.

5. Add NT stanza to /etc/lilo.conf, e.g.:


and run lilo. If lilo complains about this (I forget the message), add the "linear" flag to /etc/lilo.conf near the "compact" keyword. Furthermore, if your partition table is screwed up by NT you'll either need to use "ignore-table" or follow the directions in Step 7. See also "fix-table". The LILO HOWTO is your friend.

6. Reboot, select NT from LILO, and finish NT install. You'll need the "Boot Disk XU, HP Vectra AIC 7880 Driver A.01.02" floppy to install the ethernet drivers and the "XU/VT Drivers and Documentation" CD (directory video/disk4 if I recall correctly) to install the video drivers for the Matrox MGA Millennium.

7. Back to Linux, run fdisk and ensure you don't get "partition doesn't end on cylinder boundary" on your Linux partitions. You'll still have this error on the NT partition though, but this seems to be OK.

/dev/sda1            1        1      322   329301    6  DOS 16-bit >=32M

Partition 1 does not end on cylinder boundary:

phys=(321, 39, 9) should be (321, 63, 32)

Cfdisk reports strangeness, but it seems OK:

                                          Unusable                      0.04*

 /dev/sda1                 Primary        DOS 16-bit >=32Mb           321.59*

                                          Unusable                      0.39*

If you do get the cylinder boundary warning on your Linux partitions, it is sufficient to use cfdisk to do something innocuous like changing the boot sector.

If, however, NT has really screwed you over and cfdisk can't even run, complaining that it cannot open /dev/sda, then you'll need to take more extreme action. You'll need that MBR you saved previously. Clear and restore the MBR (but not the signature) with:

          dd if=/dev/zero of=/dev/sda bs=512 count=1

          dd if=/dev/fd0 of=/dev/sda bs=510 count=1

8. Install the rest of Linux. Easy, huh?

If you prefer to have NT write the MBR instead of LILO, you may have to resort to the following to clear the MBR first:

Epilogue: After first posting this message, I heard from several folks that they had no problems with NT's Disk Administrator, and were able to install either NT or Linux first without any problems. Hopefully, you'll be in this camp, but if not, perhaps this campfire story will be of some use.

Since the first edition of this mini-HOWTO, others have written similar documents as well. Please be sure to consult them. If your experience differs from any presented, then you should submit your own mini-HOWTO or submit a revised version of this document to the HOWTO maintainer (reference this sentence) and send a carbon copy to me as I don't have the time to maintain this document. Someone should eventually combine all of these documents into a single coherent HOWTO.

Finally, I'm afraid this document details all I know about this subject. I should point you to an appropriate Linux newsgroup for further information. I use NT about one day a year. Under duress.


3.1 If you have only one IDE hard disk

3.2 If you have more than one (SCSI) hard disk

Notice: Folks, you see, at my place, one of computers has several SCSI disks. That's why I put the word 'SCSI' in parentheses. There I have several SCSI controllers, SCSI CD ROM drive and SCSI Tape drive. So, it doesn't mean that *you* will be using SCSI parts at all. You'd rather handle more than one IDE disks, but I hope that install process shouldn't change too much, if any.


Well, actually, it isn't a real "upgrade" of running NT to 2000, but a "fresh" installation of Windows 2000 Professional. I hope it should also work for other Windows 2000 products. I haven't tried its server-type installations yet, but I remember I haven't experienced any problem with NT, regarding it was Server or Workstation.


Notice: When I say 'beside Linux and Windows 98', I mean of Linux and Windows 98 that already work together, so they were installed earlier, before we made a decission to add Windows 2000. One of the machines I use at work, has both Linux and Win98. They both load from under LILO menu.

Actually, it is not a very big problem to install Windows 2000 on a computer where another Windows is running. In my case, it is Windows 98 so I just put 2000's CD into the drive. After it recognized that an 'older' version of Windows was running on my machine, it offered me either to upgrade it to 2000 or to install W2k as the 'clean' installation. At first, I tried to upgrade my Windows 98 to W2k, in order to get a very similar combination that I have at home (described in previous chapter). But, some hardware and software compatibility issues were reported (I mean, some of my components wouldn't stay fully operational if I just did an upgrade).

When saw that, I considered to try the 'fresh' installation of W2k, beside Win98 and Linux. Happily, I recently installed another HD into the box, so I did not need to handle the first disk, where Win98 and Linux were living. Actually, the main reason to add the second disk was that the first one got almost full. If I wanted to install the third operating system on the first disk, I'd have to clean it well. So, when W2k's Setup asked for the location to be installed, I told it to use the second disk, repartition it and format it as the NTFS file system (just to mention that my Win98 was FAT32 and Linux was ext2).

After an hour or so, W2k's installation was finished. During the setup procedure, it re-started the system a couple of times. When it was about to do that for the first time, I was curious if it would re-write the MBR, where LILO resides (actually, in the previous chapter, I have mentioned that W2k's installation was likely to re-write the MBR). Interestingly, it did not do that this time, so I continued to see 'LILO boot:' on the screen. But, a *new* thing has appeared after LILO: the Windows 2000 boot loader, that in turn offered not only to load W2k but a 'Windows' (ie. my old Win98) too.

Well, depending on which operating system I like to start, the procedure might slightly differ, but it is easy. No problem at all. For example:


6.1 If you want to have *both* NT and 2000, beside Linux

Notice: Recently my bosses decided to get a couple of HP Omnibook 6000 portables, so I quickly rushed to play with new toys. It was a series with Pentium 3 at 1 GHz and 128 MB of RAM. There's also a hard disk of 30 GB, removable DVD and FDD drives, a secondary battery that goes to the removable drive bay (when it's empty) and NIC/modem combo card.

6.2 If you want to have only Windows 2000 and Linux

Notice: Well, all I have said in the previous section, resulted in a "multiboot" (or, better to say, "3-boot") system. When I want to run Linux - I have to choose its option from within LILO menu. When I am about to run any kind of Windoze - I have to choose Windows (or DOS, or whatever else) from within LILO menu. Soon after, on the screen appears Windows 2000 boot loader. Finally, from this point, either NT or 2000 may be booted. Well, for a next task, I wanted to install Symantec's Norton System Works onto both Microsoft environments. I did it successfully, but it seems that I have later entered a command that resulted in changing something very important in the setup. In sum, I have become not able to run both flavours of Windows properly. Looks that it was the right time to re-install all stuff :-)


7.1 Copyright

Copyright (c) 2002 by Miroslav "Misko" Skoric.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, with no Front-Cover Texts, and with no Back-Cover Texts. A copy of the license is available from

7.2 Disclaimer

Use the information in this document at your own risk. I disavow any potential liability for the contents of this document. Use of the concepts, examples, and/or other content of this document is entirely at your own risk.

All copyrights are owned by their owners, unless specifically noted otherwise. Use of a term in this document should not be regarded as affecting the validity of any trademark or service mark.

Naming of particular products or brands should not be seen as endorsements.

You are strongly recommended to take a backup of your system before major installation and backups at regular intervals.

7.3 News

This is not the first release of this mini-HOWTO. I hope to improve it whenever possible. Beside that, there are other documents that may help you to install more than one operating system on the same computer. You may look for them at the same location where you get Linux+WindowsNT mini-HOWTO.

This mini-HOWTO would be improved from time to time. If you think that the HOWTO on your Linux installation CD is some out-of-date, you may check for newest release on the Internet. It could be found within the main Linux Documentation Project homepage.

7.4 Credits

This version of Linux+WinNT mini-HOWTO is based on:

The Linux+WindowsNT mini-HOWTO
by Bill Wohler,
v1.1, 19 February 1997

Any comments or suggestions can be mailed to my email address: m.skoric@eunet.yu.


These are intended as the primary starting points to get the background information as well as show you how to solve a specific problem. Some relevant HOWTOs are Bootdisk, Installation, SCSI and UMSDOS. The main site for these is the LDP archive at Metalab (formerly known as Sunsite).

7.6 Mini-HOWTO

These are the smaller free text relatives to the HOWTOs. Some relevant mini-HOWTOs are Backup-With-MSDOS, Diskless, LILO, Large Disk, Linux+DOS+Win95+OS2, Linux+OS2+DOS, Linux+Win95, Linux+WindowsNT, Linux+NT-Loader, NFS-Root, Win95+Win+Linux, ZIP Drive, FBB packet-radio BBS. You can find these at the same place as the HOWTOs, usually in a sub directory called mini. Note that these are scheduled to be converted into SGML and become proper HOWTOs in the near future.

7.7 Local Resources

In most distributions of Linux there is a document directory installed, have a look in the /usr/doc directory. where most packages store their main documentation and README files etc. Also you will here find the HOWTO archive ( /usr/doc/HOWTO) of ready formatted HOWTOs and also the mini-HOWTO archive ( /usr/doc/HOWTO/mini) of plain text documents.

Many of the configuration files mentioned earlier can be found in the /etc directory. In particular you will want to work with the /etc/fstab file that sets up the mounting of partitions and possibly also /etc/mdtab file that is used for the md system to set up RAID.

The kernel source in /usr/src/linux is, of course, the ultimate documentation. In other words, use the source, Luke. It should also be pointed out that the kernel comes not only with source code which is even commented (well, partially at least) but also an informative documentation directory. If you are about to ask any questions about the kernel you should read this first, it will save you and many others a lot of time and possibly embarrassment.

Also have a look in your system log file ( /var/log/messages) to see what is going on and in particular how the booting went if too much scrolled off your screen. Using tail -f /var/log/messages in a separate window or screen will give you a continuous update of what is going on in your system.

You can also take advantage of the /proc file system that is a window into the inner workings of your system. Use cat rather than more to view the files as they are reported as being zero length. Reports are that less works well here.

7.8 Web Pages

There is a huge number of informative web pages out there and by their very nature they change quickly so don't be too surprised if these links become quickly outdated.

A good starting point is of course the Linux Documentation Project home page, an information central for documentation, project pages and much, much more.

Please let me know if you have any other leads that can be of interest.


In the end you might find yourself unable to solve your problems and need help from someone else. The most efficient way is either to ask someone local or in your nearest Linux user group, search the web for the nearest one.

Another possibility is to ask on Usenet News in one of the many, many newsgroups available. The problem is that these have such a high volume and noise (called low signal-to-noise ratio) that your question can easily fall through unanswered.

No matter where you ask it is important to ask well or you will not be taken seriously. Saying just my disk does not work is not going to help you and instead the noise level is increased even further and if you are lucky someone will ask you to clarify.

Instead describe your problems in some detail that will enable people to help you. The problem could lie somewhere you did not expect. Therefore you are advised to list up the following information on your system:




Remember that booting text is logged to /var/log/messages which can answer most of the questions above. Obviously if the drives fail you might not be able to get the log saved to disk but you can at least scroll back up the screen using the SHIFT and PAGE UP keys. It may also be useful to include part of this in your request for help but do not go overboard, keep it brief as a complete log file dumped to Usenet News is more than a little annoying.