From Norman Elliott on Thu, 23 Sep 1999
Just read the item on clearing lilo.
All I do is boot from a Dos ( 5 or greater ) boot disc and issue the command:
that seems to fix anything including boot sector viruses. Maybe Linux fdisk would take the same parameter. I enjoy your column, keep up the good work, best wishes,
The /MBR option was undocumented and only introduced in MS-DOS 5.0. I don't remember the question to which you were referring. If I didn't mention FDISK /MBR it was probably because I was not assuming that the user was trying to restore an MS-DOS 5.0 or later boot loader to their system.
Linux fdisk is a different program and doesn't touch the boot code in the MBR. It only works on the partition tables (which comprise the last 66 bytes of the MBR and possibly a set of others for extended partitions).
There are several Linux programs which do write boot records. /sbin/lilo is the most commonly used. 'dd' will do in a pinch (if you have a .bin image to put into place).
BTW: don't count on /MBR to fix a virus. Some viruses encrypt portions of your filesystem, thus causing major problems if they aren't removed corectly. To prevent infection by boot sector viruses, disable the "floppy boot" options in your BIOS. You should only enable those long enough to perform an OS installation or system recovery and disable it immediately thereafter. To prevent viral infect by "multi-partite" and "file infector" viruses, stop running MS-DOS. To avoid MS Windows macro viruses, avoid MS Office, MS Exchange and related software (with virus^H^H^H^H macroing hooks built into them).