{
    "mode": "man",
    "parameter": "grub-probe",
    "section": "8",
    "url": "https://www.chedong.com/phpMan.php/man/grub-probe/8/json",
    "generated": "2026-06-02T22:32:37Z",
    "synopsis": "grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]",
    "sections": {
        "NAME": {
            "content": "grub-probe - probe device information for GRUB\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "Probe device information for a given path (or device, if the -d option is given).\n",
            "subsections": [
                {
                    "name": "-0",
                    "content": "",
                    "flag": "-0"
                },
                {
                    "name": "-d --device",
                    "content": "given argument is a system device, not a path\n",
                    "flag": "-d",
                    "long": "--device"
                },
                {
                    "name": "-m --device-map",
                    "content": "use FILE as the device map [default=/boot/grub/device.map]\n",
                    "flag": "-m",
                    "long": "--device-map"
                },
                {
                    "name": "-t --target",
                    "content": "print  TARGET  available targets: abstraction, archints, baremetalhints, bioshints,\ncompatibilityhint, cryptodiskuuid, device, disk,  drive,  efihints,  fs,  fslabel,\nfsuuid,  gptparttype,  hintsstring, ieee1275hints, msdosparttype, partmap, partu‐\nuid, zerocheck [default=fs]\n",
                    "flag": "-t",
                    "long": "--target"
                },
                {
                    "name": "-v --verbose",
                    "content": "print verbose messages.\n\n-?, --help\ngive this help list\n",
                    "flag": "-v",
                    "long": "--verbose"
                },
                {
                    "name": "--usage",
                    "content": "give a short usage message\n",
                    "long": "--usage"
                },
                {
                    "name": "-V --version",
                    "content": "print program version\n\nMandatory or optional arguments to long options are also mandatory or optional for any corre‐\nsponding short options.\n",
                    "flag": "-V",
                    "long": "--version"
                }
            ]
        },
        "REPORTING BUGS": {
            "content": "Report bugs to <bug-grub@gnu.org>.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "grub-fstest(1)\n\nThe  full  documentation  for  grub-probe is maintained as a Texinfo manual.  If the info and\ngrub-probe programs are properly installed at your site, the command\n\ninfo grub-probe\n\nshould give you access to the complete manual.\n\n\n\nGRUB 2.06-2ubuntu7.2                        December 2022                              GRUB-PROBE(8)",
            "subsections": []
        }
    },
    "summary": "grub-probe - probe device information for GRUB",
    "flags": [
        {
            "flag": "-0",
            "long": null,
            "arg": null,
            "description": ""
        },
        {
            "flag": "-d",
            "long": "--device",
            "arg": null,
            "description": "given argument is a system device, not a path"
        },
        {
            "flag": "-m",
            "long": "--device-map",
            "arg": null,
            "description": "use FILE as the device map [default=/boot/grub/device.map]"
        },
        {
            "flag": "-t",
            "long": "--target",
            "arg": null,
            "description": "print TARGET available targets: abstraction, archints, baremetalhints, bioshints, compatibilityhint, cryptodiskuuid, device, disk, drive, efihints, fs, fslabel, fsuuid, gptparttype, hintsstring, ieee1275hints, msdosparttype, partmap, partu‐ uid, zerocheck [default=fs]"
        },
        {
            "flag": "-v",
            "long": "--verbose",
            "arg": null,
            "description": "print verbose messages. -?, --help give this help list"
        },
        {
            "flag": "",
            "long": "--usage",
            "arg": null,
            "description": "give a short usage message"
        },
        {
            "flag": "-V",
            "long": "--version",
            "arg": null,
            "description": "print program version Mandatory or optional arguments to long options are also mandatory or optional for any corre‐ sponding short options."
        }
    ],
    "examples": [],
    "see_also": [
        {
            "name": "grub-fstest",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/grub-fstest/1/json"
        },
        {
            "name": "GRUB-PROBE",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/GRUB-PROBE/8/json"
        }
    ],
    "tldr": {
        "source": "official",
        "description": "Probe device information for a particular path or device.",
        "examples": [
            {
                "description": "Get GRUB filesystem module for a path",
                "command": "sudo grub-probe {{-t|--target}} fs {{/boot/grub}}"
            },
            {
                "description": "Get the system device containing a path",
                "command": "sudo grub-probe {{-t|--target}} device {{/boot/grub}}"
            },
            {
                "description": "Get GRUB disk name for a system device",
                "command": "sudo grub-probe {{-t|--target}} drive {{/dev/sdX}} {{-d|--device}}"
            },
            {
                "description": "Get filesystem UUID",
                "command": "sudo grub-probe {{-t|--target}} fs_uuid {{/boot/grub}}"
            },
            {
                "description": "Get filesystem label",
                "command": "sudo grub-probe {{-t|--target}} fs_label {{/boot/grub}}"
            },
            {
                "description": "Get MBR partition type code(two hexadecimal digits)",
                "command": "sudo grub-probe {{-t|--target}} msdos_parttype {{/dev/sdX}}"
            },
            {
                "description": "Probe using a custom device map",
                "command": "sudo grub-probe {{-t|--target}} drive {{/boot/grub}} {{-m|--device-map}} {{path/to/custom_device.map}}"
            }
        ]
    }
}