maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   What to do when /opt gets full? (https://talk.maemo.org/showthread.php?t=96510)

cjard 2016-03-09 14:06

What to do when /opt gets full?
 
df tells me that /opt is a 2 gig partition, 100% full

I installed ncdu and ran it from opt, after enumerating all the directories it says the total disk usage is 429Mb and the apparent size is 378Mb

How can I find where my missing 1.5 gigabyte went? (error messages appearing about device storage full, cannot save messages/contacts etc)

pichlo 2016-03-09 14:40

Re: What to do when /opt gets full?
 
du
Code:

du -s -d 1 /opt | sort -n
If that comes back with nothing, then your problem is running out of inodes. You have too many small files.

Check with:
Code:

df -i
Try purging your thumbnails and see what happens.

cjard 2016-03-09 15:48

Re: What to do when /opt gets full?
 
here's the output of the first command:
Code:

8        /opt/catorise
12        /opt/frontcamera
12        /opt/mfefolders
28        /opt/man
52        /opt/bin
68        /opt/batterypatch
72        /opt/savecpu
96        /opt/bootscreen
108        /opt/AutoCompleteEditor
192        /opt/powedit
220        /opt/metromap
304        /opt/unzip
344        /opt/pyrecipe
372        /opt/speccy
424        /opt/quickflickr
436        /opt/tflapp
460        /opt/zip
524        /opt/lfocus
564        /opt/packet-injection-modules
584        /opt/x48
612        /opt/rawcam
664        /opt/kmplayer
680        /opt/recovery-tools
848        /opt/theonering
1136        /opt/dropn900
1484        /opt/theme-customizer
1736        /opt/ovi-maps-cnfix
1892        /opt/blessn900
2432        /opt/qtmobilehotspot
3832        /opt/mediabox
6440        /opt/mc
40880        /opt/fapman-cache
42344        /opt/var
46624        /opt/share
50752        /opt/usr
55524        /opt/lib
58272        /opt/pymaemo
118384        /opt/maemo
439420        /opt

The second command gave "invalid option -i" and adviused the only valid options were h, m or k

pichlo 2016-03-09 16:29

Re: What to do when /opt gets full?
 
Sorry about the missing -i option, I forgot I was using busybox-power.

Your du output looks OK, leaving us with either a lot of small files or a file system corruption. Let's hope for the former.

Try:
Code:

find /opt -size -4k | wc
I get:
Code:

9745    9745    514223
Meaning, I have 9745 files smaller than 4 kilobytes.

wicket 2016-03-09 17:06

Re: What to do when /opt gets full?
 
/opt in Maemo is actually a bind mount to /home/opt so the slice that's full is actually /home (/dev/mmcblk0p2). The command I like to use to find where my disk space has gone is:
Code:

du -mx /home | sort -n
The -x option is needed so that it doesn't traverse MyDocs which is on a different slice. With this command you should be able to quickly identify the subdirectory that's taking up the most space.

You can also quickly identify large files in a particular directory with:
Code:

ls -lahSr
My guess would be that the rest of the space is being used by something under /home/user. Modest stores it emails under /home/user/.modest. If you're using a POP3 account it will quickly fill up.

pichlo 2016-03-09 17:34

Re: What to do when /opt gets full?
 
Yes, a different way to skin the same cat. Starting in /opt makes sure you exclude MyDocs :)

The OP has listed large directories. I suspect a lot of small files rather than large ones. Modest is a likely culprit indeed. Or WhatsApp.

wicket 2016-03-09 17:39

Re: What to do when /opt gets full?
 
Quote:

Originally Posted by pichlo (Post 1501034)
Starting in /opt makes sure you exclude MyDocs :)

You must have missed my last edit that explains the -x option of du. :P

pichlo 2016-03-09 17:46

Re: What to do when /opt gets full?
 
No, I did not. Just explaining why -x is not necessary in my example :)

wicket 2016-03-09 18:04

Re: What to do when /opt gets full?
 
The problem with your example is that if he has run out blocks rather than i-nodes (which is also a good theory by the way) then your usage of du doesn't tell us much because it misses out three quarters of the slice. :)

pichlo 2016-03-09 20:47

Re: What to do when /opt gets full?
 
Quote:

Originally Posted by wicket (Post 1501042)
The problem with your example is that if he has run out blocks rather than i-nodes (which is also a good theory by the way) then your usage of du doesn't tell us much because it misses out three quarters of the slice. :)

True, I missed that little detail ;)

EDIT: OP, please try wicket's instructions too to be safe.


All times are GMT. The time now is 03:32.

vBulletin® Version 3.8.8