Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 187597

Summary: portage-2.1.3.2 intermittently crashes on x86-fbsd when fcntl() F_SETFL returns EAGAIN
Product: Gentoo/Alt Reporter: Joe Peterson (RETIRED) <lavajoe>
Component: FreeBSDAssignee: Portage team <dev-portage>
Status: RESOLVED FIXED    
Severity: normal CC: bsd+disabled
Priority: High    
Version: unspecified   
Hardware: All   
OS: FreeBSD   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 181949    
Attachments: zmedico's eagain.patch

Description Joe Peterson (RETIRED) gentoo-dev 2007-08-03 15:05:44 UTC
Portage will give a python traceback intermittently on FreeBSD as follows:

Traceback (most recent call last):
  File "/usr/bin/emerge", line 6378, in ?
    retval = emerge_main()
  File "/usr/bin/emerge", line 6372, in emerge_main
    myopts, myaction, myfiles, spinner)
  File "/usr/bin/emerge", line 5831, in action_build
    retval = mergetask.merge(pkglist, favorites, mtimedb)
  File "/usr/bin/emerge", line 3737, in merge
    prev_mtimes=ldpath_mtimes)
  File "/usr/lib/portage/pym/portage.py", line 4043, in doebuild
    alwaysdep=1, logfile=logfile)
  File "/usr/lib/portage/pym/portage.py", line 3177, in spawnebuild
retval=spawnebuild(actionmap[mydo]["dep"],actionmap,mysettings,debug,alwaysdep=alwaysdep,logfile=logfile)
  File "/usr/lib/portage/pym/portage.py", line 3177, in spawnebuild
retval=spawnebuild(actionmap[mydo]["dep"],actionmap,mysettings,debug,alwaysdep=alwaysdep,logfile=logfile)
  File "/usr/lib/portage/pym/portage.py", line 3182, in spawnebuild
    phase_retval = spawn(actionmap[mydo]["cmd"] % mydo, mysettings,
debug=debug, logfile=logfile, **kwargs)
  File "/usr/lib/portage/pym/portage.py", line 2439, in spawn
    fcntl.fcntl(f.fileno(), fcntl.F_SETFL, fd_flags[f])
IOError: [Errno 35] Resource temporarily unavailable

---

zmedico sent me a patch (attached next) that fixes this
Comment 1 Joe Peterson (RETIRED) gentoo-dev 2007-08-03 15:10:41 UTC
Created attachment 126812 [details, diff]
zmedico's eagain.patch

This patch seems to fix the issue - at least I got through an entire "emerge -e system" after applying it (whereas it would typically die 1/5 of the way in or so).
Comment 2 Zac Medico gentoo-dev 2007-08-03 19:44:33 UTC
Thanks, this is released in 2.1.3.3.