zoukankan      html  css  js  c++  java
  • LVM扩容

    在线扩容

    [root@liujunjun ~]# df -h
    文件系统                        容量  已用  可用 已用% 挂载点
    devtmpfs                        384M     0  384M    0% /dev
    tmpfs                           400M     0  400M    0% /dev/shm
    tmpfs                           400M  5.8M  394M    2% /run
    tmpfs                           400M     0  400M    0% /sys/fs/cgroup
    /dev/mapper/cl-root              19G  1.4G   18G    8% /
    /dev/sda1                       283M  126M  139M   48% /boot
    tmpfs                            80M     0   80M    0% /run/user/0
    /dev/mapper/vgtest-vgtest_LV01   30G  247M   30G    1% /data
    [root@liujunjun ~]# lvextend -L 35G /dev/vgtest/vgtest_LV01 
    [root@liujunjun ~]# lvdisplay 
      --- Logical volume ---
      LV Path                /dev/vgtest/vgtest_LV01
      LV Name                vgtest_LV01
      VG Name                vgtest
      LV UUID                62qwnI-NGDT-Cvat-ahw1-Kzvf-qfgT-fOcDYR
      LV Write Access        read/write
      LV Creation host, time liujunjun, 2020-12-13 06:48:47 -0500
      LV Status              available
      # open                 1
      LV Size                35.00 GiB
      Current LE             8960
      Segments               2
      Allocation             inherit
      Read ahead sectors     auto
      - currently set to     8192
      Block device           253:2
    [root@liujunjun ~]# xfs_growfs /dev/vgtest/vgtest_LV01
    meta-data=/dev/mapper/vgtest-vgtest_LV01 isize=512 agcount=4, agsize=1966080 blks
    = sectsz=512 attr=2, projid32bit=1
    = crc=1 finobt=0 spinodes=0
    data = bsize=4096 blocks=7864320, imaxpct=25
    = sunit=0 swidth=0 blks
    naming =version 2 bsize=4096 ascii-ci=0 ftype=1
    log =internal bsize=4096 blocks=3840, version=2
    = sectsz=512 sunit=0 blks, lazy-count=1
    realtime =none extsz=4096 blocks=0, rtextents=0
    data blocks changed from 7864320 to 9175040
    [root@liujunjun ~]# df -h
    文件系统 容量 已用 可用 已用% 挂载点
    /dev/mapper/centos-root 19G 1.8G 18G 10% /
    devtmpfs 475M 0 475M 0% /dev
    tmpfs 487M 0 487M 0% /dev/shm
    tmpfs 487M 7.7M 479M 2% /run
    tmpfs 487M 0 487M 0% /sys/fs/cgroup
    /dev/sda1 197M 111M 87M 56% /boot
    tmpfs 98M 0 98M 0% /run/user/0
    /dev/mapper/vgtest-vgtest_LV01 35G 33M 35G 1% /data
    [root@liujunjun ~]#
    resize2fs /dev/vg01/lv02        #此为ext分区格式的重载大小
  • 相关阅读:
    iOS截取http/https流量
    Jenkins拾遗--第五篇-git插件填坑
    Jenkins拾遗--第三篇(用户权限管理)
    Jenkins拾遗--第四篇-适当的让构建失败
    Jenkins拾遗--第二篇(初步配置Jenkins)
    Jenkins拾遗--第一篇(安装Jenkins)
    一个测试人员的2015的回顾和2016年展望
    xcode升级导致git无法使用
    在intellj idea下用sbt的坑
    本人已转战知乎,此处不玩了。
  • 原文地址:https://www.cnblogs.com/liujunjun/p/14129982.html
Copyright © 2011-2022 走看看