百科.dev
全部条目AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
M

memtest86plus

> 编程语言
开源

Memtest86+ 的官方仓库

1.7K stars0 点赞0 次浏览
访问官网GitHub

工具介绍

Memtest86+ 的官方仓库

Memtest86+

Memtest86+ is a free, open-source, stand-alone memory tester for x86, x86-64, ARM AArch64 and LoongArch64 architecture computers. It provides a much more thorough memory check than that provided by BIOS memory tests.

It is also able to access almost all the computer's memory, not being restricted by the memory used by the operating system and not depending on any underlying software like UEFI libraries.

Memtest86+ can be loaded and run either directly by a PC BIOS (legacy or UEFI) or via an intermediate bootloader that supports the Linux 16-bit, 32-bit, 64-bit, or EFI handover boot protocol. It should work on most x86, x86-64 CPU (Pentium class or later 32-bit or 64-bit), most ARMv8-A AArch64 CPU (UEFI boot only) and most LoongArch64 CPU (Loongson 3 and Loongson 2 family).

Binary releases (both stable and nightly dev builds) are available on memtest.org.

Table of Contents

  • Origins
  • Licensing
  • Build and Installation
  • Boot Options
  • Keyboard Selection
  • Operation
  • Error Display
  • Trouble-shooting Memory Errors
  • Execution Time
  • Memtest86+ Test Algorithms
  • Individual Test Descriptions
  • Known Limitations and Bugs
  • Code Contributions
  • Acknowledgments

Origins

Memtest86+ v6.00 was based on PCMemTest, which was a fork and rewrite of the earlier Memtest86+ v5, which in turn was a fork of MemTest-86. The purpose of the PCMemTest rewrite was to:

  • make the code more readable and easier to maintain
  • make the code 64-bit clean and support UEFI boot
  • fix failures seen when building with newer versions of GCC

In the process of creating PCMemTest, a number of features of Memtest86+ v5 that were not strictly required for testing the system memory were dropped. In particular, no attempt was made to measure the cache and main memory speed, or to identify and report the DRAM type. These features were added back and expanded in Memtest86+ v6.0 to create a unified, fully-featured release.

Licensing

Memtest86+ is released under the terms of the GNU General Public License version 2 (GPLv2). Other than the provisions of the GPL there are no restrictions for use, private or commercial. See the LICENSE file for details.

Build and Installation

Build is only tested on a Linux system, but should be possible on any system using the GNU toolchain and the ELF file format. The tools required are:

  • GCC or cross-GCC
  • binutils
  • make
  • dosfstools and mtools (optional)
  • xorrisofs (optional)

To build a x86 32-bit image

Change directory into the build/i586 directory and type make. The result is a mt86plus binary image file which can be booted directly by a 32-bit UEFI BIOS (if named mt86plus.efi), by a legacy BIOS (in floppy mode) or by an intermediate bootloader using the Linux 16-bit boot protocol. The image can be also booted by an intermediate bootloader using the Linux 32-bit or 32-bit EFI handover boot protocols.

To build a x86-64 64-bit image

Change directory into the build/x86_64 directory and type make. The result is a mt86plus binary image file which can be booted directly by a 64-bit UEFI BIOS (if named mt86plus.efi), by a legacy BIOS (in floppy mode) or by an intermediate bootloader using the Linux 16-bit boot protocol. The image can be also booted by an intermediate bootloader using the Linux 32-bit, 64-bit, or 64-bit EFI handover boot protocols.

To build an ARM AArch64 64-bit image

Change directory into the build/aarch64 directory and type make. When not building on an AArch64 host, the Makefile defaults to the aarch64-linux-gnu- cross toolchain; pass CC=, LD= and OBJCOPY= overrides if yours is named differently. The result is a mt86plus binary image file which can be booted directly by a 64-bit UEFI firmware (if named mt86plus.efi, or as EFI/BOOT/BOOTAA64.EFI on removable media). UEFI is the only supported boot method on this architecture.

To build a LoongArch64 64-bit image

x86-64 Linux environment

  • Download the cross-compiler.
    bash
    sudo mkdir /opt/LoongArch_Toolchains -p; cd /opt/LoongArch_Toolchains
    Use wget to download the latest version or other versions cross-compiler.
  • Configure cross-GCC.
    bash
    sudo tar -xvf x86_64-cross-tools-xxxxxx.tar.gz
    export PATH=/opt/LoongArch_Toolchains/cross-tools/bin/:$PATH
  • Return to the memtest86plus directory
  • Change directory into the build/loongarch64 directory and make.
    bash
    cd build/loongarch64
    make CC=loongarch64-unknown-linux-gnu-gcc LD=loongarch64-unknown-linux-gnu-ld OBJCOPY=loongarch64-unknown-linux-gnu-objcopy

LoongArch64 Linux environment

Change directory into the build/loongarch64 directory type make.

The result is a mt86plus binary image file which can be booted directly by a 64-bit UEFI BIOS (if named mt86plus.efi), and the image can also booted by an intermediate bootloader using the 64-bit EFI handover boot protocols.


In either case, to build an ISO image that can be used to create a bootable CD, DVD, or USB Flash drive, type make iso, The result is a memtest.iso ISO image file. This can then be written directly to a blank CD or DVD, or to a USB Flash drive, which can then be booted directly by a legacy or UEFI PC BIOS.

Note that when writing to a USB Flash drive, the ISO image must be written directly ('dumped') to the raw device, either by using the dd command or by using a utility that provides the same functionality.

When using an intermediate bootloader, mt86plus file should be stored in a disk partition the bootloader can access, and the bootloader configuration should be updated to boot from that file as if it were a Linux kernel with no initial RAM disk. Several boot command line options are recognised, as described below. If using the 16-bit boot protocol, Memtest86+ will use the display in text mode (640x400). If using the 32-bit or 64-bit boot protocols, Memtest86+ will use the display in either text mode or graphics mode, as specified in the boot_params struct passed to it by the bootloader. If in graphics mode, the supplied framebuffer must be at least 640x400 pixels; if larger, the display will be centred. If the system was booted in UEFI mode, graphics mode must be used.

For test purposes, there is also an option to build an ISO image that uses GRUB as an intermediate bootloader. See the individual Makefile under the build directory for details. The ISO image is both legacy and UEFI bootable, so you need GRUB modules for both legacy and EFI boot installed on your build system (e.g. on Debian, the required GRUB modules are located in packages grub-pc-bin, grub-efi-ia32-bin, grub-efi-amd64-bin, grub-efi-arm64-bin and grub-efi-loong64-bin). You may need to adjust some path and file names in the Makefile to match the naming on your system.
P.S. LoongArch64 GRUB ISO can only be created on LoongArch64 Linux environment.

The GRUB configuration files contained in the grub directory are there for use on the test ISO, but also serve as an example of how to boot Memtest86+ from GRUB.

Boot Options

An intermediate bootloader may pass a boot command line to Memtest86+. The command line may contain one or more options, separated by spaces. Each option consists of an option name, optionally followed by an = sign and one or more parameters, separated by commas. The following options are recognised:

  • nosmp
    • disables ACPI table parsing and the use of multiple CPU cores
  • nobench
    • disables the integrated memory benchmark
  • nobigstatus
    • disables the big PASS/FAIL pop-up status display
  • nosm
    • disables SMBUS/SPD parsing, DMI decoding and memory benchmark
  • nospdcrc
    • disables SPD checksum/CRC verification
  • nomch
    • disables memory controller configuration polling
  • nopause
    • skips the pause for configuration at startup
  • keyboard=type
    • where type is one of
      • legacy
      • usb
      • both
  • dark
    • change the default background colour from blue to black
  • screen.mode=wxh (EFI framebuffer only)
    • where wxh is the preferred screen resolution (e.g. 1024x768)
  • screen.mode=bios (EFI framebuffer only)
    • uses the default screen resolution set by the UEFI BIOS
  • screen.rhs-up (graphics mode only)
    • rotates the display clockwise by 90 degrees
  • screen.lhs-up (graphics mode only)
    • rotates the display anti-clockwise by 90 degrees
  • efidebug
    • displays information about the EFI framebuffer
  • usbdebug
    • pauses after probing for USB keyboards
  • usbinit=mode
    • where mode is one of
      • 1 = use the two-step init sequence for high speed devices
      • 2 = add a second USB reset in the init sequence
      • 3 = the combination of modes 1 and 2
  • console=ttySx,y
    • activate serial/tty console output, where x is one of the following IO port
      • 0 = 0x3F8
      • 1 = 0x2F8
      • 2 = 0x3E8
      • 3 = 0x2E8
    • and y is an optional baud rate to choose from the following list
      • 9600
      • 19200
      • 38400
      • 57600
      • 115200 (default if not specified or invalid)
      • 230400
  • console=x,y
    • activate MMIO UART console, where x is the MMIO stride (reg. width)
      • mmio = 8-bit MMIO
      • mmio16 = 16-bit MMIO
      • mmio32 = 32-bit MMIO
    • and y is the MMIO address in hex. with 0x prefix (eg: 0xFEDC9000)
  • newline
    • modifies the console to print a newline after every change to the frame buffer
      • useful in logging over serial where an escape or newline is needed
    • only used when using console/serial output
  • log=x,y
    • activate the machine-parseable serial log instead of the interactive serial console, using the same x,y parameters as console=
    • outputs one MTLOG ts=<seconds> ev=<event> key=value ... line per event (start banner, system info, pass/test lifecycle, timed progress, errors)
    • mutually exclusive with console=; if both are given, log wins
  • maxpasses=n
    • stop after n completed passes: emit a final ev=done line, then reboot
    • only used in log mode; 0 = unlimited (default)
  • testlist=x,y,z
    • where x,y,z is a list of the numerical values of the tests to run.
    • if specified, the initial test configuration is modified such that only the specified tests in the list are active. The list should be comma separated For example: testlist=0,1 would only run tests 0 and 1.
  • ecc
    • Enable ECC polling

Keyboard Selection

Memtest86+ supports both the legacy keyboard interface (using I/O or MMIO ports 0x60 and 0x64) and USB keyboards (using its own USB device drivers). One or the other or both can be selected via the boot command line. If not specified on the command line, the default is to use both if the system was booted in UEFI mode, otherwise to only use the legacy interface.

Older x86 or x86-64 BIOSs usually support USB legacy keyboard emulation, which makes USB keyboards act like legacy keyboards connected to ports 0x60 and 0x64. This can often be enabled or disabled in the BIOS setup menus. If Memtest86+'s USB device drivers are enabled, they will override this and access any USB keyboards directly. The downside of that is that the USB controllers and device drivers require some memory to be reserved for their private use, which means that memory can't then be covered by the memory tests. So to maximise test coverage, if it is supported, enable USB legacy keyboard emulation and, i

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

C

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言