liunx 硬盘分区

第一步:分区  fdisk /dev/sdb

         

命令(输入 m 获取帮助):m
命令操作
a toggle a bootable flag
b edit bsd disklabel
c toggle the dos compatibility flag
d delete a partition
g create a new empty GPT partition table
G create an IRIX (SGI) partition table
l list known partition types                               查看
m print this menu
n add a new partition                                        新建
o create a new empty DOS partition table
p print the partition table
q quit without saving changes                              退出不保存
s create a new empty Sun disklabel
t change a partition's system id
u change display/entry units
v verify the partition table
w write table to disk and exit                                保存退出
x extra functionality (experts only)

第二步:格式化

mkfs.类型 【-b#指定指定block大小】  /dev/sdb1    #mkfs.类型 --help可以看-b需不需要要size  

三:分区不能直接使用、需要挂载

mount     /dev/sdb1     /dir01  #可以-t选择类型

 

yum   whatprovides   mkfs.fat     #查询安装包

posted @ 2017-04-06 21:01  疯狂的鱼摆摆  阅读(214)  评论(0)    收藏  举报