Difference between revisions of "Memtest86"
(Memtest86+ requires an i386 libc) |
|||
(3 intermediate revisions by 3 users not shown) | |||
Line 3: | Line 3: | ||
'''[http://www.memtest86.com/ Memtest86]''' is a program which checks your RAM modules. | '''[http://www.memtest86.com/ Memtest86]''' is a program which checks your RAM modules. | ||
− | It can be run from within GRUB, but also as a coreboot payload (i.e. included in your ROM chip). | + | It can be run from within GRUB, but also as a coreboot [[Payloads|payload]] (i.e. included in your ROM chip). |
== Building == | == Building == | ||
Line 9: | Line 9: | ||
=== Memtest86 === | === Memtest86 === | ||
− | mkdir foo | + | $ '''mkdir foo''' |
− | cd foo | + | $ '''cd foo''' |
− | wget http://www.memtest86.com/memtest86-3.5.tar.gz | + | $ '''wget http://www.memtest86.com/memtest86-3.5.tar.gz''' |
− | tar xfvz memtest86-3.5.tar.gz | + | $ '''tar xfvz memtest86-3.5.tar.gz''' |
− | cd memtest86-3.5 | + | $ '''cd memtest86-3.5''' |
(Optional: edit '''config.h''' and set '''#define SERIAL_CONSOLE_DEFAULT 1''' for serial support) | (Optional: edit '''config.h''' and set '''#define SERIAL_CONSOLE_DEFAULT 1''' for serial support) | ||
− | make | + | $ '''make''' |
− | The file '''memtest''' is your final payload which you can use with coreboot | + | The file '''memtest''' is your final payload which you can use with coreboot, either on real hardware or in a [[QEMU]] image. |
+ | |||
+ | === Memtest86+ === | ||
+ | Prerequisite: on non-i386 hosts be sure to have the i386 libc installed (e.g. libc6-dev-i386). | ||
+ | $ '''wget http://www.memtest.org/download/4.20/memtest86+-4.20.tar.gz''' | ||
+ | $ '''tar xfvz memtest86+-4.20.tar.gz''' | ||
+ | $ '''cd memtest86+-4.20''' | ||
+ | (Optional: edit '''config.h''' and set '''#define SERIAL_CONSOLE_DEFAULT 1''' for serial support) | ||
+ | $ '''make''' | ||
=== coreboot === | === coreboot === | ||
− | Finally, you have to build coreboot | + | Finally, you have to build coreboot with Memtest86 as payload: |
− | cd .. | + | $ '''cd ..''' |
− | svn co svn://coreboot.org/ | + | $ '''svn co svn://coreboot.org/coreboot/trunk coreboot''' |
− | + | $ '''cp memtest86-3.5/memtest coreboot/payload.elf''' | |
− | cd coreboot | + | $ '''cd coreboot''' |
− | make menuconfig | + | $ '''make menuconfig''' |
− | Now enter the '''Payload''' menu and select '''Payload type''' and then '''An ELF executable payload file'''. | + | Now enter the '''Payload''' menu and select '''Payload type''' and then '''An ELF executable payload file'''. Then, exit the menu, save your settings, and build coreboot: |
− | make | + | $ '''make''' |
− | The file '''build/coreboot.rom''' | + | The file '''build/coreboot.rom''' is your final coreboot image, which also contains the payload. |
== Running Memtest86 in QEMU == | == Running Memtest86 in QEMU == | ||
− | For running the coreboot+Memtest86 image in QEMU, you need a patched version of '''vgabios-cirrus.bin''' in your '''build''' directory first: | + | For running the coreboot+Memtest86 image in [[QEMU]], you need a patched version of '''vgabios-cirrus.bin''' in your '''build''' directory first: |
− | cd build | + | $ '''cd build''' |
− | wget http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip | + | $ '''wget http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip''' |
− | unzip Vgabios-cirrus.zip | + | $ '''unzip Vgabios-cirrus.zip''' |
− | cd .. | + | $ '''cd ..''' |
− | You can now run coreboot and Memtest86 in QEMU: | + | You can now run coreboot and Memtest86 in [[QEMU]]: |
qemu -L build -hda /dev/zero -serial stdio | qemu -L build -hda /dev/zero -serial stdio | ||
Line 50: | Line 58: | ||
== Ready-made QEMU image == | == Ready-made QEMU image == | ||
− | Please follow [ | + | Please follow [[QEMU#coreboot_v3_.2B_Memtest86|these instructions]] if you want to try out coreboot and Memtest86 in [[QEMU]]. |
{{PD-self}} | {{PD-self}} |
Latest revision as of 20:55, 9 October 2012
Memtest86 is a program which checks your RAM modules.
It can be run from within GRUB, but also as a coreboot payload (i.e. included in your ROM chip).
Contents
Building
Memtest86
$ mkdir foo $ cd foo $ wget http://www.memtest86.com/memtest86-3.5.tar.gz $ tar xfvz memtest86-3.5.tar.gz $ cd memtest86-3.5
(Optional: edit config.h and set #define SERIAL_CONSOLE_DEFAULT 1 for serial support)
$ make
The file memtest is your final payload which you can use with coreboot, either on real hardware or in a QEMU image.
Memtest86+
Prerequisite: on non-i386 hosts be sure to have the i386 libc installed (e.g. libc6-dev-i386).
$ wget http://www.memtest.org/download/4.20/memtest86+-4.20.tar.gz $ tar xfvz memtest86+-4.20.tar.gz $ cd memtest86+-4.20
(Optional: edit config.h and set #define SERIAL_CONSOLE_DEFAULT 1 for serial support)
$ make
coreboot
Finally, you have to build coreboot with Memtest86 as payload:
$ cd .. $ svn co svn://coreboot.org/coreboot/trunk coreboot $ cp memtest86-3.5/memtest coreboot/payload.elf $ cd coreboot $ make menuconfig
Now enter the Payload menu and select Payload type and then An ELF executable payload file. Then, exit the menu, save your settings, and build coreboot:
$ make
The file build/coreboot.rom is your final coreboot image, which also contains the payload.
Running Memtest86 in QEMU
For running the coreboot+Memtest86 image in QEMU, you need a patched version of vgabios-cirrus.bin in your build directory first:
$ cd build $ wget http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip $ unzip Vgabios-cirrus.zip $ cd ..
You can now run coreboot and Memtest86 in QEMU:
qemu -L build -hda /dev/zero -serial stdio
Ready-made QEMU image
Please follow these instructions if you want to try out coreboot and Memtest86 in QEMU.
![]() |
I, the copyright holder of this work, hereby release it into the public domain. This applies worldwide.
In case this is not legally possible: |