Can't figure out what's taking up all my disk space

Forum rules
Before you post please read how to get help
Post Reply
Clark5221
Level 1
Level 1
Posts: 8
Joined: Tue Mar 16, 2010 11:22 pm

Can't figure out what's taking up all my disk space

Post by Clark5221 »

Hey list,

I've got Linux Mint 8 (Helena - Main Edition) running on a 200GB partition. Nautilus & the disk manager utility say I only have 40GB free, but the "File System" only has 75GB of files on it.

So...

I'm wondering what's taking up the other 85GB of space. Is there some kind of hidden system file / reports folder / something like that where these files might be hiding? I've tried looking manually through Nautilus, through a terminal command, and through the included disk analyzer. It's getting to the point where I can hardly use MythTV anymore :( Any ideas would be most welcome.

Thanks!

-Chris
User avatar
bitmason
Level 2
Level 2
Posts: 68
Joined: Mon Feb 21, 2011 12:27 am
Location: Arizona

Re: Can't figure out what's taking up all my disk space

Post by bitmason »

did you setup a custom partition table when you installed mint?
"The surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us."
- Calvin & Hobbes
vincent
Level 8
Level 8
Posts: 2217
Joined: Tue Feb 09, 2010 4:10 am

Re: Can't figure out what's taking up all my disk space

Post by vincent »

Code: Select all

df -h
Let's start off with that...
Debian Testing x64/LM9 Main x64/Windows 7 x64 - LG R580 laptop w/ Intel Core 2 Duo T6500 2.1 GHz, 4 GB DDR2 RAM, Nvidia Geforce G 105M, Ralink rt2860 802.11n, 300 GB WD HD 5400 rpm
unexistance
Level 5
Level 5
Posts: 636
Joined: Tue Aug 05, 2008 12:28 am
Location: Malaysia

Re: Can't figure out what's taking up all my disk space

Post by unexistance »

Hi,

If you want to find out the biggest file(s), you can use gdmap (it's in the repo)

Regards,
:: Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved ::
Clark5221
Level 1
Level 1
Posts: 8
Joined: Tue Mar 16, 2010 11:22 pm

Re: Can't figure out what's taking up all my disk space

Post by Clark5221 »

Thanks for the feedback, everyone, but I'm still confounded.

Bitmason, I don't remember doing a custom partition table (I think I let gParted suggest the setup - it's been a while). I am running a dual-boot with Windows - the Windows side has 30GB, but that part's accounted for.

Vincent, I ran the command you suggested in the Terminal, and got this:
Filesystem Size Used Avail Use% Mounted on
/dev/sda5 199G 146G 44G 78% /
udev 1.5G 320K 1.5G 1% /dev
none 1.5G 716K 1.5G 1% /dev/shm
none 1.5G 296K 1.5G 1% /var/run
none 1.5G 0 1.5G 0% /var/lock
none 1.5G 0 1.5G 0% /lib/init/rw
/dev/sdb5 355G 329G 7.5G 98% /media/HD2
/dev/sdc1 150G 105G 45G 71% /media/My Passport

The problem remains, though - the "File System" only has about 75GB on it. I can't find what's using up the rest of the space.

Unexistance, I installed gdmap, but it still just shows what's in "File System"

------------------------
It seems like there's something outside of my File System that's taking up space, but I can't seem to find any way to "zoom out," if you will, far enough so I can see what's on the partition besides the File System. Would this all be swap files, or something like that?

Again, any help would be awesome. Thanks all!

-Chris
Habitual
Level 13
Level 13
Posts: 4863
Joined: Sun Nov 21, 2010 8:31 pm
Location: 0.0.0.0

Re: Can't figure out what's taking up all my disk space

Post by Habitual »

Since /home is under the "/dev/sda5 199G 146G 44G 78% /" reported.
How about

Code: Select all

du -sh /home/*
output?
re: "the "File System" only has about 75GB on it. I can't find what's using up the rest of the space.."
Could that difference be /home?
71 G worth of /home/*?

I have a shell script that I use for general inquiry that has this output:

Code: Select all

0K	./initrd.img.old
0K	./proc
0K	./sys
0K	./vmlinuz.old
4K	./media
4K	./mnt
4K	./selinux
4K	./srv
16K	./lost+found
180K	./mint
432K	./root
2.6M	./tmp
2.8M	./dev
7.5M	./bin
12.3M	./sbin
14M	./etc
25.9M	./boot
96.6M	./opt
139.7M	./lib
263.7M	./var
3.8G	./usr
18.1G	./home
Total: 21.5G
If you think that may help with this analysis, I will post it.

Please let us know...
User avatar
DrHu
Level 17
Level 17
Posts: 7522
Joined: Wed Jun 17, 2009 8:20 pm

Re: Can't figure out what's taking up all my disk space

Post by DrHu »

Clark5221 wrote:The problem remains, though - the "File System" only has about 75GB on it. I can't find what's using up the rest of the space.
Is it perhaps the windows OS partitions extended partitions etrc ?

How did you install the Linux partition to coexist with the windows partition(s)
--for example did you use a wubi (mint4win) installation, where Linux uses part of the windows file system/partitions to install the Linux guest (runs alongside windows in a VM (virtual machine) type of setup))
Clark5221
Level 1
Level 1
Posts: 8
Joined: Tue Mar 16, 2010 11:22 pm

Re: Can't figure out what's taking up all my disk space

Post by Clark5221 »

Still working through this one, guys - thanks so much for your help thus far.

Habitual - I'll try that script of yours if it'll help. Based on manually checking and the various disk utilities I've used, I'm fairly certain that the 56GB in my home folder is part of the 75GB in the File System.

Also, just a note to clarify - when I look at my file system as a whole, it includes my external drives. My quote of 75GB is just the portion that I can trace to my internal HD. That's where my limited space is causing me discomfort :?

DrHu,

I don't think the Windows OS is using the space, but I guess that would be possible. I did a fresh install of both Windows XP and LM8 at roughly the same time. Out of my 250GB HD, I partitioned 30GB for a barebones Windows install, and used the rest for LM in a dual-boot environment.

If I used my old LiveCD, would there be a way to sort of look in on the system from an outside perspective and see anything different? I'm used to the Windows/Mac way of looking at a "drive," rather than a "filesystem," which seems to be independent of a particular physical drive (i.e. my file system includes 2 external drives). Maybe I'm just coming at this from the wrong angle.


Thanks again, all for your continued help! I appreciate any further help / ideas.

-Chris
Habitual
Level 13
Level 13
Posts: 4863
Joined: Sun Nov 21, 2010 8:31 pm
Location: 0.0.0.0

Re: Can't figure out what's taking up all my disk space

Post by Habitual »

Chris:

Code: Select all

#!/bin/bash
/usr/bin/du -sk ./* | /usr/bin/sort -n | /usr/bin/awk 'BEGIN{ pref[1]="K"; pref[2]="M"; pref[3]="G";} { total = total + $1; x = $1; y = 1; while( x > 1024 ) { x = (x + 1023)/1024; y++; } printf("%g%s\t%s\n",int(x*10)/10,pref[y],$2); } END { y = 1; while( total > 1024 ) { total = (total + 1023)/1024; y++; } printf("Total: %g%s\n",int(total*10)/10,pref[y]); }'
I called/named it bdu.sh (for better disk usage)
Save it anywhere you like, chmod 700 /home/chris/bdu.sh (sorry if you know this already)
and then just run it in terminal

Code: Select all

$/path/to/some/directory/bdu.sh
or as root from /

Code: Select all

# /path/to/chris/some/directory/bdu.sh
I really hope it helps you identify the missing disk space.

John
Clark5221
Level 1
Level 1
Posts: 8
Joined: Tue Mar 16, 2010 11:22 pm

Re: Can't figure out what's taking up all my disk space

Post by Clark5221 »

John,

I am admittedly a total noob :-), but I followed your instructions, and got "bash: /home/clarks/bdu.sh: Permission denied"

I tried running the script normally, and as root. I've never worked with scripts, so maybe I'm doing something wrong...
Sorry for the noobie-ness.

-Chris
Habitual
Level 13
Level 13
Posts: 4863
Joined: Sun Nov 21, 2010 8:31 pm
Location: 0.0.0.0

Re: Can't figure out what's taking up all my disk space

Post by Habitual »

not a problem.
Open terminal and type

Code: Select all

chmod 700 /home/chris/where/you/saved/bdu.sh
should now work.
Clark5221
Level 1
Level 1
Posts: 8
Joined: Tue Mar 16, 2010 11:22 pm

Re: Can't figure out what's taking up all my disk space

Post by Clark5221 »

Habitual,

Thanks for the chmod tip - your script worked just fine. Unfortunately, all I could see there was the stuff I already had accounted for (although, it's a quick, easy way to see everything at once).

Good news - I know how to use scripts now :)

Bad news - I still can't find what's taking up disk space :(

Guess I'll check windows again & try inspecting it while booted with a live cd
Habitual
Level 13
Level 13
Posts: 4863
Joined: Sun Nov 21, 2010 8:31 pm
Location: 0.0.0.0

Re: Can't figure out what's taking up all my disk space

Post by Habitual »

It's a clever script that I found and thought useful. I'm a command-line guy from Waaaaaaaaaay back in the DOS 3.3 days of the 1990s.

Glad you found it useful too.

Bummer about the disk space. :(
deivid
Level 1
Level 1
Posts: 15
Joined: Thu Jan 28, 2010 8:42 pm

Re: Can't figure out what's taking up all my disk space

Post by deivid »

Could you post the output of the following command?

Code: Select all

sudo du -sh /*
Post Reply

Return to “MATE”