LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 12-01-2015, 11:46 PM   #1
tmick
Member
 
Registered: Jun 2005
Location: North Dakota
Distribution: Debian Testing
Posts: 247

Rep: Reputation: 20
Unhappy out of disk space due to old kernel versions


I ran an update and received a message about running the command
Code:
dpkg --config -a
which I did and the that gave the error out of disk space in the /var directory. ran the df command and root '/' is full and has no free space left.
I then ran
Code:
dpkg -- list | grep 'linux-image'
and found I have 5 kernel versions that were from upgrading to newer versions but not removed.
I can't remove them due to the fact when I try to use apt-get or apt or dpkg to remove them it tells me I need to run
Code:
dpkg --configure -a
which then tells me I'm out of free space and the command fails.
So I need to know how to get rid of the older Kernel versions and not get prompted to run the configure all command.
Thanks in advance.
 
Old 12-02-2015, 12:06 AM   #2
astrogeek
Moderator
 
Registered: Oct 2008
Distribution: Slackware [64]-X.{0|1|2|37|-current} ::12<=X<=15, FreeBSD_12{.0|.1}
Posts: 6,263
Blog Entries: 24

Rep: Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194Reputation: 4194
Those kernel images really aren't taking up a lot of space, so freeing them will just defer the no-disk-space problems temporarily, if at all.

You should really identify what is taking up all the space and delete it instead, then remove old kernels if you want.

I would suggest looking in the /tmp directory first, then check for large log files, and full user home directories if that is on the same partition.

Use the du command on selected directories to find a place to start. Like maybe...

Code:
du -ks /tmp
du -ks /var/*
du -ks /home/*
You may need to be root or use sudo to see all of those.

Last edited by astrogeek; 12-02-2015 at 12:07 AM.
 
Old 12-02-2015, 10:53 AM   #3
bryanl
Member
 
Registered: Dec 2003
Posts: 97

Rep: Reputation: 35
astrogeek has good advice for finding where stuff is that you can then delete or offload.

One thing you might try is to clean up the package cache. Try this (as su):
Code:
echo "Cleaning Up" &&
apt-get -f install &&
apt-get autoremove &&
apt-get -y autoclean &&
apt-get -y clean
Another candidate is the log archives. Look for the gz files in /var/log

or you can boot off USB and use gpart to resize partitions to give you a bit more room.
 
Old 12-03-2015, 07:46 AM   #4
oldtechaa
Member
 
Registered: May 2015
Location: US
Distribution: Fedora
Posts: 364

Rep: Reputation: 83
If you have Bleachbit installed, you can use that too.
 
Old 12-06-2015, 03:53 AM   #5
tmick
Member
 
Registered: Jun 2005
Location: North Dakota
Distribution: Debian Testing
Posts: 247

Original Poster
Rep: Reputation: 20
Solved

So I found the pepperflashplayer-nonfree folder was huge. Cleared that out and removed wine from my system and I was able to get rid of the errors.
I also had to install and remove nvidia-legacy-kernel 304xx to get my GUI back (no idea why I had to do that to get that fixed) running bleach bitto clear up more free space.
Thanks all
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Recovering disk space lost due to dd error corbis_demon Linux - General 4 09-22-2009 08:43 PM
Can't login due to no disk space? How do i free some to log in?? BULPulse Slackware 10 03-11-2008 01:06 PM
System failed due to lack of free disk space une Mandriva 18 09-26-2007 05:56 AM
Kernel Deleted due to Upgrade, Cannot Reinstall Kernel due to Dependency Issues Kenji Miyamoto Debian 2 02-17-2007 09:44 AM
Linux doesn' boot due to lack of hard disk space ravykanth Linux - General 1 10-27-2003 03:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration