1.查看主机现有磁盘情况 # fdisk -l 现在主机中存在一块8G的磁盘sdb,尚未分区挂载,所以需将磁盘进行分区挂载. 2.对磁盘进行分区 # fdisk /dev/sdb (选择要操作分区的磁盘) Command (m for help): m (查看操作帮助) Command (m for help): p (打印磁盘现有分区情况) Command (m for help): n (新建一个分区) p (输入P建立分区) 分区
创建LVM分区 shell> fdisk /dev/xvdb #### 选择磁盘 Command (m for help): m #### 帮助 Command action a toggle a bootable flag b edit bsd disklabel c toggle the dos compatibility flag d delete a partition l list known partition types m print this menu n add a new