Jump to content

USB Drive MBR Access under Win98


awkduck

Recommended Posts

It seems that, with USB drives, I cannot access the MBR under Win98.

I've also notice the same thing under DOS, when using USB drivers for DOS.

"SYS X:", X equals USB Drive under Dos/Windows, and Windows format do transfer system files. But both fail to touch the MBR.

If I used HxD to view the drive, the MBR is not to be found.

And Partition magic cannot see the drive.

The test USB drive is a 16GB pendrive.

This post is just to verify that this is a limitation of Win98.

If not, a work around would be welcomed.

Or is this the outcome of using updated USB drivers?

The PartitionMagic manual says USB drives are fine.

Link to comment
Share on other sites


Under DOS:

SYS or FORMAT shouldn't affect the MBR anyway.

FDISK should.

It is very possible that *for whatever reasons* the drivers you are using mount only the volume (partition).

How (exactly) are you using HxD?

I mean, what are you accessing? If it is the drive letter then the MBR is not there, I don't know if under DOS/Windows98 there is an object similar to what the \\PgysicalDrive is in NT, the "Hard Disk n" in HxD seen here:

https://thestarman.pcministry.com/tool/HexEds.htm

I wouldn't be too surprised if your drivers or something else consider the USB stick a "removable" device and mount it only as "superfloppy", automatically "filtering out" the MBR and the sectors before the volume.

jaclaz

 

Link to comment
Share on other sites

Hey jaclaz,

9 hours ago, jaclaz said:

It is very possible that *for whatever reasons* the drivers you are using mount only the volume (partition).

This has been my suspicion.

9 hours ago, jaclaz said:

How (exactly) are you using HxD?

On other setups, HxD can copy the whole physical drive and edit the MBR.

Under "Extras > Open Disk" you are given partition options, under a "Logical disks" lable. They are listed as C:, D:, etc..

Below that you are given a label "Physical disks". They are listed "Hard Disk 1", "Hard Disk 2", etc..

I am opening under the "Physical disk" label.

9 hours ago, jaclaz said:

I wouldn't be too surprised if your drivers or something else consider the USB stick a "removable" device and mount it only as "superfloppy", automatically "filtering out" the MBR and the sectors before the volume.

This is exactly what I believe is happening. But I haven't had enough experience with USB and Win9x. I know it lets me format it, as a kind of superfloppy, if there isn't already a partition on the drive. I just don't know if that is normal, or not.

There will be no MBR.

It will mount multiple partitions, if they are present on the device.

Link to comment
Share on other sites

RMPREPUSB (to workaround a similar issue in some BIOSes) creates (optionally) a second (very small, only one cylinder, and with a hidden ID, 21 if I recall correctly) partition, but that is intended for bootable sticks, if you see multiple partitions than *somehow* the MBR is read (though it is still possible that it is not "hooked").

To make a comparison, on NT systems, the known IMDISK driver (which should be called IMVOLUME, instead as it does not mount the disk, but rather the volume) "hooks" at a level "higher than disk manager/diskpart.

Does FDISK see the disk? <- I believe that all other tools (including Partition Magic) have the same type of access as FDISK

I don't think, in the case of USB attached to an already booted OS (I believe this is the case you are referring to), that there can be a workaround, as essentially the Windows 98 USB drivers "filter" whatever they want, if you actually boot from the USB stick, things should be different as the device is  "mapped" by the BIOS.

There could be (very likely limited to DOS, NOT to the GUI Windows command prompt) a workaround through grub4dos, if you can see when booting (even if booting from another device) the USB stick, if needed using the grub4dos USB drivers (aka usb --init) then the device would be BIOS mapped and (possibly, it has to be tested) available to FDISK in the DOS session, directly or though some form of remapping in grub4dos.

Still the USB stick need to be connected before booting, so, even if it works it would be only a very partial workaround.

jaclaz

Link to comment
Share on other sites

In Windows FDISK can see the drives partition, when there is only one.

If I put two partitions on the drive, FDISK crashes after asking if you want to enable large disk support.

The reason I looked into this, is because sometimes I end up behind a Windows machine, more then a Linux machine. I also don't really ever use any NT variant. Sometimes I run into a situation where I'd like to make a bootable USB drive, and would like to do it without rebooting. It is something I can easily live without. But, sometimes you've just got to see if it can be done.

Link to comment
Share on other sites

I'm just mentioning the 2 versus 1 partition, as a way to expand on some of the speculations jaclaz has put forth.

The primary issue, is accessing the MBR. As an example, the boot loader Syslinux comes with an MBR that must be written to the drive, in order to function as a sole boot loader. When I am installing it, to the main O.S. drive, I can use something like WDE for dos. However, in attempting to do this for a USB drive, WDE cannot even view the MBR. The same is true for the HxD hex/drive editor.

 But to answer your question, if the drive is zero filled, FDISK cannot even see the drive. "Change current fixed disk drive" displays only the physical C: drive.

Link to comment
Share on other sites

FDISK won't allow anyway making more than one (primary) partition, the second can only be extended (with inside it one or more volumes), but it shouldn't crash on devices with more than one primary (i.e. it is another sign that *something* is "wrong" and specific to USB devices that are not BIOS mapped).

jaclaz

Link to comment
Share on other sites

So the issue is not the BIOS (in itself) nor (probably) the USB drivers (in themselves) it is a combination of the two.

Pure speculation, to be checked/confirmed:

Case A, stick connected before booting:

A1) when legacy USB is disabled in BIOS the OS knows nothing about the USB stick and when the drivers load they load/mount the device fully
A2) when legacy BIOS is enabled in BIOS the stick is mapped by BIOS and when the USB drivers load they *somehow* load/mount the device partially

Case B, stick connected after booting:

B1) no matter if legacy USB is enabled or disabled in BIOS, the OS knows nothing about the USB stick until the drivers load and ... (either mount the stick fully or not)

In theory A1 and B1 should behave the same, but there could be a difference between the USB drivers enumerating the stick when loading (case A1) or after having already loaded (case B1).

jaclaz

Edited by jaclaz
Link to comment
Share on other sites

After disabling BIOS USB legacy support, and then booting with the USB drive connected, Windows installed some USB related driver. It was not very specific in description. However, the Systray didn't provide the connected device icon. The USB drive was not accessible. After removing and reinserting, the drive and MBR were accessible. Interestingly, after all of this, I can now have legacy USB enabled in BIOS; and MBR access is still retained.

Initially, I though that the only reason it was "now" allowing me access (even with legacy USB enable), might have been something to do with "now" having been partitioned/formatted by Dos through Windows. But partitioning/formatting the device with Linux, with a foreign Linux filesystem, didn't prevent access to the MBR.

Link to comment
Share on other sites

So it definitely is (was) something "queer" with the USB drivers you had before, and that now are probably either another set of drivers or re-initlalized/reinstalled.

I have no idea if Windows 98 uses or can use "filter drivers" (like NT family, like the mentioned cfadisk, dummydisk, etc. ) what you reported might be related to one such filter drivers (installed and "paired" to either the whole USB subsystem or to that specific stick).

Still in the NT world, there are similar enough reported misbehaviours with CD/DVD players due to  (upper and lower) filter drivers related entries in the Registry, so it could have also been some Registry related issue, hopefully corrected by the sort of "reset" you did by disabling legacy USB in BIOS.

jaclaz

Link to comment
Share on other sites

On 1/26/2023 at 6:25 PM, jaclaz said:

So it definitely is (was) something "queer" with the USB drivers you had before, and that now are probably either another set of drivers or re-initlalized/reinstalled.

Just in case someone else runs into this, or something like it, here is the rest of the situation.

For me thing is workable (better than before). Ironically, if I want to format the USB drive correctly, I must boot the system with the USB drive connected and legacy USB enabled in BIOS. But, I must remove the drive and reinsert it to access the partition. I thought it was because FDISK had ran. But it turns out, if I boot with it connected and legacy USB enabled in BIOS again (already partitioned and formatted), I still cannot access the drive without removing and reinserting the it.

Like I said, I can live with it.

Thanks for the assistance, you two.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...