LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 10-11-2007, 03:52 AM   #1
bulkathos
LQ Newbie
 
Registered: Jun 2007
Posts: 9

Rep: Reputation: 0
My / is almost full


In my debian Etch / is almost full,I do not want rm anything and my /home(another partion) has much space.
What can I do to free some space in /.
 
Old 10-11-2007, 04:06 AM   #2
reverse
Member
 
Registered: Apr 2007
Distribution: Gentoo
Posts: 337

Rep: Reputation: 30
You can rm something. And see if `apt-get clean` helps.
 
Old 10-11-2007, 04:19 AM   #3
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
There's not much to suggest unless we know WHY your / is getting full. It it because you've installed a lot of programs and /etc is getting big? Do your /tmp or /var fill up?

Since you don't want to remove anything, what actions are acceptable to you? Do you have any other space available outside of /home? It sounds to me like your best action would be to shrink your /home partition and use the extra space to house a partition for whatever directory is getting too full.
 
Old 10-11-2007, 04:27 AM   #4
linx win
Member
 
Registered: Jan 2004
Posts: 390

Rep: Reputation: 31
Quote:
Originally Posted by reverse View Post
You can rm something. And see if `apt-get clean` helps.
Before doing this, I suggest making a backup copy of all your downloaded debian packages to your home partition as follows with your normal user account:

Code:
mkdir ~/backup
cp /var/cache/apt/archives/*.deb ~/backup
 
Old 10-11-2007, 04:41 AM   #5
bulkathos
LQ Newbie
 
Registered: Jun 2007
Posts: 9

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by David the H. View Post
It it because you've installed a lot of programs and /etc is getting big? Do your /tmp or /var fill up?
.
My box has one disk.It is divided into 4 partionne swap,and other mounted as / /home /data./ is full,because it is ony 4.5G,and I compiled some program from source so the /usr is almost 2.5G.If I
#rm -r /usr/local/src/somepro/,does the program I installed still work?
 
Old 10-11-2007, 04:56 AM   #6
Goofy180173
Member
 
Registered: Nov 2005
Location: Austria
Distribution: Open Suse 10.3
Posts: 32

Rep: Reputation: 15
If you have enough space on /home you could change your partition size with with a gparted Live CD
http://gparted.sourceforge.net/
Itīs easy to use and worked for me without any problems
 
Old 10-11-2007, 08:00 AM   #7
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
aptitude update
aptitude keep-all
aptitude install localepurge debfoster deborphan
aptitude clean
localepurge
deborphan
debfoster


(might want to review the man pages of deborphan and depfoster before running them so you know what they do.. localepurge removes man pages in languages other than what your locale is set to .)

how full are we talking here? df -h

How many kernels are currently installed on your machine ? I only keep the last 2 I installed around. anything else gets purged.

you can scan your disk for the 10 largest files to see if theres some large file hanging around out there you might not know about.
cd /
du -a | sort -nr | head


also check your /var/log directory for extraneous log files you can delete. No reason to keep a ton of old logs around you will never use.

what is in /root the root users home directory is under / not /home. Did you download any large files into /root ?

well that should give you a few things to look at.

Last edited by farslayer; 10-11-2007 at 08:01 AM.
 
Old 10-11-2007, 08:36 AM   #8
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
Quote:
Originally Posted by bulkathos
My box has one disk. It is divided into 4 partionne swap, and other mounted as / /home /data. / is full, because it is ony 4.5G, and I compiled some program from source so the /usr is almost 2.5G. If I #rm -r /usr/local/src/somepro/, does the program I installed still work?

The programs will still work. 'make install' copies the compiled files to their proper locations, and deleting the compilation folder won't touch them. But it will make removing the programs more difficult, since you won't be able to run 'make uninstall' in the original folder anymore.

There are a couple of options you can use to work around this. One, you can compile the program in your home directory using the 'fakeroot' program, which lets you simulate a root environment during compilation. Then you can su to root for the final installation.

The second method is to use 'checkinstall'. When you run this small program in place of 'make install', it will wrap your compilation up in a .deb package (on Debian. It can also do .rpm and .tgz), before it installs it. That way you can remove the compilation directory and simply uninstall the package with dpkg or apt.

And of course there's nothing stopping you from using both means together.

Overall, I think the best long-term solution is to create a separate partition for /usr (and maybe /tmp and /var). You'll need to resize your /home partition first to give you some blank space. Then you can mount the new partition, move all the /usr files to it, and finally edit your /etc/fstab file so that it mounts at /usr.

You might have some problems if your current partitioning scheme consists of four primary partitions though. A hard disk can only have a maximum of four primary partitions. You'll probably have to backup a partition, erase it, and recreate it as an extended partition, so that you can create two or more logical partitions inside of it. It's a bit of trouble, but in the long run it's probably better for your system.

Or, assuming it's not a laptop, you could simply buy a second hard disk and create all the new partitions you need on it.
 
Old 10-11-2007, 08:46 AM   #9
rickh
Senior Member
 
Registered: May 2004
Location: Albuquerque, NM USA
Distribution: Debian-Lenny/Sid 32/64 Desktop: Generic AMD64-EVGA 680i Laptop: Generic Intel SIS-AC97
Posts: 4,250

Rep: Reputation: 62
Listen to farslayer
 
  


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
Why has my / partition full??? cpd05 Debian 9 01-31-2007 05:09 AM
HDA1 is full, what now? Bag9697 Linux - Newbie 3 06-16-2005 07:42 PM
My hd is full ... boumbo Fedora 3 02-20-2005 06:06 AM
Which distributions do not support --full-time for ls (ls --full-time)? GCS Linux - Distributions 0 07-28-2004 01:25 AM
/ = 98.5% full lachlan Linux - Software 1 06-17-2002 04:37 AM

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

All times are GMT -5. The time now is 04:27 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