الفلاتر
طريقة البحث
  • الكلمات العادية تجد الأسماء والنصوص والأمثلة.
  • "كلمتان" تجد العبارة بالضبط.
  • --name أو -x تجد خيارًا.
  • #كلمة تبحث داخل الأوامر فقط.
  • @grep تجد الدروس والمعامل التي تستخدم grep.
  • الفلاتر: cat:network · in:labs · level:rhcsa · ch:8 · root:yes. ضع ! قبل كلمة لاستبعادها. OR بين الكلمات تعني إحداها.
  • ↑ ↓ للتنقل · Enter للفتح · Esc للإغلاق · / للبحث

partprobe

Tell the kernel to read the partition table of a disk again.

المستوى
امتحان RHCSA
المجموعة
الأقراص وأنظمة الملفات
يحتاج root
نعم
الحزمة
parted

هذا الجزء لم يُترجم بعد. أنت ترى النص الإنجليزي.

ماذا يفعل

After you change partitions, the kernel must learn the new table. fdisk and parted try this themselves; when the disk is in use, the kernel may keep the old table. partprobe DEVICE asks again, so new partitions appear in /dev without a reboot.

طريقة الكتابة

partprobe [-d] [-s] [DEVICE]...

الخيارات 5

الأكثر استخدامًا

DEVICE
The disk to probe (all disks without a name).
-s, --summary
Show a summary of the partitions.
-d, --dry-run
Do not tell the kernel; only check.
-h, --help
Show help.
-v, --version
Show the version.

أمثلة 10

$ مستخدم عادي# بصلاحية root (أو مع sudo)

  1. 1After fdisk

    partprobe /dev/vdb
    lsblk /dev/vdb

    New partitions now have device files.

  2. 2Show what it found

    partprobe -s /dev/vdb
    /dev/vdb: gpt partitions 1 2 3

    Quick check.

  3. 3All disks

    partprobe

    Probes every disk.

  4. 4When it fails

    partprobe /dev/vda
    Error: Partition(s) 2 on /dev/vda have been written, but we have been unable to inform the kernel...

    The disk is busy (system disk). A reboot may be needed, or use partx.

  5. 5Alternative: partx

    partx -u /dev/vdb

    Updates only the changed partitions.

  6. 6Wait for udev to create the devices

    partprobe /dev/vdb; udevadm settle

    In scripts, before mkfs.

  7. 7Dry run

    partprobe -d -s /dev/vdb

    Test without changing anything.

  8. 8After growing a VM disk

    echo 1 > /sys/class/block/vdb/device/rescan; partprobe /dev/vdb

    The kernel learns the new disk size (for SCSI/virtio with rescan support).

  9. 9Check the result with the kernel view

    cat /proc/partitions

    The kernel's list of partitions.

  10. 10In an automated disk setup

    parted -s /dev/vdb mklabel gpt mkpart data xfs 1MiB 100% && partprobe /dev/vdb && mkfs.xfs /dev/vdb1

    Each step only when the step before worked.

رموز الخروج

0 :: Done. 1 :: Error.

الدليل الكامل

هذه الصفحة تشرح الأمر بكلمات بسيطة. الدليل الأصلي فيه كل التفاصيل.

في الطرفية: man 8 partprobe