Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 98941 - Portage Crashes During Emerge; Portage Becomes an Invalid Command
Summary: Portage Crashes During Emerge; Portage Becomes an Invalid Command
Status: VERIFIED NEEDINFO
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Interface (emerge) (show other bugs)
Hardware: x86 Linux
: High blocker (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-13 17:16 UTC by Bob
Modified: 2007-01-11 11:01 UTC (History)
1 user (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 Bob 2005-07-13 17:16:01 UTC
I have a Gentoo-based server that was being updated to upgrade the packages that
were flagged in my glsa-check.  After emerge --sync, I attempted to emerge the
most recent portage ebuild.  The ebuild failed to compile, and the result was
that   "emerge" was reported as an invalid command by the bash shell.  I had to
fix boot from a Live CD and untar a new tarball to fix the problem.

Once my new system had been emerged and rebuilt, I emerge --synd'd again.  I
then used the command "emerge webapp-config cpio" to emerge two packages that
were flagged as vulnerable by "glsa-check -l".  Although webapp-config emerged
fine, the emerge of cpio failed, and the error message reported that the emerge
of PORTAGE had failed!  i have no idea why PORTAGE tried to emerge itself, but
it buggered up the server in the process.  once again, emerge is no longer
recognized as a valid command at the command prompt:  

bash: emerge:  command not found

It looks like I'll have to rebuild the system AGAIN.

Why does this keep happening?!?




Reproducible: Always
Steps to Reproduce:
1.  emerge anything   -- watch portage crash

Actual Results:  
portage crashes, emerge becomes an invalid command

Expected Results:  
emerge packages

bash: emerge: command not found
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2005-07-13 17:36:36 UTC
Uhm, are you really sure that your hardware is OK? Did you run memtest? Isn't
your CPU overheating? Other ideas in Bug 20600.
Comment 2 Bob 2005-07-13 17:59:15 UTC
as hard as this may be to believe, the emerge logs show that portage unmerged
itself!

http://forums.gentoo.org/viewtopic-p-2571867.html
Comment 3 Jason Stubbs (RETIRED) gentoo-dev 2005-07-14 03:31:17 UTC
What hardware are you running on? 
What version of portage did it upgrade to? 
What version of portage did it upgrade from? 
Do you have any logs whatsoever of what was displayed after webapp-config 
correctly installed? 
Any information that might be of help at all? 
Comment 4 Jakub Moc (RETIRED) gentoo-dev 2005-07-14 04:01:48 UTC
(In reply to comment #3)
> Do you have any logs whatsoever of what was displayed after webapp-config 
> correctly installed? 

Reposting from forums.g.o.; reporter, please don't link outside of bugzilla,
attach or paste the logs here.

1121297499: Started emerge on: Jul 13, 2005 18:31:39
1121297499:  *** emerge  webapp-config cpio
1121297503:  >>> emerge (1 of 2) net-www/webapp-config-1.11 to /
1121297503:  === (1 of 2) Cleaning
(net-www/webapp-config-1.11::/usr/portage/net-www/webapp-config/webapp-config-1.11.ebuild)
1121297519:  === (1 of 2) Compiling/Merging
(net-www/webapp-config-1.11::/usr/portage/net-www/webapp-config/webapp-config-1.11.ebuild)
1121297691:  === (1 of 2) Updating world file (net-www/webapp-config-1.11)
1121297691:  === (1 of 2) Post-Build Cleaning
(net-www/webapp-config-1.11::/usr/portage/net-www/webapp-config/webapp-config-1.11.ebuild)
1121297706:  >>> AUTOCLEAN: net-www/webapp-config
1121297712: === Unmerging... (net-www/webapp-config-1.10-r11)
1121297745:  >>> unmerge success: net-www/webapp-config-1.10-r11
1121297753:  ::: completed emerge (1 of 2) net-www/webapp-config-1.11 to /
1121297754:  >>> emerge (2 of 2) app-arch/cpio-2.6-r4 to /
1121297754:  === (2 of 2) Cleaning
(app-arch/cpio-2.6-r4::/usr/portage/app-arch/cpio/cpio-2.6-r4.ebuild)
1121297770:  === (2 of 2) Compiling/Merging
(app-arch/cpio-2.6-r4::/usr/portage/app-arch/cpio/cpio-2.6-r4.ebuild)
1121298322:  === (2 of 2) Post-Build Cleaning
(app-arch/cpio-2.6-r4::/usr/portage/app-arch/cpio/cpio-2.6-r4.ebuild)
1121298331:  >>> AUTOCLEAN: app-arch/cpio
1121298337: === Unmerging... (app-arch/cpio-2.6-r2)
1121298358:  >>> unmerge success: app-arch/cpio-2.6-r2
1121298364:  ::: completed emerge (2 of 2) app-arch/cpio-2.6-r4 to /
1121298364:  *** Finished. Cleaning up...
1121298377: === Unmerging... (sys-apps/portage-2.0.51.19)
1121298397:  *** terminating. 

Comment 5 Jason Stubbs (RETIRED) gentoo-dev 2005-07-14 04:29:23 UTC
The log snippet indicates that portage was auto-cleaned after the other 
emerges finished. The fact that it was autocleaned means that another version 
of portage is recorded as being installed at a later time than the version 
unmerged. 
 
What stage file did you install from? Do you happen to have 
FEATURES="livecvsportage". Are there any files/directories 
matching /var/db/pkg/sys-apps/portage* ? 
 
Comment 6 Stian Skjelstad 2005-07-16 06:12:03 UTC
If you rescue back your portage, please post  emerge info here.

If I understood the posts on the forum right, you have USE=+ntpl on a K6 system.
Does K6 support ntpl? I thougt ntpl required syscall support?

In your setup, portage for instance is going to upgrade itself. This goes the
following way:
compile
unmerge
*here your portage crashes*
merge in new files


The crash can come from various sources, like bad memory, or a program beeing
compiled with CFLAGS your cpu can't handle. (That is why we want to see output
from emerge info).


And for the devs, what packages are critical for portage to function without
crashes? portage, python and libc?
Comment 7 Jason Stubbs (RETIRED) gentoo-dev 2005-07-17 17:28:26 UTC
Stian, that is incorrect. 
 
Portage unmerges old files _after_ merging the new files. At no stage should a 
crash be able to cause the files to be missing. 
Comment 8 Alec Warner archtester Gentoo Infrastructure gentoo-dev Security 2005-08-06 08:35:16 UTC
Please provide any entries in /var/db/pkg/sys-apps/portage*

Comment 9 Alec Warner archtester Gentoo Infrastructure gentoo-dev Security 2005-08-12 23:05:12 UTC
(In reply to comment #8)
> Please provide any entries in /var/db/pkg/sys-apps/portage*
> 
> 

Need those /var/db/pkd/sys-apps/portage* entries, otherwise it is difficult to 
figure out exactly what went on.  If you have none, that information would be 
helpful also.
Comment 10 Marius Mauch (RETIRED) gentoo-dev 2007-01-11 11:01:32 UTC
Closing due to old age