Bug 65039

Summary: "change" sets wrong partition type & cant rebuild lilo from SRPM
Product: [Retired] Red Hat Linux Reporter: joel
Component: liloAssignee: Peter Jones <pjones>
Status: CLOSED WONTFIX QA Contact: Brock Organ <borgan>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.3   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-04-19 18:27:13 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description joel 2002-05-16 14:08:05 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0rc1) Gecko/20020417

Description of problem:
the Lilo change command sets the partition type to small dos 16 bit when big dos
16 bit is requested. I know how to fix this, but I am unable to build a working
lilo from the SRPM on RH 7.3

Version-Release number of selected component (if applicable):
lilo-21.4.4-14

How reproducible:
Always

Steps to Reproduce:
1. add an os stanza to lilo.conf and use the change command to change partition
types
2. lilo -v
3. try to boot the os just added

Example:
other = /dev/sda1
  label = NT
  change
    partition = /dev/sda1
      set = dos16_big_normal
      activate
    partition = /dev/sda2
      deactivate
      set = DOS16_big_hidden


Actual Results:  Booting the new os fails. Booting up Linux and using fdisk to
examine the partition type reveals that is has been set wrong, dos 16bit small
rather than dos 16bit large.

Expected Results:  The partition type should be set as requested and the OS
should boot.

Additional info:

This part of partition.c is wrong:

void preload_types(void)
{
    add_type("DOS12",PART_DOS12,PART_HDOS12);
    add_type("DOS16_small",PART_DOS16_SMALL,PART_HDOS16_SMALL);
    add_type("DOS16_big",PART_DOS16_BIG,PART_HDOS16_SMALL);

The last line should read:

    add_type("DOS16_big",PART_DOS16_BIG,PART_HDOS16_BIG);

When I tried to fix this and rebuild lilo, the lilo generated does not work --
it fails to boot linux with error "setup signature not found". While
troubleshooting this I found that simply rebuilding an unmodified lilo SRPM into
a binary RPM and installing it fails to generate a working lilo. I suspect there
is a problem with the header (include) files as the system kernel is 21.4.4 but
the header files installed by RH 7.3 are from 2.4-7.14

Comment 1 Jeremy Katz 2002-06-04 19:23:11 UTC
Reassigning

Comment 2 Peter Jones 2005-04-19 18:27:13 UTC
This needs to be fixed in the upstream lilo sources.