Linux 命令【8】:ssm

一、简介


用于检查关于可用硬驱和LVM卷的信息。显示关于现有磁盘存储设备、存储池、LVM卷和存储快照的信息。

二、命令详解


安装

yum -y install system-storage-manager

三、常用实例演示


3.1 查看

# 显示物理设备、存储池、存储池中的LVM卷的详细信息
ssm list
# 显示存储设备
ssm list dev
# 显示vg卷组
ssm list pool
# 显示lvm卷组
ssm list vol

3.2 添加磁盘到VG中扩容

[root@localhost ~]# ssm add -p vg00 /dev/sdd
 Physical volume "/dev/sdd" successfully created
 Volume group "vg00" successfully extended

3.3 LVM卷扩容

[root@localhost ~]# ssm resize -s +10G /dev/vg00/lv00
fsck,来自 util-linux 2.23.2
/dev/mapper/vg00-lv00: 11/65536 files (0.0% non-contiguous), 4763/262144 blocks
 Extending logical volume lv00 to 11.00 GiB
 Logical volume lv00 successfully resized
resize2fs 1.42.9 (28-Dec-2013)
Resizing the filesystem on /dev/mapper/vg00-lv00 to 2883584 (4k) blocks.
The filesystem on /dev/mapper/vg00-lv00 is now 2883584 blocks long.

3.4 创建新的VG

[root@localhost ~]# mkdir /soft
[root@localhost ~]# ssm create -s 1G -n soft --fstype xfs -p mysoft /dev/sde /soft 
//create创建、-s 1G指定大小、-n soft文件名称、--fstype xfs文件系统、-p mysoft指定VG名称、/dev/sde /soft指定那块磁盘挂载哪个目录上
 Physical volume "/dev/sde" successfully created
 Volume group "mysoft" successfully created
 Logical volume "soft" created
meta-data=/dev/mysoft/soft    isize=256  agcount=4, agsize=65536 blks
     =            sectsz=512  attr=2, projid32bit=1
     =            crc=0
data   =            bsize=4096  blocks=262144, imaxpct=25
     =            sunit=0   swidth=0 blks
naming  =version 2       bsize=4096  ascii-ci=0 ftype=0
log   =internal log      bsize=4096  blocks=2560, version=2
     =            sectsz=512  sunit=0 blks, lazy-count=1
realtime =none          extsz=4096  blocks=0, rtextents=0

3.5 删除LVM卷

[root@localhost ~]# ssm remove /dev/mysoft/soft
Device '/dev/mysoft/soft' is mounted on '/soft' Unmount (N/y/q) ? Y
Do you really want to remove active logical volume snap20160531T120543? [y/n]: y
 Logical volume "snap20160531T120543" successfully removed
Do you really want to remove active logical volume soft? [y/n]: y
 Logical volume "soft" successfully removed

3.6 删除VG

[root@localhost ~]# ssm remove mysoft
 Volume group "mysoft" successfully removed
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值