Parted:如何知道要輸入的起始編號?

Parted:如何知道要輸入的起始編號?

我正在嘗試以最基本的方式使用parted:將外部USB硬碟格式化為ext2(最好是ext4,但似乎不是選項)。大小為 3TB,已卸載在 /dev/sdd

sudo parted /dev/sdd
mklabel
[type gpt]
[type yes to agree that everything on that hard drive will be lost]
mkpart
[type myDefaultPartitionName]
[type what for Start? prompt]

當我能夠克服這一點之後,我怎麼知道要輸入什麼來結束呢?

謝謝

答案1

特別感謝 Darael 幫助我發現 gdisk。以下是我成功對外部硬碟進行分割的步驟。將下面的 x 替換為您的磁碟機的名稱。

sudo apt-get install gdisk

sudo parted -l        # inspect your drive's name and make sure it is the external one!
sudo umount /dev/sdx1 # ensure that drive is NOT mounted
sudo gdisk /dev/sdx1  # launch gdisk on the drive of interest
?       # explore the features gdisk offers
n       # create a [n]ew partition
[enter] # choose default first sector
[enter] # choose default last sector
a502    # choose FreeBSD
v       # [v]erify
c       # [c]hange the name of the partition, e.g. MY_1TB_BACKUP
p       # [p]rint to ensure the renaming is to your liking
w       # [w]rite the changes to disk

sudo mkfs -t ext4 /dev/sdx1 # create the filesystem as type ext4

相關內容