VM虚拟机中Linux扩展磁盘空间的方法

转载自:http://blog.csdn.net/liangliangdetianxia/article/details/37527767

一、Vm虚拟机下Linux扩展原有磁盘空间,详细步骤如下:
这里写图片描述

这里写图片描述
需注意以下几点: linux只能扩展磁盘容量而不能减小, 所填写的容量为总容量,即包含已分区的磁盘, 扩展容量时不能有快照哟,大家可以先把快照删除掉。
2.启动Linux,查看系统分区,并创建分区sda3,命令如下:红色字体命令,#后为注释:
[root@localhost~]#fdisk -l
Disk /dev/sda:32.2GB,32212254720 bytes
255heads,63sectors/track,3916cylinders
Units=cylindersof16065*512=8225280 bytes
DeviceBoot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 1566 12474472+ 8e Linux LVM

我的电脑有2个分区-sda1 sda2

[root@localhost~]#fdisk /dev/sda
Thenumberofcylindersforthisdiskissetto3916.
Thereisnothingwrongwiththat,butthisislargerthan1024,
andcouldincertainsetupscauseproblemswith:
1)softwarethatrunsatboottime(e.g.,oldversionsofLILO)
2)bootingandpartitioningsoftwarefromotherOSs
(e.g.,DOSFDISK,OS/2FDISK)
Command(mforhelp):m
Commandaction
a toggle a bootable flag
b edit bsd disk label
c toggle the dos compatibility flag
d delete a partition
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 apartition’s system id
u change display/entry units
v verify the partition table
w write table to disk and exit
x extra functionality (expertsonly)
这里写图片描述

这里写图片描述

这里写图片描述

这里写图片描述

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值