[Solved] Question about space on SD card

I have Volumio running off of 8GB SDHC card on the RPi. I thought that Volumio automatically resized the SD card to its full capacity. Unfortunately, when I uploaded two albums to the SD card, it run out of space. Here is the output of the “df” command:

Filesystem 1K-blocks Used Available Use% Mounted on rootfs 1536680 1439072 0 100% / /dev/root 1536680 1439072 0 100% / devtmpfs 240208 0 240208 0% /dev tmpfs 49696 572 49124 2% /run tmpfs 5120 0 5120 0% /run/lock tmpfs 262144 0 262144 0% /run/shm /dev/mmcblk0p1 76186 18982 57204 25% /boot Ramdisk 262144 0 262144 0% /run/shm

All those volumes above do not tell me much. My mpd music collection is in /home/pi/music folder. Is there anything I have to do to the SC card or maybe I should be putting my music in a different location?

Hi there,

I had the same issue, the following instructions did the trick for me:


Thanks for the link. So in my case, the partition I need to resize is the /dev/mmcblk0p1, correct? Sorry for the noob question but I am Windowze guy. :slight_smile:

Ok first start fdisk

volumio@volumio:~$ sudo fdisk -c /dev/mmcblk0

Then type ‘p’ then enter this should give you something similar to this:

[code]Command (m for help): p

Disk /dev/mmcblk0: 16.0 GB, 16012804096 bytes
4 heads, 16 sectors/track, 488672 cylinders, total 31275008 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00043284

    Device Boot      Start         End      Blocks   Id  System

/dev/mmcblk0p1 * 2048 155647 76800 b W95 FAT32
/dev/mmcblk0p3 155648 31275007 15559680 83 Linux[/code]

In my case it’s partition 3 that I need to delete (because of the name mmcblk0p3 and it’s the linux partition). If you are unsure post the printout of the ‘p’ command. Write down the ‘Start cylinder’ of the partition you need to expand.

Delete the partition using the ‘d’ command, then enter your partition number

Command (m for help): d Partition number (1-4): 3

Create a new one by entering ‘n’ then press enter, ‘p’ since you want a primary partition, enter the same partition number you had before (in my case 3). Enter the first cylinder (the one you wrote down). then press enter. Press enter again to select the default cylinder (last one). It should look like this:

Command (m for help): n Partition type: p primary (1 primary, 0 extended, 3 free) e extended Select (default p): p Partition number (1-4, default 2): 3 First sector (155648-31275007, default 155648): 155648 Last sector, +sectors or +size{K,M,G} (155648-31275007, default 31275007): Using default value 31275007

Type ‘w’ to write the new partition table (this won’t modify the actual data on disk, just the information for each partition, so if you keep the printout from the beginning you can always recover using a linux live cd and performing the same steps)

Reboot the Pi, run the following command (make sure to match the partition number you created):

sudo resize2fs /dev/mmcblk0p3

Let me know how it goes!

Thanks Larzon! That worked like a charm. I have tried it before your post but I was deleting partition 3 and creating partition #2. That always screwed up my file system and RPi was not bootable anymore.

I thank you too! Good procedure, I am sure it has helped many people.

Thank you Larzon! I have only had my Raspberry Pi + Volumio for one night, but I think its great, I just wish there was a Wiki somewhere to answer simple questioins.

So I have followed the partition resize procedure, and my /dev/mmcblk0p3 partition went from 1,628,160 blocks to 15,480,320 blocks. What would be the best approach to use that to store music files? I understand that I should create a music folder, and then a sym link to it from where the RAMDISK is? Should I put a sym link inside the RAMDISK folder, or change the RAMDISK to point to the new music folder?