Integer
Posts: 3
Joined: Sun Mar 06, 2016 9:28 am

Not booting after no space on SD Card

Sun Mar 06, 2016 9:50 am

I'm having some big troubles with my Pi 2 type B right now.
I'm not very skilled in Linux, but after many weekends my Pi finally worked the way I wanted. Then I did an apt-get update and upgrade and the problems started.
During the upgrade i got multiple errors, saying that there was no space left on my sd-card. So some of the updates failed. After that the auto-completion in the shell didn't work, also with the error that there is no space left. I could still change directory and execute commands. I didn't store anything on the sd-card besides configuration files so I didn't know what do delete. So I restarted the Pi, hoping that would clear some temporary files.

And the Pi didn't boot anymore. No SSH, no Video output. The Act-Led isn't flashing. Act and Power Led are just bright.
I tried accessing the SD-Card with my Mac, but the Mac only detected the boot partition.

So what now?
Is my SD-Card broken, or is my mac not capable of reading the file system? Is the SD-Card full and the Pi doesn't boot because of that? Can I save some of the Configuration files I edited?

I hope someone can help me out.

fruitoftheloom
Posts: 23337
Joined: Tue Mar 25, 2014 12:40 pm
Location: Delightful Dorset

Re: Not booting after no space on SD Card

Sun Mar 06, 2016 9:35 pm

Integer wrote:I'm having some big troubles with my Pi 2 type B right now.
I'm not very skilled in Linux, but after many weekends my Pi finally worked the way I wanted. Then I did an apt-get update and upgrade and the problems started.
During the upgrade i got multiple errors, saying that there was no space left on my sd-card. So some of the updates failed. After that the auto-completion in the shell didn't work, also with the error that there is no space left. I could still change directory and execute commands. I didn't store anything on the sd-card besides configuration files so I didn't know what do delete. So I restarted the Pi, hoping that would clear some temporary files.

And the Pi didn't boot anymore. No SSH, no Video output. The Act-Led isn't flashing. Act and Power Led are just bright.
I tried accessing the SD-Card with my Mac, but the Mac only detected the boot partition.

So what now?
Is my SD-Card broken, or is my mac not capable of reading the file system? Is the SD-Card full and the Pi doesn't boot because of that? Can I save some of the Configuration files I edited?

I hope someone can help me out.
Operating System you are using on the RPi ?

If Standalone Jessie (without using NOOBS) did you expand file system as first task on first boot up ??
Rather than negativity think outside the box !
RPi 4B 4GB (SSD Boot)..
Asus ChromeBox 3 Celeron is my other computer...

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: Not booting after no space on SD Card

Sun Mar 06, 2016 10:34 pm

Integer wrote: there was no space left on my sd-card. So some of the updates failed. After that the auto-completion in the shell didn't work,
[comments are kind of out of order for what you might want to do]
If this happens, you really are out of space, including I think the extra reserved for the system. Perhaps that isn't true though if tab completion is failing just for a normal user. Try doing it after switching to root.

I can't test this because, well, I know I have machines that are close to full but nothing is completely full right now and I'd avoid that because upgrades could mess up the system itself. I wish that apt-get would just tell you there isn't any more space and stop, instead it just keeps going and who knows what it remembers it needs to do whenever you get space back.
sd-card besides configuration files so I didn't know what do delete. So I restarted the Pi, hoping that would clear some temporary files.
If you can eventually get it to boot, try:

sudo apt-get clean

which will remove cache stuff from deep in the /var dir. You might also try:

sudo apt-get autoremove

which may or may not find some extra stuff that it thinks isn't currently needed. Even if you are planning on using it, but have done nothing with it yet, you might remove the wolfram engine with:

sudo apt-get remove wolfram-engine

After that, you need to enlarge your partition as the other poster suggests using the raspi-config program.
And the Pi didn't boot anymore. No SSH, no Video output. The Act-Led isn't flashing. Act and Power Led are just bright.
I tried accessing the SD-Card with my Mac, but the Mac only detected the boot partition.
It doesn't have any way to mount the ext4 formatted partition that holds all the stuff you want to fix. There may be a way to do this but I don't have a Mac that is current enough to test anything.
that? Can I save some of the Configuration files
I edited?
Ideally someone who doesn't have a Linux box with an sdcard reader would have a USB sdcard reader they could attach to their pi. Then they would boot via another sdcard in the card holder and mount the old card to edit it. Failing that, it would be nice to have a version of Linux that booted to ram and allowed its sdcard to be removed. One example of that is Tiny Core Linux.

I would take the sdcard out of the system and then find some other sdcards, specifically even a very small one such as a 128meg would work for Tiny Core, and something at least 2gig for the lite version of Raspbian Jessie.

I just tested this with Tiny Core. If you boot to a prompt and make sure that the drive itself is no longer mounted, you can remove it and put in a different sdcard. Then you can mount this card and see what is going on, hopefully your card still mounts right.

asandford
Posts: 1998
Joined: Mon Dec 31, 2012 12:54 pm
Location: Waterlooville

Re: Not booting after no space on SD Card

Mon Mar 07, 2016 12:11 am

The latest image leaves very little room for doing anything. Your best option is to image the card again and expand the filesystem once it boots. If apt gets 'confused', it can be very hard to get it back to a 'sane' state (it silently fails if you try the updates on an unexpanded image).

Integer
Posts: 3
Joined: Sun Mar 06, 2016 9:28 am

Re: Not booting after no space on SD Card

Mon Mar 07, 2016 10:34 am

fruitoftheloom wrote: Operating System you are using on the RPi ?

If Standalone Jessie (without using NOOBS) did you expand file system as first task on first boot up ??
I'm using raspbian Jessie. And no, I didn't expand the file system.

I brought my pi with me at work today. With a colleague we expanded the size of the Linux partition on the SD-Card.
Before doing that, he wanted to make a backup of my files. But instead of copying the data, he deleted the home directory from the user Pi.... :shock:

Now the Partition is expanded, but the Pi still isn't booting. No Act-LED, no HDMI output.
Is the home directory essential for booting?

User avatar
RaTTuS
Posts: 10559
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
Contact: Twitter YouTube

Re: Not booting after no space on SD Card

Mon Mar 07, 2016 10:43 am

reflash a new jessie image and start again
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

Integer
Posts: 3
Joined: Sun Mar 06, 2016 9:28 am

Re: Not booting after no space on SD Card

Mon Mar 07, 2016 2:29 pm

RaTTuS wrote:reflash a new jessie image and start again
So no chance of reviving the Pi?
At least i could save some of my configuration files...

Next time I will do a backup :lol:

User avatar
GTR2Fan
Posts: 1601
Joined: Sun Feb 23, 2014 9:20 pm
Location: South East UK

Re: Not booting after no space on SD Card

Mon Mar 07, 2016 2:35 pm

Integer wrote:Next time I will do a backup :lol:
Yep. Making a backup by writing to it should do the trick. D'oh! Reading from it. :lol:

At the risk of some members accusing me of sounding like a broken record, you could make a backup with rpi-clone. I wrote a guide to using it and creating a handy shortcut launcher here...

viewtopic.php?f=29&t=137693&p=914109#p914109

The clone of my 32GB card (which is mostly empty) fits nicely on an old 8GB card that's too slow to be of much use for anything else. :)
Pi2B Mini-PC/Media Centre: ARM=1GHz (+3), Core=500MHz, v3d=500MHz, h264=333MHz, RAM=DDR2-1200 (+6/+4/+4+schmoo). Sandisk Ultra HC-I 32GB microSD card on '50=100' OCed slot (42MB/s read) running Raspbian/KODI16, Seagate 3.5" 1.5TB HDD mass storage.

Return to “Troubleshooting”