Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Failed emerge taking up space when using tmpfs [solved]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
mani001
Guru
Guru


Joined: 04 Dec 2004
Posts: 358
Location: Oleiros

PostPosted: Mon Dec 07, 2015 10:10 am    Post subject: Failed emerge taking up space when using tmpfs [solved] Reply with quote

I'm having some disk space problems in Gentoo (I didn't foresee I would need 20 GB in /) The thing is, I needed to install Virtualbox so I deleted some stuff...but that wasn't enough and emerge failed due to lack of disk space. However, after the failed emerge, I have less disk space left than before (about 4MB :? )...and I don't get it since /var/tmp/portage is a tmpfs partition (i.e., the temporal files for the compilation should stay in memory...right?). Also, the failed emerge didn't get to the "install" part... So, is there any path where temporary stuff is saved prior to installation?

Cheers!!


Last edited by mani001 on Tue Dec 08, 2015 8:50 am; edited 1 time in total
Back to top
View user's profile Send private message
Syl20
Guru
Guru


Joined: 04 Aug 2005
Posts: 564
Location: France

PostPosted: Mon Dec 07, 2015 10:36 am    Post subject: Reply with quote

Are you sure the tmpfs is mounted on /var/tmp/portage ?
The "du" command should help you to know where to clean your system.
Back to top
View user's profile Send private message
mani001
Guru
Guru


Joined: 04 Dec 2004
Posts: 358
Location: Oleiros

PostPosted: Mon Dec 07, 2015 10:46 am    Post subject: Reply with quote

Yes, I'm sure /var/tmp is a "tmpfs". Also, during emerge I checked that the space on that partition was actually being used.

I know "du", but I don't think I can use it to find out now whether temporary stuff is in / somewhere (I don't know how much should weight every directory there).

Anyway, thanks for your quick reply.
Back to top
View user's profile Send private message
freke
Guru
Guru


Joined: 23 Jan 2003
Posts: 434
Location: Somewhere in Denmark

PostPosted: Mon Dec 07, 2015 11:02 am    Post subject: Reply with quote

Failed emerges should be under /var/tmp/portage, unless you've used PORTAGE_TMPDIR="/somewhere" to point to elsewhere...
(ie. /etc/portage/package.env to tell packages to big for tmpfs to compile using hdd/sdd)
Back to top
View user's profile Send private message
mv
Watchman
Watchman


Joined: 20 Apr 2005
Posts: 6281

PostPosted: Mon Dec 07, 2015 11:11 am    Post subject: Reply with quote

I would check whether /var/tmp/portage in the original file system was really empty (you can use mount --bind / /some-directory to check the original content).
To check for recently created files, you can use the -newer option of find with some file in /var/tmp/portage (man find for details).
Also, you should be aware that the space of a deleted file is only freed if no process is still holding a handle of that file.
Back to top
View user's profile Send private message
chithanh
Developer
Developer


Joined: 05 Aug 2006
Posts: 2152
Location: Berlin, Germany

PostPosted: Mon Dec 07, 2015 11:35 pm    Post subject: Reply with quote

Maybe something was downloaded to the distfiles directory.
In addition, emerge writes logs when compiling (though it should be less than 4 MB for a package).

Also, depending on your filesystem, small files or certain write/delete patterns can reduce usable space more than the files itself occupy. This especially applies to btrfs.
Back to top
View user's profile Send private message
enZom
n00b
n00b


Joined: 13 Nov 2015
Posts: 30
Location: In a sandbox

PostPosted: Tue Dec 08, 2015 1:49 am    Post subject: Reply with quote

Does FEATURES="fail-clean" still clean out failed data?

make.conf
Code:
FEATURES="fail-clean"


Then toss the logs elsewhere / anywhere you want.
Code:
PORT_LOGDIR="/var/log/portage"


Some linkage:
https://dev.gentoo.org/~zmedico/portage/doc/man/make.conf.5.html
Search for fail-clean
Back to top
View user's profile Send private message
mani001
Guru
Guru


Joined: 04 Dec 2004
Posts: 358
Location: Oleiros

PostPosted: Tue Dec 08, 2015 8:49 am    Post subject: Reply with quote

mv,

there is nothing in the "real" /var/tmp/portage (I "umount /var/tmp/portage" to check)

chithanh,

I didn't know about that. I'm using ext4

enZom,

interesting :) I'll give it a try

Anyway, I lost patience and ended up moving the whole /usr/portage to a different partition (that way I gained more than 1GB and it was enough). So, I didn't get to find out what the problem was. One possible hypothesis, though, is that "emerge" starts copying files to the file system before the printing out "installing" on the screen...yes, a little bit far fetched :-/

I'm marking this as solved, although I don't really know what was the problem at those specific emerges.

Thank you all!!

EDIT: ...a little late, but for what's worth the culprit was /var/tmp/ccache
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo 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