Difference between revisions of "User:Ady/test"

From Syslinux Wiki
Jump to: navigation, search
m (Wiki formatting test)
(Testing effects of css styles "display: none" vs "visibility: hidden".)
Line 149: Line 149:
  
 
For comments, feedback or questions, please [[contact]] The Syslinux Project.
 
For comments, feedback or questions, please [[contact]] The Syslinux Project.
 +
 +
----
  
 
<br />
 
<br />
Line 294: Line 296:
  
 
<code><span style=" color:#f9f9f9; background: #f9f9f9; ">text</span></code><span style=" color:#f9f9f9; background: #f9f9f9; ">  <!-- THIS ROW SETS COLUMN1 WIDTH --></span>
 
<code><span style=" color:#f9f9f9; background: #f9f9f9; ">text</span></code><span style=" color:#f9f9f9; background: #f9f9f9; ">  <!-- THIS ROW SETS COLUMN1 WIDTH --></span>
 +
 +
 +
 +
 +
 +
===== <span style="visibility: hidden; ">Notes</span> =====
 +
Note the following:
 +
 +
====== <span style="visibility: hidden; ">Note a</span> ======
 +
{{H6|a) }}
 +
The disk image can be uncompressed or compressed with gzip or zip.
 +
 +
====== <span style="display: none; ">Note b</span> ======
 +
{{H6|b) }}
 +
If the disk image is less than 4,194,304 bytes (4096K, 4 MiB) it is
 +
assumed to be a floppy image and MEMDISK will try to guess its
 +
geometry based on the size of the file.  MEMDISK recognizes all the
 +
standard floppy sizes as well as common extended formats:

Revision as of 09:34, 28 June 2019

isohdpfx

As of 2017Apr18, the latest official distribution archive of Syslinux available from kernel.org is 6.04-pre1.

Until the next official archive (6.04-pre2) gets out (there is no ETA nor specific plans), this document includes a "corrected" ("fixed") 'mbr/isohdpfx.bin' (posted in this document in plain hex dump format, named here as "isohdpfx.hex") for those users that might want it.

Alternatively, building a new Syslinux "package" based on git (master head) should also provide a "correct" 'mbr/isohdpfx.bin' (assuming that there are no building-related issues).

The two commits that are relevant for this document are (as of 2017Apr18):

Commits:

http://repo.or.cz/syslinux.git/commit/32c09027423f61c305e2423e52f5f69ecad8e2c0 
http://repo.or.cz/syslinux.git/commit/8739e2ff9ba3f92652c8df846924fd00e1ce2753 

Patches:

http://repo.or.cz/syslinux.git/patch/32c09027423f61c305e2423e52f5f69ecad8e2c0 
http://repo.or.cz/syslinux.git/patch/8739e2ff9ba3f92652c8df846924fd00e1ce2753 


These two patches apply at least since official versions 4.07 up until 6.04-pre1 (both included). The 'syslinux-4.xx' branch in the official Syslinux git repository has been also patched with equivalent commits. These two patches affect only the 'mbr/isohdpfx.S' file in the Syslinux source code.

Once version 6.04-pre2 (or newer) gets out, users can achieve and use the "correct" 'mbr/isohdpfx.bin' file from the official archive.

Prerequisites

This "isohdpfx.bin" can be useful for users failing to boot an isohybrid image from USB device, under certain conditions (please note that _all_ of them must be met for this file / method to be relevant).

  • The ISO image was built with ISOLINUX and includes an isohybrid MBR.
  • ISOLINUX from versions 3.82 up to 6.04-pre1 (both included) are potentially relevant.
  • The USB device was written via a 'dd' command, or some equivalent auxiliary tool, in which the input source was an isohybrid image.
  • The ISO image was written unaltered to the overall USB device ("sdX"), not to a partition (i.e. not to "sdX#") and not unpacked onto any filesystem volume.
  • Optical media, and other methods of transferring the _content_ of the isohybrid image onto a formatted USB device (i.e. instead of directly "burning" the ISO image) are _not_ expected to suffer from the specific boot problems that this method attempts to solve (i.e. are not relevant for this document).
  • The boot problems that this file / method attempts to solve are less likely to show up in newer systems. Just as a (very broad and not-at-all strict) generic approach, if the BIOS is newer than the year 2005, the problems that this file / method is trying to solve are less likely to show up. (As a non-strict reference, 48-bit LBA ATA-6 standard is circa 2003.)


Under the above circumstances, if the (boot) screen shows either:

isolinux.bin missing or corrupt

or

isolinux: Image checksum error, sorry...

then there is a chance that this file / method could help.

Note: This document is relevant whether the isohybrid image was built by using mkisofs (plus the isohybrid tool) or by using xorriso (or by other alternatives). In other words, the specific tool that builds the isohybrid image is _not_ a factor; the relevant conditions are those listed above, together with the aforementioned (error) messages.

Hexdump

The following is a plain hexdump of the "correct" ("fixed") 'isohdpfx.bin' file (432 bytes). Let's name the new file as 'isohdpfx_20170418.bin' and its hexdump as 'isohdpfx_20170418.hex'.

33 ED 90 90 90 90 90 90 90 90 90 90 90 90 90 90 
90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 
33 ED FA 8E D5 BC 00 7C FB FC 66 31 DB 66 31 C9 
66 53 66 51 06 57 8E DD 8E C5 52 BE 00 7C BF 00 
06 B9 00 01 F3 A5 EA 4B 06 00 00 52 B4 41 BB AA 
55 31 C9 30 F6 F9 CD 13 72 16 81 FB 55 AA 75 10 
83 E1 01 74 0B 66 C7 06 F3 06 B4 42 EB 15 EB 02 
31 C9 5A 51 B4 08 CD 13 5B 0F B6 C6 40 50 83 E1 
3F 51 F7 E1 53 52 50 BB 00 7C B9 04 00 66 A1 B0 
07 E8 44 00 0F 82 80 00 66 40 80 C7 02 E2 F2 66 
81 3E 40 7C FB C0 78 70 75 09 FA BC EC 7B EA 44 
7C 00 00 E8 83 00 69 73 6F 6C 69 6E 75 78 2E 62 
69 6E 20 6D 69 73 73 69 6E 67 20 6F 72 20 63 6F 
72 72 75 70 74 2E 0D 0A 66 60 66 31 D2 66 03 06 
F8 7B 66 13 16 FC 7B 66 52 66 50 06 53 6A 01 6A 
10 89 E6 66 F7 36 E8 7B C0 E4 06 88 E1 88 C5 92 
F6 36 EE 7B 88 C6 08 E1 41 B8 01 02 8A 16 F2 7B 
CD 13 8D 64 10 66 61 C3 E8 1E 00 4F 70 65 72 61 
74 69 6E 67 20 73 79 73 74 65 6D 20 6C 6F 61 64 
20 65 72 72 6F 72 2E 0D 0A 5E AC B4 0E 8A 3E 62 
04 B3 07 CD 10 3C 0A 75 F1 CD 18 F4 EB FD 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

The same hexdump presented as a one-line:

33 ED 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 33 ED FA 8E D5 BC 00 7C FB FC 66 31 DB 66 31 C9 66 53 66 51 06 57 8E DD 8E C5 52 BE 00 7C BF 00 06 B9 00 01 F3 A5 EA 4B 06 00 00 52 B4 41 BB AA 55 31 C9 30 F6 F9 CD 13 72 16 81 FB 55 AA 75 10 83 E1 01 74 0B 66 C7 06 F3 06 B4 42 EB 15 EB 02 31 C9 5A 51 B4 08 CD 13 5B 0F B6 C6 40 50 83 E1 3F 51 F7 E1 53 52 50 BB 00 7C B9 04 00 66 A1 B0 07 E8 44 00 0F 82 80 00 66 40 80 C7 02 E2 F2 66 81 3E 40 7C FB C0 78 70 75 09 FA BC EC 7B EA 44 7C 00 00 E8 83 00 69 73 6F 6C 69 6E 75 78 2E 62 69 6E 20 6D 69 73 73 69 6E 67 20 6F 72 20 63 6F 72 72 75 70 74 2E 0D 0A 66 60 66 31 D2 66 03 06 F8 7B 66 13 16 FC 7B 66 52 66 50 06 53 6A 01 6A 10 89 E6 66 F7 36 E8 7B C0 E4 06 88 E1 88 C5 92 F6 36 EE 7B 88 C6 08 E1 41 B8 01 02 8A 16 F2 7B CD 13 8D 64 10 66 61 C3 E8 1E 00 4F 70 65 72 61 74 69 6E 67 20 73 79 73 74 65 6D 20 6C 6F 61 64 20 65 72 72 6F 72 2E 0D 0A 5E AC B4 0E 8A 3E 62 04 B3 07 CD 10 3C 0A 75 F1 CD 18 F4 EB FD 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00


Obtain fixed file

There are several alternatives for users to obtain the "corrected" file. An updated version / build of Syslinux (6.04-pre2 or newer) would include a new, corrected 'isohdpfx.bin' file (assuming that there are no building-related issues). The 'syslinux-4.xx' branch of the official Syslinux git repo can also provide a base for a new build. Package maintainers of (Linux) distributions are invited to test and provide the new 'mbr/isohdpfx.bin'. Feedback is appreciated. Until such build is available, users can use the above hexdump in the following ways (among others).

Alternative A

  1. Open some hex-editor program.
  2. Select the whole plain text hexdump that was posted above in a prior section of this document.
  3. Copy it.
  4. Then paste it in the hex-editor program.
  5. In the hex-editor, save the file as 'isohdpfx_20170418.bin'.

Alternative B

  1. Open some plain-text editor program (not to be confused with some Word / Write editor).
  2. Select the whole plain text hexdump that was posted above in a prior section of this document.
  3. Copy it.
  4. Then paste it in the plain-text editor program.
  5. In the plain-text editor, save the file as 'isohdpfx_20170418.hex'.
  6. Use the 'xxd' tool so as to convert the hexdump file into the binary file :
 xxd -r -p isohdpfx_20170418.hex > isohdpfx_20170418.bin

Note 1: Other tools and methods can be used; the 'xxd' tool is only a simple / suggested alternative.

Note 2: Windows users can obtain "xxd.exe" and execute the same 'xxd' command line.

Fix the boot problem

If the USB device encountered any of the error messages / behavior described in the "Prerequisites" section of this document, then the USB device can be patched and, perhaps, overcome the boot problem.

Before executing the command, please be aware of the following notes:

  • 'sdX' represents the USB device that is having the boot problem; and,
  • it is already written with the original isohybrid image; and,
  • the relevant device(s) is/are unmounted; and,
  • in the following command, the 'if=/path/to/isohdpfx_20170418.bin' option should be modified according to the actual path in which the file, 'isohdpfx_20170418.bin', is actually located; and,
  • the specific device (here represented by a generic 'sdX', which should be modified in the command so as to match the actual device to be written) has been confirmed to be the correct device that is supposed to be patched (in other words, beware to write to the correct device, because writing to the wrong device will cause more troubles than anyone would ever want to encounter). You have been warned!

Then the command (to be executed with "superuser" or "root" permissions):

 dd conv=notrunc bs=1 count=432 if=/path/to/isohdpfx_20170418.bin of=/dev/sdX

(remember to modify '/path/to/' according to the location of the 'isohdpfx_20170418.bin' file in your system, and to use the adequate '/dev/sdX')
would patch the first 432 bytes of the USB device.

Booting with the patched USB device should be expected to solve the problems mentioned in this document. However, please note that not every case can be solved by this corrected isohybrid MBR.

Please note that the original md5/sha checksums / signature of the USB device will no longer be valid after applying the patch.

For comments, feedback or questions, please contact The Syslinux Project.



wiki formatting test

SYSLINUX options:
-s
  Slow, safe, stupid mode.

Use simpler code that boots better. May work on some very buggy BIOSes on which SYSLINUX would otherwise fail. If you find a machine on which the "-s" option is required to make it boot reliably, please send as much info about your machine as you can, and include the failure mode.  

-f
  Force installing.

Ignore precautions. In some cases, this option might not change the result.  

-r
  Raid mode.

If SYSLINUX fails to boot, then tell the BIOS to boot the next device in the boot sequence (usually the next hard disk), instead of stopping with an error message. This is useful for RAID-1 booting.


SYSLINUX options:
-1 --12345678901234567890123 THIS ROW SETS COLUMN1and2 WIDTH
-s
  Slow, safe, stupid mode.

Use simpler code that boots better. May work on some very buggy BIOSes on which SYSLINUX would otherwise fail. If you find a machine on which the "-s" option is required to make it boot reliably, please send as much info about your machine as you can, and include the failure mode.  

-f
  Force installing.

Ignore precautions. In some cases, this option might not change the result.  

-r
  Raid mode.

If SYSLINUX fails to boot, then tell the BIOS to boot the next device in the boot sequence (usually the next hard disk), instead of stopping with an error message. This is useful for RAID-1 booting.

SYSLINUX options:
-1 --12345678901234567890123 THIS ROW SETS COLUMN1and2 WIDTH
-s
  Slow, safe, stupid mode.

Use simpler code that boots better. May work on some very buggy BIOSes on which SYSLINUX would otherwise fail. If you find a machine on which the "-s" option is required to make it boot reliably, please send as much info about your machine as you can, and include the failure mode.  

-f
  Force installing.

Ignore precautions. In some cases, this option might not change the result.  

-r
  Raid mode.

If SYSLINUX fails to boot, then tell the BIOS to boot the next device in the boot sequence (usually the next hard disk), instead of stopping with an error message. This is useful for RAID-1 booting.


SYSLINUX options:
-1 --12345678901234567890123 THIS ROW SETS COLUMN1and2 WIDTH
-s
  Slow, safe, stupid mode.

Use simpler code that boots better. May work on some very buggy BIOSes on which SYSLINUX would otherwise fail. If you find a machine on which the "-s" option is required to make it boot reliably, please send as much info about your machine as you can, and include the failure mode.  

-f
  Force installing.

Ignore precautions. In some cases, this option might not change the result.  

-r
  Raid mode.

If SYSLINUX fails to boot, then tell the BIOS to boot the next device in the boot sequence (usually the next hard disk), instead of stopping with an error message. This is useful for RAID-1 booting.

text



Notes

Note the following:

Note a
a)

The disk image can be uncompressed or compressed with gzip or zip.

Note b
b)

If the disk image is less than 4,194,304 bytes (4096K, 4 MiB) it is assumed to be a floppy image and MEMDISK will try to guess its geometry based on the size of the file. MEMDISK recognizes all the standard floppy sizes as well as common extended formats: