zoukankan      html  css  js  c++  java
  • lv resize

    # lvreduce -L -400G /dev/vg_atalinux001/lv_home

    # resize2fs   /dev/vg_atalinux001/lv_home

    resize2fs 1.41.12 (17-May-2010)

    Filesystem at /dev/vg_atalinux001/lv_home is mounted on /home; on-line resizing required

    On-line shrinking from 107852800 to 2995200 not supported.


    # umount /home

    # resize2fs   /dev/vg_atalinux001/lv_home

    resize2fs 1.41.12 (17-May-2010)

    Please run 'e2fsck -f /dev/vg_atalinux001/lv_home' first.

    # e2fsck -f /dev/vg_atalinux001/lv_home

    一通回车之后就挂了...

    # mount -a

    mount: wrong fs type, bad option, bad superblock on /dev/mapper/vg_atalinux001-lv_home,

           missing codepage or helper program, or other error

           In some cases useful info is found in syslog - try

           dmesg | tail  or so

    # tail /var/log/messages 

    Dec 12 11:09:54 ata-linux-001 kernel: dm-2: rw=1217, want=428081160, limit=23961600

    Dec 12 11:09:54 ata-linux-001 kernel: Buffer I/O error on device dm-2, logical block 53510144

    Dec 12 11:09:54 ata-linux-001 kernel: lost page write due to I/O error on dm-2

    Dec 12 11:09:54 ata-linux-001 kernel: JBD2: I/O error detected when updating journal superblock for dm-2-8.

    Dec 12 11:09:54 ata-linux-001 kernel: attempt to access beyond end of device

    Dec 12 11:09:54 ata-linux-001 kernel: dm-2: rw=1217, want=428081160, limit=23961600

    Dec 12 11:09:54 ata-linux-001 kernel: Buffer I/O error on device dm-2, logical block 53510144

    Dec 12 11:09:54 ata-linux-001 kernel: lost page write due to I/O error on dm-2

    Dec 12 11:09:54 ata-linux-001 kernel: JBD2: I/O error detected when updating journal superblock for dm-2-8.

    Dec 12 11:14:19 ata-linux-001 kernel: EXT4-fs (dm-2): bad geometry: block count 107852800 exceeds size of device (2995200 blocks)


    # mkfs.ext4 /dev/vg_atalinux001/lv_home

    之后好了。


     lvreduce 需谨慎使用呀,使用前把数据要全拷贝出来才安全。


  • 相关阅读:
    编程实现SQL Server数据库导入导出操作
    C#正则表达式入门
    Winform实现窗体抖动的效果代码
    js获取当前日期,格式为YYYYMMDD
    XML基本知识及其技术指南
    WPF学习心得
    脚本调试
    标题:VS2008简体中文专业版
    使用 XML Schema 定义元素的基本知识2
    C#操作xml文件入门
  • 原文地址:https://www.cnblogs.com/storymedia/p/4436084.html
Copyright © 2011-2022 走看看