Jul 28

磁碟转载鸟哥私房菜之叁拾第捌章linux磁碟与档磁碟

Posted by liuxu at 13:51 | 电脑教程 | 评论(0) | 阅读(24) | 转自 本站原创 | |
磁碟  大年夜  号码  画面  主动  方才  开端  硬碟  系统  时分  局部  乾净  保守  状况  两个  中央  有的  方法  假定  区间  软体  滑稽  按键  最接近  装置  逻辑  害怕  容量  多种  位置  继续  全部  数字  结果  测试  资料  资讯
Zhuan∴Zai∴Niao∴Ge∴Si∴Fang∴Cai∴Zhi∴San∴Shi∴Di∴Ba∴Zhang∴linuxCi∴Die∴Yu∴Dang假设妳是依照鸟哥倡议的方法往装置妳的 CentOS !那麼妳的磁碟该当会预留壹块容量来做训练的 实践训练新增硬碟之前!我们先来玩壹玩害怕的增除好了假设想要测试壹下若何将妳的 /dev/hdc 局部的联系槽增除!该当怎麼做
fdisk /dev/hdc 保守进 fdisk 画面
p 先看壹下联系槽的资讯!假定要杀掉落 /dev/hdc1
d 这个时分会要妳挑选壹个 partition !就选 1 罗
w  q 按 w 可贮存到磁碟资料表中!并合并 fdisk 固然罗! 假设妳反悔了!呵呵!间接按下 q 就可以够撤消方才方才的增除举动了
训练壹 保守进 fdisk 的画面傍边往
rootwww  fdisk /dev/hdc
训练贰 先看看全部联系表的状况是若何
Command : p
Disk /dev/hdc: 41.1 GB! 41174138880 bytes
255 heads! 63 sectors/track! 5005 cylinders
Units = cylinders of 16065  512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdc1  1 13 104391 83 Linux
/dev/hdc2 14 1288 10241437+ 83 Linux
/dev/hdc3 1289 1925 5116702+ 83 Linux
/dev/hdc4 1926 5005 24740100 5 Extended
/dev/hdc5 1926 2052 1020096 82 Linux swap / Solaris
训练叁 按下 d 给他增除吧
Command : d
Partition number : 4
Command : d
Partition number : 3
Command : p
Disk /dev/hdc: 41.1 GB! 41174138880 bytes
255 heads! 63 sectors/track! 5005 cylinders
Units = cylinders of 16065  512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdc1  1 13 104391 83 Linux
/dev/hdc2 14 1288 10241437+ 83 Linux
因为 /dev/hdc5 是由 /dev/hdc4 所衍生出现的逻辑联系槽!因此 /dev/hdc4 被增除!
/dev/hdc5 就主动不见了终究就会剩下两个联系槽罢了喔
Command : q
鸟哥这里仅是做壹个训练罢了!所以!按下 q 就可以够合并罗
新增磁碟联系槽有好多种状况!因为新增 Primary / Extended / Logical 的浮现结果都不太相同 底下我们先将 /dev/hdc 局部增除成为乾净未联系的磁碟!然后依序新增给大年夜家瞧瞧
训练壹 进进 fdisk 的联系软体画面中!并增除壹切联系槽
rootwww  fdisk /dev/hdc
Command : d
Partition number : 4
Command : d
Partition number : 3
Command : d
Partition number : 2
Command : d
Selected partition 1
由於最后仅剩下壹个 partition !因此系统主动拔取这个 partition 增除往
训练贰 开端新增!我们先新增壹个 Primary 的联系槽!且指定为 4 号看看
Command : n
Command action lt。==因为是全新磁碟!因此只会问extended/primary罢了
e extended
p primary partition  
plt。==挑选 Primary 联系槽
Partition number : 4lt。==设定为 4 号
First cylinder : lt。==间接按下enter按键决定
Using default value 1 lt。==启始磁柱就选用预设值
Last cylinder or +size or +sizeM or +sizeK : +512M
这个中央滑稽了我们知道 partition 是由 n1 到 n2 的磁柱号码 !
但磁柱的大年夜小每颗磁碟都不相同!这个时分能够填进 +512M 来让系统主动帮我们找出
最接近 512M 的阿谁 cylinder 号码因为不克不及够方才好等於 512MBytes 啦
如上所示这个中央输进的方法有两种
1) 间接输进磁柱的号码!妳得要自己盘算磁柱/联系槽的大年夜小才行
2) 用 +XXM 来输进联系槽的大年夜小!让系统自己捉磁柱的号码
+与M是必须要有的!XX为数字
Command : p
Disk /dev/hdc: 41.1 GB! 41174138880 bytes
255 heads! 63 sectors/track! 5005 cylinders
Units = cylinders of 16065  512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/hdc4 1 63 506016 83 Linux
留心只要 4 号 1  3 保管上往了
训练叁 继续新增壹个!此次我们新增 Extended 的联系槽好了
Command : n
Command action
e extended
p primary partition  
elt。==挑选的是 Extended 喔
Partition number : 1
First cylinder : lt。=enter
Using default value 64
Last cylinder or +size or +sizeM or +sizeK : lt。=enter
Using default value 5005
还记得我们正在第叁章的磁碟联系表曾经谈到过的!延长联系最好能够包含壹切
未联系的区间所以正在这个训练中!我们将壹切未建设的磁柱都给了这个联系槽喔
所以正在开端/完毕磁柱的位置上!按下两个enter用预设值便可假设妳是依照鸟哥倡议的方法往装置妳的 CentOS !那麼妳的磁碟该当会预留壹块容量来做训练的 实践训练新增硬
刘旭 ' blog  http://www.liuxu.info
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   游客无需密码
网址   电邮   [注册]