Eric H. Johnson on 31 Jan 2013 18:12:05 -0800 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: [PLUG] Using resize2fs |
Rich, Thanks, that is basically what I thought. It does not have LVM. I am trying to get Debian / Ubuntu running on an Olinuxino (sort of like a RPi). The first step was to just get a stock OS running. It isn't all that important to expand to the size of the SD since I will need to build my own kernel / distro anyway. It just sounded like it should be easy. Thanks, Eric Sent from my ASUS Pad Rich Freeman <r-plug@thefreemanclan.net> wrote: >On Thu, Jan 31, 2013 at 8:15 PM, Eric H. Johnson ><ejohnson@camalytics.com> wrote: >> I have tried this both when mounted to another Linux computer and after booting to the SD. In both cases it basically says "nothing to do". If I give it a size of 15G it says only so many blocks are available and I asked for a whole lot more. >> >> How do I expand the 3.9GB partition to use the remainder of the SD without losing data? > >Might not hurt to give actual commands and responses, as it is easy to >miscommunicate. Include: >fdisk -l >df -h (with the partition mounted) > >That said, your first issue is that your filesystem can't be bigger >than the partition it is on, and that is only 4GB. So, you first need >to edit the partition table to extend the partition to fill the >remaining space. Something like qtparted can probably do the job - or >you can just delete and re-create the partition but if you do this you >MUST make sure the starting position is the same. Oh, and don't do >this part with the filesystem mounted (unless you're using LVM). > >Once the partition is resized then just run resize2fs <device> and it >will be resized to the full size of the partition. This part can run >while mounted, but I'd avoid that if you can just the same. > >With LVM all this stuff is a breeze - you can grow, shrink, as much as >you want with everything online. > >Oh, be aware that ext2/3/4 have a fixed number of inodes at filesystem >creation - so unless it was created with an unusually large number of >inodes you can't resize more than a few orders of magnitude before you >run out of them. If you're storing digital video or something that >isn't a big deal, but if you're storing lots of small files it >definitely is one (in fact, on small filesystems even the defaults can >be pretty sparse on inodes). That is one of the benefits of btrfs - >everything is dynamic. > >Rich >___________________________________________________________________________ >Philadelphia Linux Users Group -- http://www.phillylinux.org >Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce >General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug > ___________________________________________________________________________ Philadelphia Linux Users Group -- http://www.phillylinux.org Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug