# LVM2 lvextend doesn't give more space to use

## jyaan

Is there something I'm doing wrong? I used the command 

```
lvextend -L+10G /dev/vg/home
```

 and it says the partition was extended successfully. Problem is, I don't actually get any extra space to use. I've resized my /home partition to 40G, but I only have about 5G accessible! lvdisplay reports the size I should have, but df reports otherwise. 

```
gentoo jyaan # lvdisplay /dev/vg/home

  --- Logical volume ---

  LV Name                /dev/vg/home

  VG Name                vg

  LV UUID                CLdc8K-Imyj-S8fs-ctpA-G2mw-UAdH-Py3hU5

  LV Write Access        read/write

  LV Status              available

  # open                 1

  LV Size                41.00 GB

  Current LE             10496

  Segments               3

  Allocation             inherit

  Read ahead sectors     auto

  - currently set to     256

  Block device           253:1

   

```

----------

## scherz0

After extending the LV, you need to extend the FS also, since this is not automatic.

The command to use depends on the fs type.  For example, see resize_reiserfs to extend a (mounted) reiser fs.

----------

## jyaan

Oh, I'm using ext3. So the command is resize2fs? Can this be done on a live fs, or do I need to unmount?

----------

## drescherjm

 *Quote:*   

> So the command is resize2fs? 

 

Yes.

 *Quote:*   

> Can this be done on a live fs

 

Yes

----------

## jyaan

Thank you very much! It's working perfectly now.  :Smile: 

Closed.

----------

## szatox

I will have to resize root partition with ext3 on lvm on device mapper, and... well, is it actually safe?

I have 2 options, I can either "just do it" or diassemble raid, do whatever is nessesery on the other drive, reboot to the new system and rebuild raid. In first case downside is if anything goes wrong I have to reinstall, in second case no matter what happens I have to rebuild raid.

So, question is: what can go wrong while I'm *extending* *mounted* *root* *ext3* filesystem on *lvm*?

Creating filesystem takes only a few seconds, will resize also be this fast?

If resize is interrupted due to any reasons, does it mean data lose and broken system?

Is it possible for resize2fs to simply screw up filesystem for no particular reason? (e.g. without hardware/power failure)

----------

## drescherjm

You can just resize the root. It is safe to expand a live ext2/3/4. And yes it will be fast.

----------

## szatox

Thanks, it seems it did go smoothly indeed

----------

