
2、2、用fdisk对这块硬盘分区fdisk /dev/sdb(sdb代指新硬盘盘符,有可能是别的)
3、3、按下m显示分区命令菜单,可以用m命令来看fdisk命令的内部命令;n命令创建一个新分区;d命令删除一个存在的分区;p命令显示分区列表;t命令修改分区的类型ID号;l命令显示分区ID号的列表;a命令指定启动分区;w命令是将对分区表的修改存盘让它发生作用。
4、我们这里是创建新分区,所以输入 n 然后 e 是扩展分区,p 是主分区,我们输入 p
5、接下来的块数什么的,都输入 1 ,最后选择大小,Last cylinder or +size or +sizeM or +sizeK (1-60801, default 60801): +500GB //我们输入这个意思是分区大小为500G
6、最后输入 w 保存。
每个扇区大小为0, 一共350个柱面,起始柱面是1000,扇区数量300.详细如下:
fdisk [-uc] [-b sectorsize] [-C cyls] [-H heads] [-S sects] device
-b sectorsize
Specify the sector size of the disk. Valid values are 512, 1024, 2048 or 4096. (Recent kernels know the sector size. Use this only on old kernels or to override the kernel's ideas.) Since util-linux-2.17, fdisk differentiates between logical and physical sector size. This option changes both sector sizes to sectorsize.
-c[=mode]
Specify the compatiblity mode, 'dos' or 'nondos'. The default is non-DOS mode. For backward compatibility, it is possible to use the option without the <mode>argument -- then the default is used. Note that the optional <mode>argument cannot be separated from the -c option by a space, the correct form is for example '-c=dos'.
-C cyls
Specify the number of cylinders of the disk. I have no idea why anybody would want to do so.
-H heads
Specify the number of heads of the disk. (Not the physical number, of course, but the number used for partition tables.) Reasonable values are 255 and 16.
-S sects
Specify the number of sectors per track of the disk. (Not the physical number, of course, but the number used for partition tables.) A reasonable value is 63.
linux分区的方案是:1、第一个分区是boot分区,安装 *** 作系统,一般200M即可;
2、第二个分区是swap分区,虚拟内存;
3、第三个分区是,分区,一般所有文件都放在根目录下。
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)