如何在SSD的實體可用空間中建立新分區?

如何在SSD的實體可用空間中建立新分區?

我在新的 SSD 1TB 中克隆了 HDD 320GB,但現在我無法在新支援的實體空白空間中建立新分割區。我gdisk嘗試創建一個,n但可用扇區僅限於舊磁碟大小。

GPT fdisk (gdisk) version 1.0.1

Partition table scan:
  MBR: protective
  BSD: not present
  APM: not present
  GPT: present

Found valid GPT with protective MBR; using GPT.

Command (? for help): p
Disk /dev/sda: 1953525168 sectors, 931.5 GiB
Logical sector size: 512 bytes
Disk identifier (GUID): CD2076D4-0A3C-4C9D-9E20-269AC17A5A49
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 625142414
Partitions will be aligned on 2048-sector boundaries
Total free space is 2669 sectors (1.3 MiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048         1050623   512.0 MiB   EF00  EFI System Partition
   2         1050624       623140863   296.6 GiB   8300
   3       623140864       625141759   977.0 MiB   8200

Command (? for help): n
Partition number (4-128, default 4): 4
First sector (34-625142414, default = 34) or {+-}size{KMGTP}:

如何建立新分割區而不遺失所有資料?

答案1

主GPT分割區表位於磁碟的第1個磁區;備份應該位於最後一個磁區;和所有分區必須居於兩者之間。當您複製到更大的磁碟時,備份分割區表最終會位於中間的某個位置 - 複製工具不會更新其在主表中的位置 - 但所有分割區必須位於它們之間的限制仍然適用。

前往專家選單 ( x),然後使用命令e「將備份資料結構重新定位到磁碟末尾」。然後進行更改並寫入分區表。 (您可以用來p驗證「總可用空間」現在是否正確顯示。)

或者,使用 util-linux fdisk– 它會在寫入期間自動重新定位備份 GPT。因此,如果您不想實際使用 fdisk 進行分區,只需載入分區表並再次將其寫出就足夠了。

相關內容