您的位置:首页>>系统应用>>Unix/Linux>>阅读资讯:新手学堂:Linux操作系统下进行硬盘扩容本人硬盘扩容的步骤,注意:机器一定要先关机,然后在插硬盘,否则机器不是宕机就报一群IO错误。 字串8
1,启动机器后 按 F8 键进入阵列管理 先 view logical driver 看看自己实际存在的物理硬盘个数及其所占的端口,然后 careate logical driver 很据实际需要选择 radius[0] [0+1] [1],我选择radius[0],按 F8 存盘退出 注意: 如果创建错误 运行 delete logical driver 进行删除,最后重启机器 字串8
2,查看现有文件系统
字串9
df -k
字串7
文件系统 1K-块 已用 可用 已用% 挂载点 字串9
/dev/cciss/c0d0p1 98747 14994 78654 17% /boot
www.yueluo.net
/dev/cciss/c0d0p7 21525300 5074728 15357136 25% /home www.yueluo.net
/dev/cciss/c0d1p1 70009904 553120 65900456 1% /old www.yueluo.net
根据结果推荐 新增家物理设备在linux系统中的设备名,以上最到编号是 c0d1,由此我们可以推断新设备名称为 c0d2。 字串9
3,验证新设备名的准确性 字串8
sfdisk -l /dev/cciss/c0d2
字串5
Disk /dev/cciss/c0d2: 17433 cylinders, 255 heads, 32 sectors/track
sfdisk: ERROR: sector 0 does not have an msdos signature
月落
/dev/cciss/c0d2: unrecognized partition
月落网
4,对新设备进行分区
字串9
fdisk /dev/cciss/c0d2
字串5
Command action 月落网
a toggle a bootable flag www.yueluo.net
b edit bsd disklabel
c toggle the dos compatibility flag 字串6
d delete a partition www.yueluo.net
l list known partition types
m print this menu 月落网
n add a new partition
字串8
o create a new empty DOS partition table
字串7
p print the partition table 月落网
q quit without saving changes 字串7
s create a new empty Sun disklabel
t change a partition's system id
字串7
u change display/entry units
v verify the partition table yueluo.net
w write table to disk and exit yueluo.net
x extra functionality (experts only) yueluo.net
Command (m for help): n
月落
Command action 字串6
e extended
yueluo.net
p primary partition (1-4)
p
字串5
Partition number (1-4): 1 字串9
First cylinder (1-17433, default 1): 字串6
Using default value 1 字串6
Last cylinder or +size or +sizeM or +sizeK (1-17433, default 17433): 月落
Using default value 17433
yueluo.net
Command (m for help): w
字串9
The partition table has been altered! 字串9
5,给新分区的存储设备创建linux文件系统: mkfs -t ext3 /dev/cciss/c0d2p1
月落网
6, 把文件系统过载到新的目录: mount /dev/cciss/c0d2p1 /目录 月落
ok,到现在你的硬盘已经添加到系统,你可以使用的新硬盘了,空间好大,呵呵。
月落
注意:1,文件挂错了,可以用 umount /dev/cciss/c0d2p1 /目录 进行卸载
2,万一阵列管理程序找不见硬盘及其现有硬盘也不见了,那你新插入的盘一定是坏盘 哈哈 以上情况我全遇到了。 yueluo.net