我添加了 2 個 2TB 硬碟,與 Windows 不同的是,我會看到 C:/ D:/ 等等...我什麼也沒看到
所以我的問題是如何格式化這些磁碟機以及在哪裡可以看到它們(我使用 Swish 在 Windows 7 中查看它們)
這是我使用後得到的fdisk -l
:
WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.
Disk /dev/sda: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/sda doesn't contain a valid partition table
WARNING: GPT (GUID Partition Table) detected on '/dev/sdb'! The util fdisk doesn't support GPT. Use GNU Parted.
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/sdb doesn't contain a valid partition table
Disk /dev/sdc: 150.0 GB, 150038863360 bytes
255 heads, 63 sectors/track, 18241 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00055c68
Device Boot Start End Blocks Id System
/dev/sdc1 * 1 17498 140546048 83 Linux
/dev/sdc2 17498 18242 5974017 5 Extended
/dev/sdc5 17498 18242 5974016 82 Linux swap / Solaris
答案1
我建議使用 pared 工具而不是 fdisk 來對它們進行分區。
http://www.gnu.org/software/parted/manual/html_node/Running-Parted.html#Running-Parted
如果您執行的是 Gnome 或 KDE 等 GUI,也可以使用 gparted。
http://gparted.sourceforge.net/
無論哪種方式,您都需要在磁碟機分割後安裝它們。與 Windows 不同,Linux 檔案系統都是一棵樹,因此首先您需要決定將這些磁碟放在樹中的位置。 (例如,我有一個/data 目錄,我在其中掛載用於存儲個人資料的驅動器。)您可以使用mount 命令掛載驅動器,但它們不會在引導時自動掛載,除非您將它們列出在/etc/fstab 檔案。
答案2
只需格式化整個磁碟並將它們安裝到某個地方即可。
mkfs.ext3 /dev/sdb
mount /dev/sdb /var/www
ETC…
若要使安裝永久,請將行新增至/etc/fstab
:
/dev/sdb /var/www ext3 defaults
有很多變體,您應該查找更多資訊並了解不同的檔案系統等…以確保這就是您想要的。