Solved

Redhat 5.2 dual boot with NT 4.0

Posted on 1998-11-17
39
424 Views
Last Modified: 2013-12-15
it gets complicated.

I've got a system which had Win NT 4.0 SP 4 installed on it originally.  The NT system is installed on the first partition of an 18gb scsi disk..   in unix terms /dev/sda1
the partition is 2gb..  

I have successfully installed Redhat Linux 5.2 on /dev/sda3, kind of anyway..  ie. the system will boot successfully and be totally accessible, but only from a Linux floppy boot disk which is prepared during the setup phase..

LILO does not install correctly during that setup phase.. nor can I install LILO after the fact on either partition.. ie. not on the Linux root partition, nor in the Master Boot Record (which is owned by NT)..

I have modified the NT BootLoader as described in the mini-howto file on setting up dual boot NT/Linux systems but it still forces me to put in the boot floppy diskette in drive a to boot..

I've extracted the bootsect.lnx file form the floppy and moved it to my NT boot partition as well to no avail..  it spits out a string of "80 80 80 80" characters until I put the boot diskette in..  (my NT bootloader maps to C:\BOOTSECT.LNX for Linux..)

any clues on how to get LILO to work?? or load??

 
0
Comment
Question by:tfabian
  • 19
  • 5
  • 4
  • +8
39 Comments
 
LVL 2

Expert Comment

by:gothick
ID: 1631640
It sounds like you're on exactly the right track.  I have NT and Linux successfully dual-booting using NT's boot manager.  There's an article on this, giving exact steps on how to do it, in the SuSE Linux knowledge base at:

http://www.suse.de/Support/sdb_e/nt.html

although this is in the SuSE KB, it should work exactly the same for you.
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631641
gothick:

The pages you've referenced seem to describe everything I've already done.. I've printed them out and will study them in greater detail though, and try to repeat some of the examples they describe..  if any of them work, I'll post a followup comment here ask you to repost an "answer" for the points..

thanks for your efforts..
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631642
a general followup comment:

I don't need to know how to get the NTBOOTLOADER configured.. I've done that aleady.. my problem seems to stem from the fact that during the Linux install, the installation of LILO fails.. it gives an error message that's practically useless, and asks me if if I want to return to the previous step (building as boot diskette), go to the menu (it says it's not recommended to do so), or skip the step..

when I skip the step (the installation of LILO), it tells me the install process (of Linux) is complete..


when I try to install LILO from the command prompt, it spits out the various options I've setup, ie. NT and LINUX, then says "PARTITION NOT FOUND"



0
 

Expert Comment

by:screwdriver
ID: 1631643
here is what I did:
First I installed NT at /dev/hda1
Then I installed linux at /dev/hdb5 and I put LILO at /dev/hdb5
I boot linux using the disk by inserting the boot disk, rebooting my computer, and at prompt I typed:

linux single root=/dev/hdb5 initrd=

at shell prompt, I typed:

dd if=/dev/hdb5 of=/bootsect.lnx bs=512 count=1

This will create a file called bootsect.lnx at / directory

I mount my C: drive, using command: mount /dev/hda1 /mnt

I moved bootsect.lnx to /mnt directory, using command:
mv /bootsect.lnx /mnt

at your /mnt directory, edit file 'bootsect.lnx'. Add this line:
C:\bootsect.lnx="linux"

you may want to change the permission of boot.ini (set write permission)

umount /mnt
reboot -r now

That's all.
0
 
LVL 2

Expert Comment

by:gothick
ID: 1631644
Post your lilo.conf; I'll compare it against mine -- they should, after all, be pretty much identical.  (I've even got Linux in /dev/sda3!).
0
 
LVL 2

Expert Comment

by:vx
ID: 1631645
Perhaps you should try running "liloconfig". It should be a part of the LILO distribution, it isn't a specific RedHat setup program.
0
 
LVL 2

Expert Comment

by:cwalter
ID: 1631646
There are 2 ways I have used to correct the problem your having:
1. When your NT and want to boot to Linux then make part3 active and reboot then to get back make part1 active and reboot. Not automatic but it works.
2. Use Partition Magic to move your NT partition a little and create a 2mb partition at the beginning of the drive and install lilo or another boot manager there. I have found that the boot manager that comes with OS/2 is one of the best. Don't install OS/2 or anything just the boot manager if you have OS/2 laying around somewhere.
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631647
thanks cwalter, but...

I tried the first solution about making the other partition active and rebooting, but that fails with the error message "no operating system"..

regarding your second idea, instead of "Partition Magic", I used a shareware (?) package called "OS-BS" that one of my coworkers supplied.. it created another menu driven boot program in the MBR and let me put the NT Bootloader a few bytes further into the disk, and call it (and other boot programs up) with a key stroke.. so far so good.. but the end result was still the same.. while NT worked flawlessly under this scenerio, Linux still doesn't function properly..

it still locks up.. now it too returns with the "no operating system" message...

when I back that "fix out" and put the NT Bootloader program back into the MBR directly, the Linux load option displays

   L80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80 80

etc. etc. etc.

when I put the Linux boot floppy in the a drive, the display continues:

    80 80 80ILO

    ......


and boot normally..


more information in the next note / comment..

0
 
LVL 5

Author Comment

by:tfabian
ID: 1631648
vx:

I looked for "liloconfig", but it's not part of my system..

I did find "linuxconf" though, which has a section on configuring LILO..  when I attempted to use it,  it tries to install itself but terminates with a "return code 1"..  it's unable to find the "partition"...

thanks for your thoughts though..
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631649
screwdriver:

I've done that same basic thing several times.. nothing to show for it...  see my other recent comments to get full details of what I've been experimenting with..


thanks


0
 
LVL 5

Author Comment

by:tfabian
ID: 1631650
gothink:

I don't think posting lilo.conf would do much good at this point..

it's on a different machine on an isolated network than the one which I'm using to post/access this information,  and transfering it would be a pain in the neck.. and I'm certainly not going to retype it at this point.. but thanks for offerring to compare... if all else fails, I may take you up on the offer...



0
 
LVL 2

Expert Comment

by:gothick
ID: 1631651
Okey-dokey.  What does the Lilo manual say about the 80 80 80... error message?  I think it has a meaning, but unfortunately I'm on an NT system at the moment, so my manual isn't to hand.

Incidentally, I believe liloconfig is just a link to /sbin/lilo on some distributions (but this is from my dim recollections of slackware.  And I'd rather assumed that you'd been running /sbin/lilo ;-)

0
 
LVL 5

Author Comment

by:tfabian
ID: 1631652
more general comments:


I've been reading the Linux 5.2 installation book, and various help files within the "linuxconf" program menus..   a couple of things stood out in my mind that might be causing the problems..

again, the main problem is the inability to install LILO on/in the partition successfully.. the absense of LILO explains the "no operating system" messages, and the L80 80 80 80
stuff too.. when LILO is introduced into the mix (via the floppy), it continues the ILO completion on the screen and boots..  so obviously the inability to load LILO on the partition is the root problem..

in searching for information on this, I need to restate how the disk is setup..

the disk in the system is an 18 gb scsi drive..

  first 2gb partition contains the MBR and NT 4.0..  it defined to linux as /dev/sda1
  it's FAT16, drive C to NT

  second 2gb partition is also FAT16, and is drive D to NT.. don't know the linux definition
  offhand..  probably /dev/sda2

  third partition is NATIVE LINUX, /dev/sda3..  growable size to linux maximum remainder
  of disk..

  fourth partition is LINUX swap file..  /dev/sda4  recommended size by the linux setup
  program..  also growable...

  fifth partition makes up the remainder of the disk, roughly 9gb.. it NTFS formatted,
  linux sees it as HPFS   /dev/sda5   NT sees it as drive F


one of the documents I found states something like  (I'm paraphrasing from memory):

  LILO can reside in either the MBR or the first bytes of the Linux root partition, but
  if the Linux root partition isn't on a separate disk, the Linux partition needs to be active..

this seems to match the ideas put forth by cwalter...

another documents options to use instead of LILO.. I'm planning on exploring those next..





0
 
LVL 5

Author Comment

by:tfabian
ID: 1631653
gothink:

I haven't found the exact "80 80 80 80" error in the manual yet, or in any other documentation for that matter..

but, the L along (with scrolling numbers)  implies according to the manual, one of three things:

  1) /boot partition is beyond the 1023rd cylinder on the disk

  2) the kermnal, or part of it are beyond the 1023rd cylinder of the disk

  3) the kernal is on a scsi disk with an ID other than 0 or 1


my inclanation is that I'm probably beyond the 1023rd cylinder.. but I can't prove that..

back to the drawing board.. I think I'll try changing my jaz drives scsi ID to 1 and then install LINUX on it instead of on the main drive..  maybe that'll work...


catch you later..




0
 
LVL 2

Expert Comment

by:vx
ID: 1631654
I did some research on the 80 error:

0x80   "Disk timeout". The disk or the drive isn't ready. Either the
    media is bad or the disk isn't spinning. If you're booting from a
    floppy, you might not have closed the drive door. Otherwise, trying to
    boot again might help.

You're right RedHat doesn't include the liloconfig util; the official LILO distribution doesn't either, but it does include a QuickInstall script - perhaps that will work for you. You can get it at: ftp://sunsite.unc.edu/pub/Linux/system/boot/lilo/lilo-20.tar.gz
0
 
LVL 2

Expert Comment

by:gothick
ID: 1631655
This still sounds like a problem with your lilo.conf to me, but I suppose it could be some kind of weird BIOS thing.  Oh well.
0
 
LVL 2

Expert Comment

by:gothick
ID: 1631656
Incidentally, sorry for locking the question out -- I pressed "answer" instead of "comment" on that last one.
0
 
LVL 2

Expert Comment

by:vx
ID: 1631657
Did you try the QuickInstall script as I suggested before?
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631658
VX:

not yet.. I've been backlogged with other projects, Thanksgiving, and budget reviews..
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 51

Expert Comment

by:ahoffmann
ID: 1631659
puh, a lot of comments, hope I did read properly ..

Anyway, some of my knowledge about comments and your problem:

1) /dev/sda3  must be within the first 1024 cylinders
   (This is a limitation of LILO; I'm not shure now if the hole
    partition must match this restriction, or just the start of it,
    see  man lilo,  or howtos)
2) please post your lilo.conf
3) L80 80 80 ...
   usually results from a wrong map file, means that the map file
   generated by lilo doesn't match the information in lilo.conf
   found by the MBR
4) you still know how to save and restore the MBR using dd,
   I recomment using only 448 bytes instead of 512, 'cause the
   remaining bytes are the partition table

 continued (Q.10105102 ;-)
0
 

Expert Comment

by:Nemorino
ID: 1631660
The 1023rd cilynder limitation is pretty serious. That is why it is recommended that you install a small 50mb partition close to the beginning of the drive. In it you will map /boot. Yes, it is better if the whole /boot partition is inside this 'safe' area. If you place /boot borderline the limit you may not boot properly.
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631661
I'm sidetracked with a bunch of other things, but wanted to add a comment or two..

I tried reinstaling Linux on a different disk to see what would happen.. it failed, but that's not entirely suprising..

what I did find out was that my original Linux partition was within the 1023 cylindar boundry..   it was at 500 something..  so that discounts that cause/effect scenerio..


re: posting my LILO.CONF file..  that's harder than it sounds.. the machine I'm working with isn't on the same network, nor can I transfer the file easily without retyping,, and I really don't want to do that.. so until I can get a spare minute to figure out a transfer of a sort, I can't post it.. I don't think it has any relavant information in it anyway..

re: the map file information, I'll try to look into that when I find that spare minute above..


thanks guys..

the problems remains, LILO cannot be installed..  


0
 
LVL 5

Author Comment

by:tfabian
ID: 1631662
okay, after much manuvering, here's the LILO.CONF file



boot = /dev/sda3
timeout = 50
compact
linear
prompt
  default = linux
  vga = normal
  read-only
map=/boot/map
install=/boot/boot.b
image = /boot/vmlinuz-2.0.36-0.7
  label = linux
  initrd = /boot/initrd-2.0.36-0.7.img
  root = /dev/sda3
  read-write
other = /dev/sda1
  label = NT
  table=/dev/sda
other = /dev/sda5
  label = dos
  table=/dev/sda
other = /dev/sdb4
  label = dos
  table=/dev/sdb
  map-drive=0x80
  to =0x81
  map-drive=0x81
  to =0x80
other = /dev/sda1
  label = NT 4.0






I also looked for a /boot/map file, but can't find one..

what should be in it??



0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 1631663
> boot = /dev/sda3

install lilo on your 3'rd partition, not on MBR
This means that your bootmanager loaded by MBR (NT's OS loader in this case) must know how to call LILO (AFAIK, it cannot do that).

Change to    boot=/dev/sda   to install LILO on MBR.
I highly recommend to save the curren MBR as follows:

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

if something fails with lilo, you can then boot anyhow into linux and restore this MBR again.

I also would remove

  map=/boot/map

and let LILO use its default, unless you realy know what happens here (read man LILO and LILO howto).

Good luck.
0
 
LVL 3

Expert Comment

by:hnminh
ID: 1631664
Evaluate this thing:
 - Use some software allow you edit your MBR like diskedit of NU.
  1. Make a copy of your current MBR on another sector.
  2. Erase everything on your MBR.
  3. Copy only partition information of your harddisk back to MBR.
  4. Boot by RedHat installation CD and choose upgrade.
  5. At the end, the installation ask you where to install your LILO, choose Master Boot Partition.
  6. Declare a name for you NT system partion and... finish.
As my experince, LILO should boot your NT system up without any problems.
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631665
These are all things I have already tried..  for the time being, I'm rejecting the response, and I will try them again.. if it works this time, I'll be in touch via this forum..


thanks
0
 
LVL 1

Expert Comment

by:sxh
ID: 1631666
hi tfabian

Wow, a lot of suggestions on this thread.

If it's any use, I use system commander from v-communications.

This lets me run multiple operating systems from one disk via partitions. currently i have win95, win nt 4.0 and linux redhat 5.1 all running from different partitions on an 8.4 Gb WD drive.

It gives me a nice little menu at boot to select the operating system I would like and provides multi-user boot logins.

It also recognises and allows installation of OS/2, BDS, SCO unix etc etc.


I had similar problems to you and waisted a lot of time 'messing around', although educational it was not practical.

System commander answered all my problems, and NO i don't work for them or sell their their product.

regards

sxh
0
 

Expert Comment

by:jji
ID: 1631667
 You have 2 entries for dos in 'lilo.conf'. Is that really OK?
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631668
to JJI

I don't know.. that's the lilo.conf that got generated automatically by the installation.. I haven't editted it.. changed it.. or any way modified it...



to other interested parties.. here's an update..

I tried to use a completely different machine, different hard drive, different IP address, etc. etc. and duplicate the problem, and I was successful at duplicating it..

thus I've concluded that my only possible action now is to try moving the partitions around on the drive, or wiping them out and recreating them (and the installed software) from ground zero..  

at present, I am working toward finding a shareware package called FIPS which I'm told will non-destructively move partitions around on disk.. if that proves true, I'll try to move the Linux related partitions to the first part of the drive, and to move the NT portions to the last part of the drive..

assuming that works, I'll let you folks know..


thanks for the ideas, and hanging in with me..



 
0
 

Expert Comment

by:jji
ID: 1631669
Somehow my comment got lost...

  Try to remove the other 'dos' entry or change it's label to 'dos1'   and run lilo. The install script is broken if it let you to define duplicate labels.
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631670
jji,

changing the labels in lilo.conf had no effect.. the problem still exists..


thanks for trying..
0
 

Expert Comment

by:jji
ID: 1631671
 And you didn't forget the magic words 'dd if=/dev/sda3 of=/yourntpartition/bootsect.lnx bs=512 (or 448 as ahoffmann suggested) count=1'? (that have to be done everytime you run lilo). What does 'df' say? Are Linux and NT the only OS's in your system? If so you only need 2 entries in lilo.conf. (I really doubt that you have 2 different dos's there...) Maybe you should start with only 2 entries in lilo.conf, 1 for NT and 1 for Linux.
0
 
LVL 2

Expert Comment

by:vx
ID: 1631672
As I reread the question, I saw that you copied the MBR from the bootdisk. That can't be right; you should install LILO to the linux partition and then copy the bootsector from your linux partition to C:\

I'm sorry I'm turning back to basic here, but I'm not sure if you did this right.
0
 
LVL 5

Author Comment

by:tfabian
ID: 1631673
I tried the sequence of commands again, with the dd stuff, and it still fails..

next step, upgrade the kernal and see if  the problem goes away... stay tuned..


0
 
LVL 5

Author Comment

by:tfabian
ID: 1631674
I don't have a lot of time to go through everything now, but I wanted to let you all know that I solved the problem, I just don't know how I solved the problem..

in brief, I tried to upgrade the Linux kernel on the machine, but that failed and the system became unbootable, at least from a Linux standpoint..

my next effort invovled trying to move NT from one partition on the disk to another without physically reinstalling it.. again, that failed..

finally in desperation, I wiped out the entire machine.. every partition on the 18gb disk..

I recreated a 50mb partition at the front end of the disk, then made a bunch of 2 gb partitions after it while reloading NT..  after getting NT up and running in the 4th 2gb partition, I trashed the first two..  so my disk appeared as

   50mb  drive c
   4 gb  undefined
   2 gb  drive d
   2 gb  drive e  <-- with NT on it
   2 gb  drive f
   6 gb  undefined

or close to it..

I then installed Linux.. the only difference was I used a cd rom (instead of an FTP site) to do the install..

Linux ended up in the first 4 gb undefined area in a Native Linux partition..  LILO installed fine.. and it boots correctly from the NT Loader Boot.ini menu..

I did manage to trash NTOSKRL.EXE somehow though, and NT wouldn't load, but that's another story..


anyway, thanks for your ideas, thoughts, etc.   I'm still trying to sort out things..  eventually when things settle down, I'll try to get the EE folks to split the points between everyone who provided an idea / comment to this point..  I'll try to give them some breakout of how it should be divided..  so stay tuned..


 thanks..



0
 
LVL 5

Author Comment

by:tfabian
ID: 1631675
wow.. I fixed the NT problem too.. partition number in the boot.ini file..


anyway, here's the folks I'm going to list for the point split..


   gothink
   screwdriver
   vx
   cwalter
   ahoffmann
   nemorino
   hnminh
   sxh
   jji

I increased the points to 180, so a nine way split should be 20 points each at an "A" grade..  

lets see how long it takes for the admin folks to do it..



0
 
LVL 7

Accepted Solution

by:
linda101698 earned 180 total points
ID: 1631676
I'm going to post an answer to this question so it can be saved in the PAQ.  Then I'm going to add points to tfabian's account so he can post questions for the experts who he wants to receive points.  Watch for the question in this topic area.

Thanks for participating.

Linda Gardner
Customer Service @ Experts Exchange

0
 
LVL 5

Author Comment

by:tfabian
ID: 1631677
Thanks for handling the point split.. or at least for explaining how to do it..

0
 
LVL 5

Author Comment

by:tfabian
ID: 1631678
Epilogue:

I tried the process on the second machine, but without reformating the drive and without removing NT..  and LILO again installed correctly..


the differences that I can figure out were that I was loading from an FTP site when LILO failed to load properly,  in all cases, and from the local CD ROM when it work properly...


there appears to be a difference...



0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now