Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Portage stopped working after upgrade
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
Carnildo
Guru
Guru


Joined: 17 Jun 2004
Posts: 584

PostPosted: Tue Nov 20, 2012 9:06 pm    Post subject: Portage stopped working after upgrade Reply with quote

I upgraded Portage from 2.1.11.9 to 2.1.11.31 on one of my systems, and it no longer works, failing with the following output:
Code:
Traceback (most recent call last):
  File "/usr/bin/emerge", line 48, in <module>
    retval = emerge_main()
  File "/usr/lib/portage/pym/_emerge/main.py", line 1021, in emerge_main
    gc_locals=locals().clear)
  File "/usr/lib/portage/pym/_emerge/actions.py", line 3501, in run_action
    repo_name_duplicate_check(trees)
  File "/usr/lib/portage/pym/_emerge/actions.py", line 3396, in repo_name_duplicate_check
    portdb = root_trees['porttree'].dbapi
  File "/usr/lib/portage/pym/portage/util/__init__.py", line 1374, in __getitem__
    result = lazy_item.func(*pargs, **kwargs)
  File "/usr/lib/portage/pym/portage/dbapi/porttree.py", line 1013, in __init__
    self.dbapi = portdbapi(mysettings=settings)
  File "/usr/lib/portage/pym/portage/dbapi/porttree.py", line 99, in __init__
    self._event_loop = EventLoop(main=False)
  File "/usr/lib/portage/pym/portage/util/_eventloop/EventLoop.py", line 67, in __init__
    self._poll_obj = _epoll_adapter(select.epoll())
IOError: [Errno 38] Function not implemented


Any ideas?
Back to top
View user's profile Send private message
Hu
Watchman
Watchman


Joined: 06 Mar 2007
Posts: 8617

PostPosted: Wed Nov 21, 2012 2:25 am    Post subject: Reply with quote

What is the output of emerge --info? If that does not work, what is the output of uname -a?
Back to top
View user's profile Send private message
Carnildo
Guru
Guru


Joined: 17 Jun 2004
Posts: 584

PostPosted: Wed Nov 21, 2012 2:50 am    Post subject: Reply with quote

The output of "emerge --info" can be seen in my first post; "uname -a" produces

Code:
Linux snail 2.4.37.11 #2 Tue Dec 28 14:55:32 PST 2010 i586 Pentium MMX GenuineIntel GNU/Linux
Back to top
View user's profile Send private message
The Doctor
Veteran
Veteran


Joined: 27 Jul 2010
Posts: 1269

PostPosted: Wed Nov 21, 2012 2:55 am    Post subject: Reply with quote

Are you trying to use python 3? If so go back to 2.7 an run python-updator
_________________
First things first, but not necessarily in that order.
Back to top
View user's profile Send private message
Carnildo
Guru
Guru


Joined: 17 Jun 2004
Posts: 584

PostPosted: Wed Nov 21, 2012 3:13 am    Post subject: Reply with quote

I'm running Python 2.7.
Back to top
View user's profile Send private message
Hu
Watchman
Watchman


Joined: 06 Mar 2007
Posts: 8617

PostPosted: Wed Nov 21, 2012 4:03 am    Post subject: Reply with quote

Carnildo wrote:
The output of "emerge --info" can be seen in my first post; "uname -a" produces

Code:
Linux snail 2.4.37.11 #2 Tue Dec 28 14:55:32 PST 2010 i586 Pentium MMX GenuineIntel GNU/Linux
Your kernel is out of date. Why are you using modern software on a pre-2.6 kernel?
Back to top
View user's profile Send private message
dol-sen
Developer
Developer


Joined: 30 Jun 2002
Posts: 2503
Location: Richmond, BC, Canada

PostPosted: Wed Nov 21, 2012 4:24 am    Post subject: Reply with quote

From the error that you got. Your portage code is mixed up with old and new files, or perhaps just some missing files. Portage does not rely on outside libraries for all the basic functionality.

I think you will probably have to do a manual fix of portage, using a rescue image. But if you have some other boxes with a working portage, you can copy the /usr/lib/portage dir onto a usb stick (or net transfer) and transfer it to the broken one.

Then re-sync and re-emrege portage again.

Hmm, If you are on a 2.4 kernel, is the rest of your system way out of date too?
_________________
Brian
Porthole, the Portage GUI frontend irc@freenode: #gentoo-guis, #porthole, Blog
layman, gentoolkit, CoreBuilder, esearch...
Back to top
View user's profile Send private message
Genone
Retired Dev
Retired Dev


Joined: 14 Mar 2003
Posts: 8995
Location: beyond the rim

PostPosted: Wed Nov 21, 2012 8:47 am    Post subject: Reply with quote

dol-sen wrote:
From the error that you got. Your portage code is mixed up with old and new files, or perhaps just some missing files. Portage does not rely on outside libraries for all the basic functionality.

Don't think it's an issue of mixed portage install, just the kernel being way outdated and not implementing the epoll() syscall python uses.
Back to top
View user's profile Send private message
Carnildo
Guru
Guru


Joined: 17 Jun 2004
Posts: 584

PostPosted: Wed Nov 21, 2012 10:15 am    Post subject: Reply with quote

Hu wrote:
Carnildo wrote:
The output of "emerge --info" can be seen in my first post; "uname -a" produces

Code:
Linux snail 2.4.37.11 #2 Tue Dec 28 14:55:32 PST 2010 i586 Pentium MMX GenuineIntel GNU/Linux
Your kernel is out of date. Why are you using modern software on a pre-2.6 kernel?

Why not? Most of it still works.

Genone wrote:
dol-sen wrote:
From the error that you got. Your portage code is mixed up with old and new files, or perhaps just some missing files. Portage does not rely on outside libraries for all the basic functionality.

Don't think it's an issue of mixed portage install, just the kernel being way outdated and not implementing the epoll() syscall python uses.

I looked into this, and the problem isn't that 2.4 doesn't support epoll, it's that the method Portage uses to detect a lack of epoll doesn't work. It's expecting that referring to "select.epoll" will throw an AttributeError, when what it should be doing is calling "select.epoll()" and looking for an IOError. Adjusting things accordingly gives me a working copy of Portage.
Back to top
View user's profile Send private message
zmedico
Developer
Developer


Joined: 02 Jan 2004
Posts: 284
Location: California USA

PostPosted: Thu Nov 22, 2012 12:26 pm    Post subject: Reply with quote

Carnildo wrote:
I looked into this, and the problem isn't that 2.4 doesn't support epoll, it's that the method Portage uses to detect a lack of epoll doesn't work. It's expecting that referring to "select.epoll" will throw an AttributeError, when what it should be doing is calling "select.epoll()" and looking for an IOError. Adjusting things accordingly gives me a working copy of Portage.


This is fixed in git:

http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=4cc3db2b37e3a0ee123f9c9c81aba56be543b383
_________________
Zac
Back to top
View user's profile Send private message
Carnildo
Guru
Guru


Joined: 17 Jun 2004
Posts: 584

PostPosted: Fri Nov 23, 2012 11:48 pm    Post subject: Reply with quote

zmedico wrote:
Carnildo wrote:
I looked into this, and the problem isn't that 2.4 doesn't support epoll, it's that the method Portage uses to detect a lack of epoll doesn't work. It's expecting that referring to "select.epoll" will throw an AttributeError, when what it should be doing is calling "select.epoll()" and looking for an IOError. Adjusting things accordingly gives me a working copy of Portage.


This is fixed in git:

http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=4cc3db2b37e3a0ee123f9c9c81aba56be543b383

I can confirm it works.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming 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