Disk
partprobe
Notify the kernel of partition table changes.
Additional Notes
partprobe informs the operating system kernel about changes to the partition table on a disk device. After modifying the partition table with tools like parted, fdisk, or gdisk, the kernel needs to re-read the partition table for the new partitions to appear as device nodes (e.g., /dev/sda1, /dev/sda2).
While the kernel automatically re-reads the partition table in many cases, partprobe is useful when the kernel does not detect changes automatically or when partitions on an in-use disk need to be rescanned without rebooting. It avoids the more aggressive blockdev --rereadpt or hdparm -z approaches.
Syntax
partprobe [options] [device...]
Parameters
device: One or more disk devices to rescan, such as/dev/sda. If no device is given, all devices are probed.
Common Options
-d,--dry-run: Show what would be done without actually doing it.-s,--summary: Show a summary of partition information for each device.-h,--help: Show help and exit.-v,--version: Show version information.
Examples
partprobe
Re-read the partition table on all disk devices.
partprobe /dev/sda
Notify the kernel about changes to /dev/sda only.
partprobe -s /dev/sdb
Show a summary of partitions on /dev/sdb after probing.
sudo partprobe /dev/nvme0n1
Re-read the partition table on an NVMe device.
partprobe -d /dev/sda
Dry run: show what would be done but do not make changes.
Practical Notes
partprobeis part of thepartedpackage. Install it withsudo apt install partedorsudo yum install parted.- If the kernel cannot re-read the partition table (e.g., the disk is in use),
partprobemay report EBUSY. In such cases, a reboot may be necessary. - After
partprobe, new partition device files appear under/dev/. Runlsblkorfdisk -lto verify. - For devices using device-mapper (LVM, multipath),
partprobemay not suffice. Usepartx -aorkpartx -ain those scenarios. - Use
udevadm settleafterpartprobein scripts to ensure all udev rules have processed the new partitions.