Partition
無法創建新分區
我有一個擁有 508 G 可用空間的 CentOS 系統。我想從中創建一個新分區。它位於擴展分區中。
我創建新分區並將其格式化為任何內容(ext4,fat32),應用後它無法完成該過程並給我這個錯誤:
An error occurred while applying the operations See the details for more information. IMPORTANT If you want support, you need to provide the saved details! See http://gparted.sourceforge.net/larry/tips/save_details.htm for more information.
當我保存它時,
save_details.htm
它包含以下資訊:GParted 0.6.0 Libparted 2.1 Create Logical Partition #1 (fat32, 508.23 GiB) on /dev/sda 00:00:01 ( ERROR ) calibrate New Partition #1 00:00:00 ( SUCCESS ) path: /dev/sda-1 start: 184424448 end: 1250263039 size: 1065838592 (508.23 GiB) create empty partition 00:00:01 ( ERROR ) libparted messages ( INFO ) WARNING: the kernel failed to re-read the partition table on /dev/sda (Device or resource busy). As a result, it may not reflect all of your changes until after reboot. WARNING: the kernel failed to re-read the partition table on /dev/sda (Device or resource busy). As a result, it may not reflect all of your changes until after reboot. ========================================
我使用 fdisk 和 created
/dev/sda6
,我看到這樣的分區:$ sudo fdisk -l Disk /dev/sda: 640.1 GB, 640135028736 bytes 255 heads, 63 sectors/track, 77825 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disk identifier: 0xa62a8bc3 Device Boot Start End Blocks Id System /dev/sda1 * 1 262 2097152 83 Linux Partition 1 does not end on cylinder boundary. /dev/sda2 262 5361 40960000 83 Linux /dev/sda3 5361 10460 40960000 83 Linux /dev/sda4 10460 77826 541113344 5 Extended /dev/sda5 10461 11480 8192000 82 Linux swap / Solaris /dev/sda6 11480 77825 532917056+ 83 Linux Partition 6 does not start on physical sector boundary.
但是當我
mkfs
用來格式化它時,我看到了這個錯誤:$ sudo mkfs -t ext4 /dev/sda6 mke2fs 1.41.12 (17-May-2010) Could not stat /dev/sda6 --- No such file or directory The device apparently does not exist; did you specify it correctly?
問題是什麼?
您應該通知核心有關對磁碟所做的更改。為此,您需要執行
partprobe
.
# partprobe /dev/sda6
然後您應該執行
mkfs.ext4
以將文件系統分配給新創建的分區。
# mkfs.ext4 /dev/sda6
這樣你的分區就準備好了
mount
# mount /dev/sda6 /mountpoint
partprobe -s
您必須在執行任何操作之前執行該命令/dev/sda6
如果您沒有該命令,則只需重新啟動機器