Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[inodes] - Out of disk space errors, but there is free space
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
i92guboj
Moderator
Moderator


Joined: 30 Nov 2004
Posts: 9752
Location: Córdoba (Spain)

PostPosted: Fri Jan 13, 2006 7:28 pm    Post subject: [inodes] - Out of disk space errors, but there is free space Reply with quote

Well, I run out of inodes for first time in all my linux years due to portage, the growing beast that we all love.

I researched a bit around and saw some people on these forums with a similar problem, but no solutions, so I wrote this for both, future reference and as a tip for those with the same problem.

The context
A 1gb filesystem, formated with ext2 and mounted under /usr/portage (the distfiles are under another partition). To start, 1gb nowadays should be more than enough to hold portage without the distfiles. But after when moving portage to that partition I started receiving "out of space" errors. I saw that there was more than 500 mb of free space, but did not bother. I just deleted the metadata and copied the rest. All was fine.

To retrieve the metadata again I did a sync, but I started to get (after downloading some thousand of files) this annoying errors:
Code:

mkstemp "/usr/portage/metadata/glsa/.glsa-200406-11.xml.4Z0sc1" failed: No such file or directory
        1901 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-12.xml.HHMBdk" failed: No such file or directory
        2219 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-13.xml.yNQMeD" failed: No such file or directory
        2183 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-14.xml.Bji3fW" failed: No such file or directory
        2021 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-15.xml.CBPmhf" failed: No such file or directory
        2405 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-16.xml.hhLIiy" failed: No such file or directory
        2412 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-17.xml.8U16jR" failed: No such file or directory
        2148 100%    0.00kB/s    0:00:00
mkstemp "/usr/portage/metadata/glsa/.glsa-200406-18.xml.HWdyla" failed: No such file or directory

So I searched around and found about people having the same problem. It seemed that I was running out of inodes, now I understood the problem, back to the console and did this:
Code:

┌─(vie ene 13, 19:55:41)-(root@localhost)-(/home/i92guboj)-·
└─[9]-> # /usr/bin/df -i
S.ficheros           Nodos-i NUsados NLibres NUso% Montado en
/dev/hda2             611648  125566  486082   21% /
udev                   31947     287   31660    1% /dev
none                   31947       1   31946    1% /dev/shm
/dev/hda3             245280   41616  203664   17% /var
/dev/hda6            15499264   52727 15446537    1% /home
/dev/hda7             131616  131616       0  100% /usr/portage
/dev/hda8            1181952    3846 1178106    1% /usr/portage/distfiles
/dev/hda9             611648    1736  609912    1% /tmp
/dev/hda9             611648    1736  609912    1% /var/tmp
/dev/hda10            123648    1638  122010    2% /root
/dev/hda11            576000   23672  552328    5% /usr/src

I was indeed running out of inodes in hda7, my portage partition. Well, I wanted to get some more info:
Code:

┌─(vie ene 13, 20:04:21)-(root@localhost)-(/home/i92guboj)-·
└─[2]-> # tune2fs -l /dev/hda7
tune2fs 1.38 (30-Jun-2005)
Filesystem volume name:   <none>
Last mounted on:          <not available>
Filesystem UUID:          5719e659-59bd-424f-b089-38cc5137aa38
Filesystem magic number:  0xEF53
Filesystem revision #:    1 (dynamic)
Filesystem features:      filetype sparse_super
Default mount options:    (none)
Filesystem state:         not clean
Errors behavior:          Continue
Filesystem OS type:       Linux
Inode count:              131616

Indeed, portage almost fit in 1gb with a block size of 4096, somewhere in the latest updates the number of files grown up to 131616, which is the inodes count on that partition, and that was the reason why I run out of inodes. Well, it seems that I will have to reformat.

The solution
Code:

mkdir /home/tmp
umount /usr/portage/distfiles
mv /usr/portage/* /home/tmp
umount /usr/portage
mkfs.ext2 -i2048 /dev/hda7
tune2fs -O dir_index -c100 -i100 /dev/hda7
mount /usr/portage
mv /home/tmp/* /usr/portage
mount /usr/portage/distfiles
emerge sync

Hopefully, there's no problem from now on, well, until portage reaches this new inodes mark:
Code:

┌─(vie ene 13, 20:14:07)-(root@localhost)-(~/portage)-·
└─[32]-> # tune2fs -l /dev/hda7
tune2fs 1.38 (30-Jun-2005)
Filesystem volume name:   <none>
Last mounted on:          <not available>
Filesystem UUID:          0830cbad-31ad-4eb6-8285-0a7bd401a318
Filesystem magic number:  0xEF53
Filesystem revision #:    1 (dynamic)
Filesystem features:      dir_index filetype sparse_super
Default mount options:    (none)
Filesystem state:         clean
Errors behavior:          Continue
Filesystem OS type:       Linux
Inode count:              526592

Hope this is usefull for someone out there.
_________________
Gentoo Handbook | My website
Back to top
View user's profile Send private message
orvtech
Tux's lil' helper
Tux's lil' helper


Joined: 28 Aug 2004
Posts: 115
Location: US. Florida

PostPosted: Thu Feb 16, 2006 10:22 pm    Post subject: Un millon de gracias Reply with quote

Duuuude ... thank you so much!!!!!!!!!! :D
_________________
http://orvtech.com
http://www.linuxevolution.org
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum