[syslinux] syslinux tool for Win2k and 'safeboot' option

Patrick J. LoPresti patl at curl.com
Sun Oct 27 05:49:16 PST 2002


"H. Peter Anvin" <hpa at zytor.com> writes:

> You know, you actually *have* that state already.  Create the
> partition table, compare it with the that's on the disk, if not the
> same, install and reboot.  If it *is* the same, keep going...

We are moving ever farther off-topic, but hey, it's your list ;-).

Actually, I had thought of this.  The problem is that there is no easy
way to do it.  I do not particularly want to roll my own code for
reading/writing the partition table when FreeDOS fdisk already does
such a nice job.  But FreeDOS fdisk does not provide an interface to
feed in a bunch of partitioning commands and then only install the new
table if it changed.  (I suppose I could add such an interface since I
have the source code.)

But wait a minute...  There *is* an interface to dump the current
partition table to stdout.  So I just now realized I can:

  1) dump the partition table (fdisk /info)

  2) erase the partition table and create a new one (fdisk /whatever)

  3) dump the partition table again

...and then compare the two dumps, only rebooting if it actually
changed.

I cannot believe it took me so long to see this.  Thank you!

 - Pat



More information about the Syslinux mailing list