Jump to content











Photo
- - - - -

How to boot Win9x from logical?


  • Please log in to reply
13 replies to this topic

#1 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 09 August 2011 - 02:48 AM

Hello.

I would like to attempt to boot Windows 98 from a logical partition, but I'm unsure about how to do it properly using Grub4dos's 'partnew' command.

Does this command temporarily map logical partitions to primaries, or is it permanent?

I've read that you'll need an 'empty' boot sector for this. How do I ensure I have one? My multi-booting procedures have been pretty sloppy in the past...

My current dilemma is that I've installed Windows 98 to my third, and final, primary partition. I then transferred all of these files, with attributes intact, to the first logical partition located in my extended hard drive space. I'd like to boot this Windows 98, without the need for having the boot files contained on another fatn partition.

Finally, I don't learn well with just having a bunch of reading material thrown at me. I'm actually able to use, apply, and retain information if it applies directly to the action I'm attempting. Thank you for any help you may be able to offer.

#2 wendy

wendy

    Frequent Member

  • Lady
  • 266 posts
  • Location:one mile from the QR main line
  • Interests:Operating systems, Weights and Measures, Geometry
  •  
    Australia

Posted 09 August 2011 - 07:47 AM

Windows 98 must be booted from a primary partition. You can install it on a logical partition, that is, run setup and point this at drive d: or something, and you can install it on a partition on the second drive, but the boot loader (io.sys, msdos.sys and a few others), needs to be on the active partition of the first disk.

#3 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13748 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 09 August 2011 - 11:14 AM

Virii
you have some confused info on the partnew command.
READ (attentively) the

******************************************************************************
*** About the new map option --in-situ ***
******************************************************************************

--in-situ is used with hard drive images or hardrive partitions. With an
in-situ map, we can typically use a logical partition as a primary partition.

In-situ map is a whole drive map. It only virtualize the partition table and
the number of hidden sectors in the BPB of the DOS Boot Record.

While disk emulation may encounter various problems with win9x, the in-situ map
works fine with win9x.

Note that --in-situ will not change the real partition table.

Example:

map --in-situ (hd0,4)+1 (hd0)


******************************************************************************
*** The PARTNEW Command Syntax ***
******************************************************************************

Besides the mappings in the above section, you may instead choose to create a
new primary partition with the PARTNEW command. PARTNEW can generate a primary
partition entry (in the partition table) for a logical partition.

For example,

partnew (hd0,3) 0x07 (hd0,4)+1

where the file (hd0,4)+1 stands for the whole partition (hd0,4). This command
will create a new primary partition (hd0,3) whose type is 0x07 and whose
contents/data is the same as that of the logical partition (hd0,4).

Just like a whole logical partition, a contiguous partition image file can
also be used with PARTNEW:

partnew (hd0,3) 0x00 (hd0,0)/my_partition.img

The type 0x00 indicates a type-auto-detection of the image MY_PARTITION.IMG.
The above command will create a new primary partition (hd0,3) with a proper
type and with contents/data being exactly that of the contiguous file
(hd0,0)/my_partition.img.

PARTNEW will automatically correct the "hidden sectors" in the BPB and the
modification will be permanent. And PARTNEW modifies the partition table
permanently.

In addition to creating new partition entries, PARTNEW can also be used to
delete(erase, or wipe) a primary partition entry. For example,

partnew (hd0,3) 0 0 0

which will empty the last entry in the partition table in MBR. Generally,
you should use the form of "partnew PARTITION 0 0 0" to erase the entry.
Note that only the entry would be erased, and the data stored in the partition
will not be touched.


So:
  • partnew changes are PERMANENT
  • to boot a Windows 9x, try using the map --in-situ approach

For the record you don't need and "empty bootsector" to use the partnew command, you need an empty "partition entry in the MBR".

@Wendy
Not really-really, in the sense that what you posted is a DOS requirement but grub4dos can trick - see above - DOS to think it is actually on a Primary. :whistling:

Just for the record you CANNOT nomally install Win9x on a logical volume (SU 013 Error), you will need a couple of tricks as well, old approach:
http://www.allensmit...XOSL/II.htm#II1

:smiling9:
Wonko

#4 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 09 August 2011 - 01:00 PM

Okay then. The partnew command can be used to create, and delete (aka emptying an partition entry in the MBR), primary partitions among other things. Thank you for the clarification.

I had previously tried to map the logical drive, without success. I received some type of "int13" error when I went to 'map --hook'.

After trying the '--in-situ' command, I received the following error, or something similar.

Error 64 cannot use --in-situ command


I already have 3 primaries, and the 1 extended partition. Will this not allow the command to work?

#5 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13748 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 09 August 2011 - 01:22 PM

After trying the '--in-situ' command, I received the following error, or something similar.

Why it is so difficult? :) EVERYTIME!
I have NO crystal ball, (the one I used to have got lost and however it was always out of tune), I have not ESP powers, HOW the heck do you think I can reply with NO or oartial info? ;)

WHICH EXACT grub4dos version are you using?
HOW big is the hard disk and the partitions?

Besides an answer to the above questions, post the output of the grub4dos geometry command for the hard disk and the output of the root command for each of the partitions in it.
AMD POST THE EXACT set of commands you attempted issuing AND THE EXACT errors you got.

This is NORMAL, it is COMMON SENSE, it is asked in order to try and help you with your problem :):
http://homepages.tes...ard-litany.html

A problem report that doesn't answer all of these questions is incomplete, and contains insufficient information for diagnosis and prescription of a remedy. If you don't supply this information right at the start, you'll waste yours and others' time, and delay the actual remedy to your problem, by forcing everyone to spend one or more rounds of communication back and forth simply trying to wring the relevant information out of you.

The questions in the standard litany can be paraphrased when it comes to the use of computers:

What did you do ? What actual commands or tests did you run ? Where precisely did you run them ? What was your exact configuration ?

What did the computer actually do ? What were the exact test results, complete log contents, and exact error messages that were issued ?

What did you expect the computer to do ? What did you expect the computer to do instead ? What were you aiming to achieve and what makes you think that you aren't actually achieving it ?

Note the words "actual", "exact", "complete", and "precisely". Problem reports that are vague or superficial are worthless. ("I'm ill, doctor. Help!")


B)
Wonko

#6 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 09 August 2011 - 02:36 PM

Sorry, I thought the generic error code would be something simple. But, by the time I booted, connected to the net, logged in here, and start typing, I forgot most of it...

The full error, which I had to write down by hand was the following:
Error 64: Cannot use --in-situ because the partition tale is full(i.e., all the 4 entries are in use).



Press any Key to continue...

My menu.lst entry was this:

title Windows 98 SE

find --set-root --ignore-floppies --ignore-cd /winxp.tag

hide ()

find --set-root --ignore-floppies --ignore-cd /win98.tag

map --in-situ ()+1 (hd0)

find --set-root --ignore-floppies --ignore-cd /win98.tag

chainloader ()/io.sys

Geometry (per grub4dos):
drive 0x80(LBA): C/H/S=1024/255/63, Sector Count/Size=1953523712/512

My partition info is (per bootice):
Partition 0, Filesystem NTFS, Partition type 07

Partition 1, Filesystem Ext4, Partition type 83

Partition 2, Filesystem Fat32 (Active), Partition type 0C

Partition 4, Filesystem Fat32, Partition type 0B

Again apologies, and I hope this info is sufficient?

#7 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13748 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 09 August 2011 - 03:03 PM

Again apologies, and I hope this info is sufficient?

Yes/no.

Which grub4dos version?
(there may be differences :))

The error is strange, though I never tested the --in-situ option with a "4 entries filled" hard disk, I had gathered that it's use was convenient EXACTLY when they are full (and thus you cannot use partnew). ;)

In any case mapping something without --hooking it is probably wrong.

Try mapping to a non existing hard disk.
When experimenting ALWAYS use command line and NEVER use a pre-made menu.lst (this way we know which actual command causes the error and see the actual feedback).

What happens with:
map --in-situ (hd0,4)+1 (hd1)
[ENTER]
map --hook
[ENTER]
map (hd1) (hd0)
[ENTER]
map (hd0) (hd1)
[ENTER]
map --hook
[ENTER]
root (hd0,
[TAB]
root (hd1,
[TAB]

:)
Wonko

#8 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 09 August 2011 - 05:01 PM

Yes/no.

Which grub4dos version?
(there may be differences ;))

Oops. I was using the google code site's 0.4.5b version dated 11-08-02, but I've since updated to the 11-08-09 version.

Try mapping to a non existing hard disk.
When experimenting ALWAYS use command line and NEVER use a pre-made menu.lst (this way we know which actual command causes the error and see the actual feedback).

Okay.

What happens with:
map --in-situ (hd0,4)+1 (hd1)

After entering this command, I directly received the previous error.

Error 64: Cannot use --in-situ because the partition table is full(i.e., all the 4 entries are in use).

I even tried mapping the drives first, before attempting.

map (hd0) (hd1)

map (hd1) (hd0)

map --hook

I receive an error stating the device doesn't exist, and then after trying this command.
map --in-situ (hd1,4)+1 (hd0)

I get the same error.

Error 64: Cannot use --in-situ because the partition table is full(i.e., all the 4 entries are in use).

I'm not sure if this is relevant, but I also attempting directly mapping (hd0,4) to (hd0).

After entering...
map (hd0,4)+1 (hd0)

[ENTER]

This is the message I see.

BPB probed C/H/S = 6081/255/63, BPB probed total sectors = 97675264

Try to locate extended partition (hd0)1660497857+97675327 for the virtual (hd0)

Error 41: Extended partition table is invalid, or its CHS values conflict with the BPB in a logical partition.

Edited by Virii, 09 August 2011 - 05:17 PM.


#9 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13748 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 09 August 2011 - 05:56 PM

Tested, and confirmed. :)

To use map --in-situ you need to have an empty partition entry in the MBR. ;) (forget the attempt in my previous post, it will give you the same error :))

You will need to use a more elaborated approach, like the one talked about here:
http://reboot.pro/7138/

Or, more simply you can try to only fix the BPB of the logical volume.

But, wait, HOW big in size is the disk? 1 Tb? B)

You won't be able ANYWAY to run DOS/Win98 on anything that big without serious problems, let alone having it starting from above the LBA28 limit (around 128 Gb).


:cheers:
Wonko

#10 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 09 August 2011 - 06:16 PM

You will need to use a more elaborated approach, like the one talked about here:
http://reboot.pro/7138/

Hmmm... This will literally take me several hours to comprehend given the context. I won't be able to get back to you on this until at least tomorrow.

Or, more simply you can try to only fix the BPB of the logical volume.

Could you elaborate more on how this would be possible? I'll probably have to re-read the Wikipedia article on CHS again.

But, wait, HOW big in size is the disk? 1 Tb? ;)

You won't be able ANYWAY to run DOS/Win98 on anything that big without serious problems, let alone having it starting from above the LBA28 limit (around 128 Gb).

I'm not expecting full functionality from Win98 anyways, but what does having it start over the LBA28 limit mean? I have non-standard partitioning, with all my partitions starting from the outer edge of disk moving inward. Also, does the 1TB make a difference when I'll never have a fat partition over 50GB present? In actuality the two present fat partitions are all I'm planning on.

Edited by Virii, 09 August 2011 - 06:18 PM.


#11 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13748 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 09 August 2011 - 06:36 PM

Forget (for the moment B)) about that linked thread. :cheers:
Forget also (for good ;)) the CHS article on Wikipedia. (you are delving MUCH deeper than that "general" article)

You CANNOT have Windows 9x boot from anything beyond the LBA28 limit. (though strangely enough you may be able to boot DOS ;))

You may be able to "fix" the Windows 9x to work on partitions that "stretch" over the LBA28 limit (this is NOT easy, and it is VERY likely that if you don't do it properly and fully the result will be a CORRUPTED partition/filesystem :)).

Info is on MSFN (several threads to read :) ):
http://www.msfn.org/...ows-959898seme/
http://www.msfn.org/...98-seme-topics/
http://www.msfn.org/...a-thread-index/

It's a LOT of work! (and unfortunately with uncertain results ;))

And have a quick look here:
http://www.msfn.org/...more-recent-pc/
(as you most probably have a SAT ard disk, more than 1 Gb of RAM and heaven-only-knows which "monster" graphic card)

Correcting the "Sectors Before" or "Hidden Sectors" in the BPB opf the logical volume can be done manually allright, see here:
http://www.goodells.net/multiboot/

Fixing Boot Records in Logical Partitions
A logical volume in the extended primary partition does not usually contain an operating system, and there is not normally a boot record there. (Okay, maybe there's technically a "boot sector", but it's normally blank unless we put an OS there.) If we put an OS and boot record there we need to check the boot record to make sure it knows where to find itself. Petr Soucek has documented that a key parameter in the partition boot sector may prevent an OS from booting from an extended logical partition. This parameter, "Hidden Sectors", should be the total number of sectors on the disk preceding the partition, but for a logical partition the value may be incorrectly initialized by the tool used to create or manipulate the partition. Sometimes it is the number of sectors from the start of the extended partition (e.g., 63) instead of from the beginning of the disk. If this number is incorrect the OS cannot determine where the other sectors of its own partition are and the boot process hangs. Powerquest's Partition Table Editor may be used to fix the "Hidden Sectors" parameter in the partition boot record of any OS's installed in logical partitions. Partition boot records in primary partitions are normally okay.

And:
http://www.goodells....ot/ptable.shtml

You should do your experiments in Qemu (+Qemu Manager).

:(
Wonko

#12 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 09 August 2011 - 07:37 PM

Forget (for the moment :)) about that linked thread. B)
Forget also (for good :cheers:) the CHS article on Wikipedia. (you are delving MUCH deeper than that "general" article)

You CANNOT have Windows 9x boot from anything beyond the LBA28 limit. (though strangely enough you may be able to boot DOS ;))

I recently booted W98 off a partition scheme like this.

[<------------900GB Empty><-45GB Fat Prim><15GB Ext3 Prim><-40GB NTFS Prim>]

Whereas the Win98 install was on the primary fat partition, and it worked fine for what I wanted from the install.

With my current setup, do I have to worry about LBA limits as I don't see the need for have large fatn disks under Win9x? Who needs that?

[<---------850GB Empty><50GB Fat Log><-45GB Fat Prim><15GB Ext4 Prim><-40GB NTFS Prim>]

Whereas the Win98 is this time installed to the logical fat. Would this be an issue?

Info is on MSFN (several threads to read :) ):
http://www.msfn.org/...ows-959898seme/
http://www.msfn.org/...98-seme-topics/
http://www.msfn.org/...a-thread-index/

I'll look, but won't promise as I'm familiar with the site. I grew tired of the 2-bit d**che-baggery of some of their members.

I suppose in the end, I may just *sigh* reinstall XP again, but this time to a logical partition. I would then retry the '--in-situ' compatibility with a free partition entry.

You should do your experiments in Qemu (+Qemu Manager).

I've never tried VM's before, but I suppose I could try.

;)
Wonko

And cheers to you too. *downs some ale*
Thanks, I'll report back if I can.

#13 Virii

Virii

    Member

  • Members
  • 56 posts
  •  
    United States

Posted 10 August 2011 - 03:43 AM

If anyone can delete the post before this one, please do. I was unable to amend it with this edit.

I decided to just go ahead and delete the extended partition, and the third primary. I recreated the extended partition, added 2 logical partitions, and copied over the previous virgin install backup of Windows 98. If I knew the files were all that needed copied, and Win98 didn't need some type of PBR present, I would have kept a backup like this a long time ago.

This left me with the following setup.
(hd0,0) -> Primary NTFS
(hd0,1) -> Primary Ext4
(hd0,4) -> Logical Fat32
(hd0,5) -> Logical Fat32

Before I modified the grub4dos menu, I made these changes to the Windows 98 files (now present on (hd0,5), (hd0,4) reserved for XP). These are the play it safe settings.

Added this setting under the '[386Enh]' section of the system.ini.

[386Enh]

MaxPhysPage=30000

Added this setting to the '[vcache]' setting in the system.ini.

[vcache]

MaxFileCache=393216

I renamed the 'vga.drv' file to 'vga.drv.bak', and made a copy of the 'supervga.drv' file followed by renaming it to 'vga.drv'. I renamed the 'ESDI_506.PDR' file to 'ESDI_506.BAK'.

Because I use a SATA drive, Win98 doesn't recognize logical partitions on it, let alone boot from one.

I initially typed these command in one by one in grub4dos, but later added them to my menu.lst.


map --in-situ (hd0,4)+1 (hd1) <--Making XP partition available as 2nd drive
map --in-situ (hd0,5)+1 (hd0) <--Makes 98 bootable as 1st recognized drive
map --hook
root (hd0,0) <--After mapping, this is Win98 partition
chainloader /io.sys
boot <--Not needed in menu.lst

The results?

Windows 98 booting from a logical partition as though if it were a primary, success.

Edited by Virii, 10 August 2011 - 03:47 AM.


#14 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 13748 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 10 August 2011 - 10:51 AM

Windows 98 booting from a logical partition as though if it were a primary, success.


Good news. :cheers:

Now that you can run it:
  • try the partnew command (it will fix the the Sectors Before in the VBR BPB automatically)
  • delete the new partition entry created by partnew.
  • try chainloading (hd0,5)+1 directly

:cheers:
Wonko




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users