27

I'm using an 8GB SD card and installed Raspbian which is 3.9GB large. I suppose that about 4GB should be available, but it isn't. When I type 'df -ah' on my Raspberry pi, it shows

enter image description here

Only 65MB is available....

And this is diskutil list on my Mac OS X

enter image description here

And I did not install nothing but open-ssh..and vim..

user3595632
  • 403
  • 5
  • 7

2 Answers2

42

It appears that you have not yet expanded your file system.

  1. Run sudo raspi-config.
  2. Select Expand Filesystem (the first option at the time of this writing), and follow the instructions.

After rebooting the system you should have significantly more space available.

Jacobm001
  • 11,898
  • 7
  • 46
  • 56
  • Is my assumption correct that there is actually more than 65MB available, but that it's only showing 1 partition (i.e. the FAT32 partition)? – BlueCacti Jan 28 '16 at 13:02
  • 2
    @GroundZero Yes. The image that was written to the SD card was of a certain size and contains a filesystem that "knows" this. When the image is written to the larger SD card it is written "as is" and is not expanded because that is best done from within the Raspian OS itself. That is what is done via the 1st menu-option in raspi-config. Most Raspian "getting started" manuals cover this .... The poster must have missed that. – Tonny Jan 28 '16 at 15:08
  • @GroundZero: I started to edit my answer to address your question, but it's honestly another question entirely. If you post your comment as a question, I'd be happy to give you a detailed answer. In short, Tonny is correct. – Jacobm001 Jan 28 '16 at 18:05
  • @Jacobm001 Thanks but that won't be necessary. I just wanted to confirm my thoughts on this. The reason that the OS only shows 65MB is because it's only showing the size of the FAT32 partition. Which doesn't necessarily mean that there's only 65MB available. Any other filesystem that is readable to the host, would show up seperately – BlueCacti Jan 29 '16 at 08:15
  • 1
    @MarkBooth: decent point. I have updated the answer accordingly. – Jacobm001 Feb 08 '16 at 17:08
7

Option 1:

Step 1: If this isn't a fresh install, back up your data.

Step 2: Run the command: sudo raspi-config

Step 3: Choose the option "Expand Filesystem" from the menu.

Option 2:

Step 1: Back up your data

Step 2: Put the SD card in to your PC/Mac and expand the main partition

Step 3: Put your data back on the SD card

Mark Booth
  • 4,360
  • 2
  • 29
  • 42
reeddeer
  • 71
  • 1