Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 17354 - portage broken due to bash move from sys-apps/bash to app-shells/bash
Summary: portage broken due to bash move from sys-apps/bash to app-shells/bash
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High critical
Assignee: Nicholas Jones (RETIRED)
URL:
Whiteboard:
Keywords:
: 17399 17431 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-03-12 03:39 UTC by Robin Johnson
Modified: 2003-03-18 15:27 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 03:39:25 UTC
portage broken due to bash move from sys-apps/bash to app-shells/bash, see bug 
13530.

Severity = critcal because this breaks portage.

Reproducible: Always
Steps to Reproduce:
1. emerge sync
2. emerge -upvk --deep world
3.

Actual Results:  
emerge sync:
(normal output)
emerge -upvk --deep world:
These are the packages that I would merge, in order:
Calculating world dependencies /
emerge: there are no masked or unmasked ebuilds to satisfy ">=sys-apps/bash-
2.05a".

Expected Results:  
should have displayed list of software to update

Portage 2.0.47-r8 (default-x86-1.4, gcc-3.2.2, glibc-2.3.2_pre1-r0)
=================================================================
System uname: 2.4.20-gentoo-r1 i686 Pentium III (Katmai)
GENTOO_MIRRORS="http://gentoo.oregonstate.edu "
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/kde/3/share
/config /var/bind /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config /usr/share/te
xmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/config"
CONFIG_PROTECT_MASK="/etc/gconf /etc/afs/C /etc/afs/afsws /etc/env.d"
PORTDIR="/usr/portage"
DISTDIR="/usr/portage/distfiles"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR_OVERLAY="/usr/local/portage"
USE="x86 libg++ -3dfx -3dnow aalib acl acpi afs alsa apache2 apm arts avi 
berkdb bonobo canna cdr cjk crypt cups dga directfb doc dvd encode esd ethereal 
evo fbcon flash freewnn gb gd ggi gif -gnome gphoto2 gps gtk gtk2 gtkhtml guile 
imap imlib innodb ipv6 java jikes jpeg junit kde -kerberos lcms ldap leim 
libgda libwww maildir -matrox mbox mikmod motif mozilla mpeg -mule mysql nas 
nls oav -oci8 oggvorbis opengl oss -pcmcia -pda pdflib plotutils png pnp -
postgres qt -qtmt quicktime ruby samba sasl scanner sdl slp snmp socks5 spell 
sse svga tcltk tcpd tetex tiff truetype trusted usb -voodoo3 wavelan wmf X 
xface xml xml2 xmms xv gdbm gpm mmx ncurses pam perl pic python readline slang 
ssl zlib mozsvg mozcalender mozaccess mozinterfaceinfo mozp3p mozxmlterm"
COMPILER="gcc3"
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=pentium3 -O3 -pipe"
CXXFLAGS="-O2 -mcpu=i686 -pipe"
ACCEPT_KEYWORDS="x86 ~x86"
MAKEOPTS="-j4"
AUTOCLEAN="yes"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
FEATURES="buildpkg sandbox"
Comment 1 Seemant Kulleen (RETIRED) gentoo-dev 2003-03-12 04:18:04 UTC
I would like you to do the following:

rm -rf /var/cache/edb/dep*
emerge sync

emerge -upvk --deep world

and report here please.
Comment 2 Mathias Gumz 2003-03-12 05:08:45 UTC
i have some similar problems here, but with another package -> perl

------>

alpha root # emerge -Up --deep world
>>> --upgradeonly implies --update... adding --update to options.

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

Calculating world dependencies -
emerge: there are no masked or unmasked ebuilds to satisfy "sys-devel/perl".

<------

i tried:

>rm -rf /var/cache/edb/dep*
>emerge sync

but it doesnt help. a normal emerge -Up world works ...



alpha root # emerge info 
Portage 2.0.47-r7 (default-x86-1.4, gcc-3.2.2, glibc-2.3.2-r0)
=================================================================
System uname: 2.4.20 i686 AMD Athlon(tm) processor
GENTOO_MIRRORS="ftp://sunsite.dk/mirrors/gentoo/ ftp://gentoo.linux.no/pub/gentoo/ ftp://ftp.tu-clausthal.de/pub/linux/gentoo/ ftp://ftp.snt.utwente.nl/pub/os/linux/gentoo/ ftp://ftp.rez-gif.supelec.fr/pub/Linux/distrib/gentoo/ "
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config /usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/kde/3.1/share/config /usr/share/config"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
PORTDIR="/usr/portage"
DISTDIR="/usr/portage/distfiles"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/scratch/portage"
PORTDIR_OVERLAY=""
USE="x86 oss 3dnow apm avi crypt cups encode gif jpeg libg++ mikmod mmx mpeg ncurses nls pdflib png quicktime spell truetype xml2 xmms xv zlib gdbm berkdb slang readline arts tetex aalib svga tcltk java guile ruby mysql X sdl gpm tcpd pam libwww ssl perl python esd imlib oggvorbis gnome gtk qt kde motif opengl mozilla cdr"
COMPILER="gcc3"
CHOST="i686-pc-linux-gnu"
CFLAGS="-O3 -mcpu=athlon-tbird -march=i686 -DHAVE_ERRNO_AS_DEFINE=1 -pipe"
CXXFLAGS="-O3 -mcpu=athlon-tbird -march=i686 -DHAVE_ERRNO_AS_DEFINE=1 -pipe"
ACCEPT_KEYWORDS="x86 ~x86"
MAKEOPTS="-j2"
AUTOCLEAN="yes"
SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"
FEATURES="sandbox ccache"


i still got -r7 because of the broken cvs-distfiles on network-fs-systems and the ugly xmms-install-bug ...


hope it helps,

m

Comment 3 sf 2003-03-12 07:29:55 UTC
After following Seemant Kulleen's suggestions (see comment 2) the error did not go away.
Comment 4 Martin Holzer (RETIRED) gentoo-dev 2003-03-12 11:52:02 UTC
please sync new
just recheckt portage tree, no problem here
Comment 5 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 12:07:55 UTC
After following Seemant's advice (comment 2) the error also remains.
Something interesting as per comment 3, if I leave out --deep (so it's
roughly 'emerge -Upkv'), then it complains on perl and not bash.
Comment 6 Martin Holzer (RETIRED) gentoo-dev 2003-03-12 12:09:10 UTC
do you use PORTAGE_OVERLAY ?
Comment 7 Martin Holzer (RETIRED) gentoo-dev 2003-03-12 12:14:32 UTC
1. rm -rf /var/cache/edb/dep/*
2. emerge regen

this should fix it
Comment 8 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 12:18:13 UTC
Yes, I do use PORTAGE_OVERLAY. It presently contains only a custom ebuilds for: dev-php/php, dev-php/mod_php, net-libs/libwww.

I'm running your latest instructions now martin.
Comment 9 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 12:44:27 UTC
After running martin's instructions (comment 8) the results are still the same, I still get the error.

I've also tried wiping out all of /usr/portage (leaving out distfiles and packages) and doing the sync again, with out any resolution to the problem.
Comment 10 Martin Holzer (RETIRED) gentoo-dev 2003-03-12 12:48:02 UTC
agriffis submitted gentoolkit-0.1.19-r3.ebuild which has the old depend sys-devel/perl in it

just changed it to dev-lang

this should really fix it
Comment 11 sf 2003-03-12 13:02:19 UTC
I did

1. rm -rf /var/cache/edb/dep/*
2. emerge regen
3. emerge sync

Still no go!
Comment 12 Seemant Kulleen (RETIRED) gentoo-dev 2003-03-12 13:30:13 UTC
ok check it out:

mv /usr/portage/distfiles/* /var/tmp or wherever OUTSIDE of /usr/portage
rm -rf /var/cache/edb/dep/*

emerge sync
emerge regen

report here..
Comment 13 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 13:30:53 UTC
martin: just did emerge sync to get the update, as well as emerge regen after rm -rf /var/cache/edb/dep*, and still no success.

are you really really sure? ;-)

I'm heading off to an exam now, so I won't be working on this issue for the next 6-7 hours.

I left this command running on a hunch:
find /usr/portage /var/db/pkg /var/cache/edb -exec egrep -Hn 'sys-devel/perl|sys-apps/bash' \{} \; >/root/results

I'll look thru the results later.
Comment 14 sf 2003-03-12 14:33:38 UTC
I think i got a clue to the problem:

When I define DISTDIR and PKGDIR explicitly in /etc/make.conf, either using ${PORTDIR}/... or written out, I get

emerge: there are no masked or unmasked ebuilds to satisfy ">=sys-apps/bash-2.05a".

If I comment those definitions out again the error goes away.
Comment 15 Martin Holzer (RETIRED) gentoo-dev 2003-03-12 16:07:22 UTC
*** Bug 17399 has been marked as a duplicate of this bug. ***
Comment 16 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 20:31:00 UTC
If I try what is suggested in comment 15, the results remain the same.

Trying seemant's stuff in comment 13 now.
Comment 17 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 20:41:22 UTC
Ok, there seem to be two seperate issues here now.

Seemant's advice in comment 13 on it's own leads to it always complaining about sys-devel/perl. I've narrowed it down to the fact that it's the packages dir causing the problem. I'll see about figuring out which package is the issue later on, because I have a LOT of packages built on this machine (~1200 or so that is).

Applying comment 15 after seemant's stuff resolves the rest of it. I'm going to work thru and see which variables are the source of the problem. 
In my case, the variables are specified explicltly:
PORTAGE_TMPDIR=/var/tmp
DISTDIR=/usr/portage/distfiles
PKGDIR=/usr/portage/packages
PORT_LOGDIR=/var/log/emerge
PORTDIR_OVERLAY=/usr/local/portage
Comment 18 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 22:16:11 UTC
Found it now for the sys-devel/perl while looking thru my results from earlier.
In my PORTDIR_OVERLAY, I have a custom ebuild of net-libs/libwww i've been working on, getting it up to MySQL 4 compliancy. Now I'm just working on tracing what package caused the bash error to pop up.
Comment 19 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 22:47:14 UTC
For the packages problem, 
check this out:
(in /usr/portage/packages/All)
server1 All # grep '>=sys-apps/bash-2.05a' *
Binary file portage-2.0.46-r11.tbz2 matches
Binary file portage-2.0.46-r12.tbz2 matches
Binary file portage-2.0.47-r2.tbz2 matches
Binary file portage-2.0.47-r7.tbz2 matches
Binary file portage-2.0.47-r8.tbz2 matches

I so re-emerged portage, and the compliant about bash goes away.
Similar results for perl and a few other things it started to complain about.

So about portage behavior, presently it seems to look inside each of the most up to date binary packages to get the ebuild specs. If that ebuild happens to reference something that got moved, it barfs.

There are a number of possible solutions to this I believe, but of them, I believe this would be best:
When ANY changes are make to an ebuild, the release number is bumped. This could even be done via CVS then with a bit of scripting treachery. Under this, the CVS tree would only ever have a single base build for each version, and that can get custom checked out say the 5 most recent versions of each file, or maybe using tags ? That data would then get distributed via rsync with 5 files.

Comment 20 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-12 23:58:18 UTC
just a question
could some master list of package renaming get put together and made visible to users?
Comment 21 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-13 00:02:13 UTC
Another possible idea on the fix for the problem.
It occured because the sys-apps/bash ebuild vanished from the tree, it was renamed to app-shells/bash, but portage didn't know that itself.

So either it shouldn't have been removed at that point, or alternatively portage needs some sort of package pointer feature. It would have to be smarter than symlinks to actually tell it to use another package. Ideally it should spit out a warning as well.
Comment 22 Seemant Kulleen (RETIRED) gentoo-dev 2003-03-13 00:16:17 UTC
in theory, portage should know about this. (see /usr/portage/profiles/updates/1Q-2003)
Comment 23 Seemant Kulleen (RETIRED) gentoo-dev 2003-03-13 10:18:59 UTC
*** Bug 17431 has been marked as a duplicate of this bug. ***
Comment 24 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-13 12:14:06 UTC
Seemant/carpaski:
Where in portage.py is the code that is supposed to handle this?

Looking at it, I see lines 4440-4457, as well as the function @ 4397-4438, but I don't see where that gets applied to the data from the binary packages.
Comment 25 sf 2003-03-13 14:40:52 UTC
For what it is worth: After randomly and repeatedly doing "rm -rf /var/cache/edb/dep*", "emerge sync", "emerge regen", "emerge portage" the problem of the bash dependency is gone.

Now I get

emerge: there are no masked or unmasked ebuilds to satisfy ">=sys-devel/perl-5.6.0".
Comment 26 Dominik Diesch 2003-03-15 11:46:53 UTC
It seems to me that its not the --deep switch causing the problem, but the -k. After 
removing all the tbz2 containing sys-devel/perl or sys-apps/bash from the 
/usr/portage/packages/All directory the problems vanished. 
I also tried to  
sed 's#sys-devel/perl#dev-lang/perl#' 
the packages in question to rescue the expensive builds but I didn't succeed since 
some binary information gets corrupted. Does someone know how to fix this easily? 
Comment 27 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-15 17:32:58 UTC
Dom:
I just did found all the files in PORTDIR/packages/All containing 'sys-apps/bash' or 'sys-devel/perl' using grep, and recompiled them in a sensible order that I could find myself. there were about 40, incl. bash, binutils, mozilla, all of KDE and a few others. It didn't take me longer than 12 hours for the entire recompile, so I don't know how you are defining expensive builds?

The latest -r10 of Portage now actually displays the file that caused the problem as well, so it's easier to trace the problem package.
Comment 28 D Wollmann 2003-03-16 02:34:47 UTC
For what it's worth, I've been experiencing the
sys-devel/perl dep problem, and ran the following
against ${PORTDIR_OVERLAY}:

find . -name '*.ebuild' | xargs perl -pi.badperldep -e s!sys-devel/perl!dev-lang/perl!g'

This seems to have cleared up the problem when
resolving dependencies on my build machine, but
I suppose I'll have to rebuild the binary packages
for installation on my other gentoo system.

Would it be possible to introduce rsync-managed symlinks
into the portage tree to make moves of this sort less
painful in the future, or would that just make things
worse?
Comment 29 Martin Holzer (RETIRED) gentoo-dev 2003-03-16 15:34:51 UTC
carpaski updated all packages 
the cvs comment: "Updated all of the profile information to move sys-apps/bash to apps-shells/bash..."

should be fixed now
Comment 30 Scott Richey 2003-03-17 10:49:01 UTC
Everything is working fine now after the latest emerge sync. Thanks!
Comment 31 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2003-03-18 15:24:00 UTC
Carpaski/Seemant/Holzer: 
I think this can move to status RESOLVED now, pending verification.
Comment 32 Martin Holzer (RETIRED) gentoo-dev 2003-03-18 15:27:10 UTC
thx. closing this now