public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Alan McKinnon <alan.mckinnon@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Removing Packages with Portage
Date: Mon, 4 May 2009 13:08:53 +0200	[thread overview]
Message-ID: <200905041308.53676.alan.mckinnon@gmail.com> (raw)
In-Reply-To: <ac71f2bb0905040245w378969d0x2bd4285de92e9649@mail.gmail.com>

On Monday 04 May 2009 11:45:00 Matt Causey wrote:
> Hello all!
>
> I am a Gentoo n00b.  I have  question about what the 'expected
> behaviour' is/should be when removing packages under Gentoo package
> management.  So I read this document:
>
> http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?style=printable&full
>=1#book_part2
>
> And it says, to remove software, use  'emerge --unmerge'.  Cool, yeah
> that seems to do what I expect... So, I have a package madwifi-ng,
> which contains some kernel modules.  I want to emerge --unmerge that
> package, because I want to make those drivers go away.  That seems to
> go well, as when I search for it in portage it show all non-installed
> and stuff:
>
> prometheus ~ # emerge --search madwifi-ng
> Searching...
> [ Results for search key : madwifi-ng ]
> [ Applications found : 2 ]
>
> *  net-wireless/madwifi-ng
>       Latest version available: 0.9.4
>       Latest version installed: [ Not Installed ]
>       Size of files: 3,403 kB
>       Homepage:      http://www.madwifi-project.org/
>       Description:   Next Generation driver for Atheros based IEEE
> 802.11a/b/g wireless LAN cards
>       License:       atheros-hal || ( BSD GPL-2 )
>
> Buuut, there are still kernel modules there, which are owned by that
> package:
>
> prometheus ~ # ls -lah /lib/modules/2.6.28-gentoo-r5/net/ath_pci.ko
> -rw-r--r-- 1 root root 77K May  3 20:43
> /lib/modules/2.6.28-gentoo-r5/net/ath_pci.ko
> prometheus ~ #
>
> and of course they still load.
>
> Sooo, my question.  What is the expected behaviour here?  Are the
> ebuilds intended to maintain knowledge of the files they put on a
> system, so they can remove the binaries when --unmerge'd?  

That's the general idea. Except for *this* case :-)

> Are kernel
> modules handled differently because of the possibility of damaging a
> working system?

Out of tree kernel modules are a maintenance pain in the ass, and cause 
severely non-obvious problems like this. Every time you upgrade your kernel, 
you must rebuild the out-of-tree modules, and you do that by re-running 
"emerge madwifi-ng". This builds a new modules that matches the currently 
configured kernel (/usr/src/linux/) and puts the module in 
/lib/modules/<version>

Upgrade your kernel a few times and you have various versions of modules 
floating around. Portage remembers the modules installed by the most recent 
emerge, but AFAIK forgets all the previous ones. This is expected of course - 
when you upgrade firefox-2 to firefox-3 you would not expect the system to 
remember the firefox-2 files (as they are supposed to not be there anymore)

-- 
alan dot mckinnon at gmail dot com



  parent reply	other threads:[~2009-05-04 11:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-04  9:45 [gentoo-user] Removing Packages with Portage Matt Causey
2009-05-04  9:55 ` Neil Bothwick
2009-05-04 11:14   ` KH
2009-05-04 11:08 ` Alan McKinnon [this message]
2009-05-04 12:11   ` Matt Causey
2009-05-04 14:54     ` Alan McKinnon
2009-05-04 15:11     ` Daniel Iliev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200905041308.53676.alan.mckinnon@gmail.com \
    --to=alan.mckinnon@gmail.com \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox