Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
/usr/portage getting huge!!
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Duplicate Threads
View previous topic :: View next topic  
Author Message
tristure
Apprentice
Apprentice


Joined: 30 Oct 2003
Posts: 270
Location: France

PostPosted: Sun Dec 28, 2003 10:16 pm    Post subject: /usr/portage getting huge!! Reply with quote

Hi, as you can imagine from the title, I'm trying to get some disk space free, and I noticed that my /usr/portage is about 1Go wide!!!

I don't understand what it is... Can I safely make it smaller??

Thanks.
Back to top
View user's profile Send private message
MaDmAsTeR
n00b
n00b


Joined: 31 Jul 2002
Posts: 39
Location: somewhere in Bavaria

PostPosted: Sun Dec 28, 2003 10:20 pm    Post subject: Reply with quote

Hi!

look at /usr/portage/distfiles

There are all files stored that you've downloaded and emerged...

The files in this directory can safely deleted from time to time, but dont do that when u use a slow inet-connection ;-)
_________________
My System stats
Back to top
View user's profile Send private message
El_Presidente_Pufferfish
Veteran
Veteran


Joined: 11 Jul 2002
Posts: 1179
Location: Seattle

PostPosted: Sun Dec 28, 2003 11:11 pm    Post subject: Reply with quote

you can
Code:
rm -r /var/tmp/portage/

too, but dont do it while emerging ;-D
Back to top
View user's profile Send private message
tristure
Apprentice
Apprentice


Joined: 30 Oct 2003
Posts: 270
Location: France

PostPosted: Sun Dec 28, 2003 11:29 pm    Post subject: Reply with quote

Thanks for the tip.

My /var/tmp/portage is not that huge though...
Back to top
View user's profile Send private message
dabooty
Guru
Guru


Joined: 15 May 2003
Posts: 482
Location: Belgium

PostPosted: Sun Dec 28, 2003 11:36 pm    Post subject: Reply with quote

cleaning out /usr/portage/distfiles should help quite a bit
_________________
registered user #284425
get yourself counted
http://counter.li.org
------
#emerge -pv solves a lot of questions beforehand
Back to top
View user's profile Send private message
slais-sysweb
Apprentice
Apprentice


Joined: 14 Jun 2002
Posts: 221
Location: London

PostPosted: Mon Dec 29, 2003 12:21 am    Post subject: Reply with quote

First, as others have already said, clear our /usr/portage/distfiles
Second, set up a /etc/portage/rsync_excludes file, uncomment /etc/make.conf to use it, and delete the unused ebuild categories from /usr/portage
My file for a very minimal system:
Code:

sysweb@knuth:sysweb $ cat /etc/portage/rsync_excludes
# KNUTH.....
# slais-sysweb@....        2003-09-22

## Required for emerge system
## sys-libs
## sys-fs
## sys-apps
## sys-devel
## net-misc
## dev-libs
## dev-lang
## app-shells
## app-editors

### Never exclude
### skel.metadata.xml
### skel.ebuild
### skel.ChangeLog
### scripts
### profiles
### metadata
### licenses
### header.txt
### eclass
### distfiles

# wildcards for groups never required
games-*
gnome-*
kde-*
media-*
x11-*
xfce-*

# ls /usr/portage > /etc/portage/rsync_excludes
# app-admin
# app-arch
app-benchmarks
app-cdr
# app-crypt
app-dicts
app-doc
app-emacs
app-emulation
app-gnustep
app-i18n
# app-misc      /screen
app-office
app-pda
# app-portage
app-sci
# app-text
# app-vim
app-xemacs
dev-ada
dev-cpp
dev-db
dev-dotnet
dev-embedded
dev-games
dev-haskell
dev-java
dev-lisp
dev-ml
# dev-perl
# dev-php
# dev-python
dev-ruby
dev-tcltk
dev-tex
# dev-util
fresco-base
net-analyzer
net-dialup
net-dns
net-firewall
# net-fs        # samba
net-ftp
net-im
net-irc
net-libs
# net-mail [virtual/mta dep vcron]
net-nds
net-news
net-p2p
net-print
net-wireless
net-www
net-zope
sec-policy
sys-cluster
# sys-kernel
unix2tcp


Note that as the ebuild categories get re-organised from time to time you will need to update this list from time to time. If you emerge and it cannot find an ebuild to satisfy a dependency that usually means that something is being excluded that is required. Also check the date of the files in /usr/portage after emerge sync, an excluded directory that has not been deleted will show up by not having the date of the latest sync
_________________
--
djc
sysweb SLAIS UCL
Back to top
View user's profile Send private message
dabooty
Guru
Guru


Joined: 15 May 2003
Posts: 482
Location: Belgium

PostPosted: Mon Dec 29, 2003 12:25 am    Post subject: Reply with quote

thanks slais-sysweb
_________________
registered user #284425
get yourself counted
http://counter.li.org
------
#emerge -pv solves a lot of questions beforehand
Back to top
View user's profile Send private message
moltonel
n00b
n00b


Joined: 31 Mar 2003
Posts: 31
Location: Ireland

PostPosted: Tue Aug 10, 2004 2:00 pm    Post subject: Reply with quote

You can automaticaly generate this /etc/portage/rsync_excludes file with these two commands :
Code:

emerge -ep `qpkg -I -nc` | grep ebuild | sed 's/.*] //' | sed 's/\/.*//' | sort | uniq > used_categories
grep -v -F -f used_categories /usr/portage/profiles/categories > /etc/portage/rsync_excludes

Update: lighter version not taking eventual new dependencies into account, therefore much faster, and single line just to show off :p :
Code:
grep -v -F `qpkg -I -nc |sed 's/^/-e /'|sed 's/\/.*//'|sort|uniq` /usr/portage/profiles/categories > /etc/portage/rsync_excludes


Last edited by moltonel on Thu Sep 30, 2004 3:14 pm; edited 1 time in total
Back to top
View user's profile Send private message
joeybravo
n00b
n00b


Joined: 30 Aug 2002
Posts: 45
Location: PH

PostPosted: Thu Sep 30, 2004 5:24 am    Post subject: Reply with quote

moltonel wrote:

Code:

emerge -ep  `qpkg -I -nc` |grep ebuild |sed 's/.*] //'|sed 's/\/.*//'|sort|uniq > used_categories
grep -v -F -f used_categories /usr/portage/profiles/categories > /etc/portage/rsync_excludes


I can't seem to make the first command to work :( "used_categories" came out empty.

My portage version is Portage 2.0.50-r9.
Back to top
View user's profile Send private message
oberyno
Guru
Guru


Joined: 15 Feb 2004
Posts: 467
Location: /bin/zsh

PostPosted: Thu Sep 30, 2004 5:40 am    Post subject: Reply with quote

Try this instead: (qpkg is part of gentoolkit)
Code:
qpkg -I -nc | sed 's:/.*::' | uniq > used_categories


Edit: added back -nc. :oops:
Back to top
View user's profile Send private message
joeybravo
n00b
n00b


Joined: 30 Aug 2002
Posts: 45
Location: PH

PostPosted: Fri Oct 01, 2004 2:08 am    Post subject: emerge -ep `qpkg -I -nc` Reply with quote

emerge -ep `qpkg -I -nc` seems to be the problem.

Quote:
talk root # emerge -ep `qpkg -I -nc`

These are the packages that I would merge, in order:

Calculating dependencies /
!!! all ebuilds that could satisfy "app-portage/deltup" have been masked.
!!! possible candidates are:
- app-portage/deltup-0.4.0 (masked by: ~keyword)

!!! Error calculating dependencies. Please correct.


Could be because I don't have "app-portage/deltup" in my portage.

Quote:
talk root # ls /usr/portage/app-portage/
abeni epm genlop gentoolkit-dev mirrorselect porthole
ebuilder esearch gentoo-stats kentoo portage-prefpane splat
envtest genflags gentoolkit metagen portagemaster ufed


BTW my system is using: Portage 2.0.50-r9 (x86, gcc-3.3.3, glibc-2.3.3.20040420-r0, 2.6.7-hardened)


This one worked: (Thanks oberyno)
Code:
qpkg -I -nc | sed 's:/.*::' | uniq > used_categories


And this too: (Thanks moltonel)
Code:
qpkg -I -nc |sed 's/\/.*//'|sort|uniq
Back to top
View user's profile Send private message
oberyno
Guru
Guru


Joined: 15 Feb 2004
Posts: 467
Location: /bin/zsh

PostPosted: Fri Oct 01, 2004 2:30 am    Post subject: Reply with quote

Deltup was removed from portage a while ago according to this thread. Without a valid ebuild in portage, portage can't figure out what to do.

I would suggest putting the ebuild in your overlay.
Code:
#uncomment the PORTDIR_OVERLAY line in make.conf
mkdir -p /usr/local/portage/app-portage/deltup
cp /var/db/pkg/app-portage/deltup-0.4.0/deltup-0.4.0.ebuild /usr/local/portage/app-portage/deltup/
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 20067

PostPosted: Fri Oct 01, 2004 2:41 am    Post subject: Reply with quote

See the FAQ Forum entry on disk space.
_________________
Quis separabit? Quo animo?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Duplicate Threads 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