Gentoo Archives: gentoo-user

From: "András Csányi" <sayusi.ando@××××××.hu>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] list of kernel modules
Date: Fri, 06 Apr 2012 15:03:45
In Reply to: Re: [gentoo-user] list of kernel modules by Joshua Murphy
On 6 April 2012 16:43, Joshua Murphy <poisonbl@×××××.com> wrote:
> On Fri, Apr 6, 2012 at 10:02 AM, András Csányi <sayusi.ando@××××××.hu> wrote: >> Dear All, >> >> I'm a little bit confused regarding modprobe command. As far as I >> remember I used the command below to list all of kernel modules >> independently it's loaded or not. >> modprobe -l or modprobe -L >> >> But now I can see that there is no -l or -L for this command. When >> have changed this command or my memories are failed? On the other >> hand, I would like to ask that how can I list all of kernel modules? >> >> Thanks in advance! >> >> András >> >> -- >> --  Csanyi Andras (Sayusi Ando)  -- -- >> >> --  ""Trust in God and keep your gunpowder dry!" - Cromwell > > From 'man modprobe' here (module-init-tools version 3.16): >    -l --list >    List all modules matching the given wildcard (or "*" if no > wildcard is given).  This option is provided for backwards > compatibility and  may go away in future: see find(1) and basename(1) > for a more flexible alternative. > > > And, found this handy little 'replacement' of sorts (in .bashrc or > such, not tested by me): > > fkm() { >  local kver=$(uname -r) arg=${1//[-_]/[-_]} >  find "/lib/modules/$kver" -iname "*$arg*.ko*" \ >    -exec bash -c 'mods=("${@##*/}"); printf "%s\n" "${mods[@]%.ko*}"' _ {} + > >  if [[ ! -e /lib/modules/$kver/kernel ]]; then >    echo "reboot!" >&2 >  fi > } > > (source: )
Thanks Guys! The situation at my machine is the next and it looks like I have to use one of your handy tools. :) a-home log # eix -s module-init-tools * sys-apps/module-init-tools Available versions: 3.5!t (~)3.6-r1!t (~)3.8 (~)3.9 (~)3.10 (~)3.11 (~)3.11.1 (~)3.12 3.12-r1!t (~)3.13!t (~)3.16!t 3.16-r1!t {{old-linux static}} Homepage: Description: tools for managing linux kernel modules sa-home log # emerge -avt module-init-tools These are the packages that would be merged, in reverse order: Calculating dependencies... done! [ebuild N ] sys-apps/module-init-tools-3.16-r1 USE="-static" 233 kB [blocks B ] sys-apps/module-init-tools ("sys-apps/module-init-tools" is blocking sys-apps/kmod-7) [blocks B ] sys-apps/kmod ("sys-apps/kmod" is blocking sys-apps/module-init-tools-3.16-r1) Total: 1 package (1 new), Size of downloads: 233 kB Conflict: 2 blocks (2 unsatisfied) * Error: The above package list contains packages which cannot be * installed at the same time on the same system. (sys-apps/kmod-7::gentoo, installed) pulled in by >=sys-apps/kmod-5 required by (sys-fs/udev-182-r3::gentoo, installed) sys-apps/kmod required by (virtual/modutils-0::gentoo, installed) (sys-apps/module-init-tools-3.16-r1::gentoo, ebuild scheduled for merge) pulled in by module-init-tools For more information about Blocked Packages, please refer to the following section of the Gentoo Linux x86 Handbook (architecture is irrelevant): sa-home log # -- --  Csanyi Andras (Sayusi Ando)  -- -- --  ""Trust in God and keep your gunpowder dry!" - Cromwell