# [Walkthrough] Resizing Partitions



## ivanmmj (Oct 13, 2011)

Here's a walkthrough on how I removed the Ubuntu Chroot partition and merged it back to my SD partition. I'm going to try to remove the SWAP and WebOS partitions later on, too.

WARNING: I do not take any responsibility for anything going wrong.

Step 0: Always back up. You never know when something may go wrong.

Step 1: Boot into WebOS.
Step 2: Load Novaterm

Step 3: Unmount the Ubuntu Chroot partition.

```
# umount /dev/mapper/store-ext3fs
```
Step 4: Remove the partition.

```
# lvremove /dev/mapper/store-ext3fs
```
Step 5: Unmount anything else we need.


```
# pkill -SIGUSR1 cryptofs<br />
# umount /media/cryptofs<br />
# mount | grep cryptofs<br />
# umount /media/internal<br />
# mount | grep internal
```
Step 6: Resize the logical volume to fill the void.


```
# lvresize -l +100%FREE /dev/mapper/store-media
```
Step 7: View the size of your logical partition.


```
<br />
# lvscan<br />
ACTIVE '/dev/store/root' [568.00 MB] inherit<br />
ACTIVE '/dev/store/var' [64.00 MB] inherit<br />
ACTIVE '/dev/store/update' [16.00 MB] inherit<br />
ACTIVE '/dev/store/log' [24.00 MB] inherit<br />
ACTIVE '/dev/store/mojodb' [256.00 MB] inherit<br />
ACTIVE '/dev/store/filecache' [136.00 MB] inherit<br />
ACTIVE '/dev/store/media' [27.63 GB] inherit<br />
ACTIVE '/dev/store/swap' [400.00 MB] inherit<br />
```
Take note of the 27.63 GB next to /dev/store/media as this is important to the next step.

Step 8: Resize the media partition to take the rest of the logical partition.

```
# resizefat /dev/mapper/store-media 26G
```
MAKE SURE that the size (26G in this case) is SMALLER than the size that was listed above. Make sure it's formatted as number and capital G (not GB) with NO space in between.

That's it. Reboot, you're done.

Resources:
http://www.webos-internals.org/wiki/Application:MetaDoctor
http://forums.precentral.net/hp-touchpad/301330-touchpad-missing-disk-space-after-botched-ubuntu-install.html#post3181997


----------

