Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Solved] Clean up /var/cache
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
lars_the_bear
Guru
Guru


Joined: 05 Jun 2024
Posts: 522

PostPosted: Sat Jun 22, 2024 9:50 am    Post subject: [Solved] Clean up /var/cache Reply with quote

Hi folks

After setting up Gentoo, I see that I have nearly 6Gb of stuff in /var/cache. I tried 'eclean' in various ways, but the amount hasn't reduced much.

I've set up a private binhost, so everything in /var/cache/binpkgs is centralized. The other large consumer is /var/cache/distfiles.

Is any hard likely to be done if I just delete the whole lot?

BR, Lars.


Last edited by lars_the_bear on Wed Jun 26, 2024 8:54 am; edited 1 time in total
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 9824
Location: almost Mile High in the USA

PostPosted: Sat Jun 22, 2024 10:36 am    Post subject: Reply with quote

Yes you can manually delete all of the distfiles if you so desire. eclean was meant to delete only stuff that no longer exists in portage (and thus would be hard to rebuild as you don't have an ebuild that tells portage how to build it).
_________________
Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54578
Location: 56N 3W

PostPosted: Sat Jun 22, 2024 10:41 am    Post subject: Reply with quote

lars_the_bear,

Quote:
everything in /var/cache/binpkgs is centralized.

The best/safest thing here is
Code:
eclean packages
which will remove every binary package that does not have an ebuild in the tree.
If you add the --deep option, everything not installed on the host you run it from will be removed. You probably don't want that.

Likewise with
Code:
distfiles
.
Should you choose to throw away distfiles entirely, they will be fetched again as required.
That's 'mostly harmless'. Packages will require to be rebuilt if you throw away packages.

Code:
Filesystem                      Size  Used Avail Use% Mounted on
/dev/mapper/storage-distfiles   984G  760G  179G  81% /var/cache/distfiles

I'm a hoarder, that's all my distfiles since June 2006 :)
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
lars_the_bear
Guru
Guru


Joined: 05 Jun 2024
Posts: 522

PostPosted: Sat Jun 22, 2024 12:37 pm    Post subject: Reply with quote

NeddySeagoon wrote:

Code:
Filesystem                      Size  Used Avail Use% Mounted on
/dev/mapper/storage-distfiles   984G  760G  179G  81% /var/cache/distfiles



That's more storage than I have, on the machines I'm running Gentoo on, put together :)

BR, Lars.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54578
Location: 56N 3W

PostPosted: Sat Jun 22, 2024 3:10 pm    Post subject: Reply with quote

lars_the_bear,

This is my 'bucket list' PC. :)
The link explains what and why.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
lars_the_bear
Guru
Guru


Joined: 05 Jun 2024
Posts: 522

PostPosted: Sat Jun 22, 2024 5:31 pm    Post subject: Reply with quote

NeddySeagoon wrote:
l
This is my 'bucket list' PC. :)


Fair enough. I kind-of got interested in Gentoo so I wouldn't have to buy a bucket-list PC. I've never really bought a computer -- not a modern one, anyway. They've always been supplied by employers or clients. But, all being well, I'll be retiring this year, and all the decent kit will be going back.

I did consider buying one final computer that would see me out, but I wondered whether, with Gentoo and a bit of fiddling, my 2012 Lenovo and Raspberry Pis would do the job. And they positively fly, without all the cruft of a modern Linux desktop. But whether they'll be up to KiCAD, Darktable, etc., I'm not sure.

I guess time will tell.

BR, Lars.
Back to top
View user's profile Send private message
Goverp
Advocate
Advocate


Joined: 07 Mar 2007
Posts: 2179

PostPosted: Sat Jun 22, 2024 6:33 pm    Post subject: Reply with quote

FWIW I always run
Code:
eclean --deep --time-limit=1m packages
eclean --deep --time-limit=1m distfiles

before my weekly
Code:
emerge --update --... @world

That way I still have all the files to rebuild what I'm about to update, also anything used in the last month, but no more.
I have "only" 14 GB distfiles (a lot of which is scenery for flightgear) and ~6GB binpkgs.
_________________
Greybeard
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