Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Can't load some modules / wrong module directory?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Daemon14
Tux's lil' helper
Tux's lil' helper


Joined: 05 Feb 2005
Posts: 120
Location: Poland / Colombia

PostPosted: Wed Jun 02, 2021 5:13 pm    Post subject: [SOLVED] Can't load some modules / wrong module directory? Reply with quote

Hi everyone,
I've just successfully built Gentoo with LTO overlay, everything emerged without any problem, it boots, X starts etc but while booting I get:
Quote:
Warning: /lib/modules/5.10.34-1-lts/modules.devname not found - ignoring

and as a result it doesn't load some modules, I'm lacking wifi, mouse and sound (maybe something else but I haven't discovered it yet). I use gentoo-sources-5.12.8 and it's the only directory I have in /lib/modules so everything seems ok. I looked up for modules and they are in /lib/modules/5.12.8-gentoo-x86_64/kernel as they should but they don't load. I tried to load some of the missing modules but I got:
Quote:
FATAL: modules bfusb not found in directory /lib/modules/5.10.34-1-lts


Interestingly, plenty of modules loaded correctly, e.g. video, I can start X without any issues, I noticed e1000 for ethernet loaded as well.

Where does /lib/modules/5.10.34-1-lts come from? Why would it even look for modules in this directory if my only kernel I built is 5.12.8-gentoo-x86_64?

I don't know if this information may be useful:
I build the whole system using LTO overlay and Gold linker. In order to build kernel I switched to BFD as necessary. I used genkernel.

emerge --info
Quote:
Portage 3.0.19 (python 3.9.5-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-10.3.0, glibc-2.33, 5.12.8-gentoo-x86_64 x86_64)
=================================================================
System uname: Linux-5.12.8-gentoo-x86_64-x86_64-Intel-R-_Core-TM-_i5-4300M_CPU_@_2.60GHz-with-glibc2.33
KiB Mem: 8062912 total, 3441324 free
KiB Swap: 0 total, 0 free
Timestamp of repository gentoo: Wed, 02 Jun 2021 02:30:01 +0000
Head commit of repository gentoo: da82f78f72dc94513ac6e27a9b18a722f9ea3421
sh bash 5.1_p8
ld GNU gold (Gentoo 2.35.2 p1 2.35.2) 1.16
ccache version 4.3 [disabled]
app-shells/bash: 5.1_p8::gentoo
dev-java/java-config: 2.3.1::gentoo
dev-lang/perl: 5.34.0::gentoo
dev-lang/python: 2.7.18_p10::gentoo, 3.8.10_p1::gentoo, 3.9.5_p1::gentoo, 3.10.0_beta2::gentoo
dev-lang/rust: 1.52.1::gentoo
dev-util/ccache: 4.3::gentoo
dev-util/cmake: 3.20.3::gentoo
sys-apps/baselayout: 2.7-r2::gentoo
sys-apps/openrc: 0.43.3::gentoo
sys-apps/sandbox: 2.24::gentoo
sys-devel/autoconf: 2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake: 1.16.3-r1::gentoo
sys-devel/binutils: 2.35.2::gentoo, 2.36.1-r1::gentoo
sys-devel/gcc: 10.3.0::gentoo
sys-devel/gcc-config: 2.4::gentoo
sys-devel/libtool: 2.4.6-r6::gentoo
sys-devel/make: 4.3::gentoo
sys-kernel/linux-headers: 5.12::gentoo (virtual/os-headers)
sys-libs/glibc: 2.33::gentoo
Repositories:

gentoo
location: /var/db/repos/gentoo
sync-type: rsync
sync-uri: rsync://rsync.gentoo.org/gentoo-portage
priority: -1000
sync-rsync-extra-opts:
sync-rsync-verify-max-age: 24
sync-rsync-verify-jobs: 1
sync-rsync-verify-metamanifest: yes

lto-overlay
location: /var/lib/layman/lto-overlay
masters: gentoo mv
priority: 50

mv
location: /var/lib/layman/mv
masters: gentoo
priority: 50

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=haswell -mtune=haswell -O3 -pipe -s -fgraphite-identity -floop-nest-optimize -fdevirtualize-at-ltrans -fipa-pta -fno-semantic-interposition -flto=auto -fuse-linker-plugin -falign-functions=32"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LC_ALL="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-flto=5"
LINGUAS="en en_US en_GB"
MAKEOPTS="-j5"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="7z 7zip X a52 aac acl acpi activities alsa amd64 berkdb bluetooth branding brightness-control browser-integration bzip2 cairo cdda cddb cdr chromium cli colord connman crypt cups custom-optimization dbus declarative default-gold dhcp djvu dos dri dropbox dts dvd dvdr egl elogind emboss encode exif faad ffmpeg fftw flac fortran frei0r gdbm gif gles2 google googledrive graphite grub gstreamer gtk gui iconv icu initramfs inspector ipv6 iwd jpeg kate kde kdesu kipi kwallet lcms libcaca libglvnd libidn2 libinput libkms libmpv libnotify libtirpc lm-sensors lto mad minizip mng modplug mp3 mp4 mpd mpeg mpv multilib musepack n230 ncurses network nfs nls nptl nss ogg opengl openh264 openmp pam pango pcre pdf pgo phonon plasma plugin plymouth png policykit postgres ppds pulseaudio python qml qrcode qt5 rar readline screencast sddm sdl seccomp semantic-desktop share spell split-usr ssh ssl staging startup-notification svg taglib tcpd test-va-api theora tiff tools truetype udev udisks unicode upower usb usb-monitor utils uxa v4l vaapi vnc vorbis vpx wayland weather webp widevine widgets wifi wireless wxwidgets x264 x265 xattr xcb xml xscreensaver xv xvid zip zlib" ABI_X86="64" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt rdrand sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="mouse keyboard evdev synaptics libinput" KERNEL="linux" L10N="en en-US en-GB" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_9" PYTHON_TARGETS="python3_9" RUBY_TARGETS="ruby26 ruby27" USERLAND="GNU" VIDEO_CARDS="intel i965" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset: CC, CPPFLAGS, CTARGET, CXX, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS


any ideas?
_________________
Dell Optiplex 7010 / CPU Core i7-3770K / RAM 16GB Patriot Viper III / GTX 1050 2GB / SSD 500GB + 2x HDD 2TB
Dell Latitude E6440 / CPU Core i5-4300M / RAM 8GB / SSD 120GB + HDD 500GB


Last edited by Daemon14 on Wed Jun 02, 2021 6:17 pm; edited 1 time in total
Back to top
View user's profile Send private message
alamahant
Advocate
Advocate


Joined: 23 Mar 2019
Posts: 3879

PostPosted: Wed Jun 02, 2021 5:26 pm    Post subject: Reply with quote

Bad kernel
Here is mine
Code:

ls /lib/modules/5.12.5-gentoo
block   modules.alias              modules.builtin.bin      modules.devname  modules.symbols.bin
build   modules.alias.bin          modules.builtin.modinfo  modules.order    source
extra   modules.builtin            modules.dep              modules.softdep  video
kernel  modules.builtin.alias.bin  modules.dep.bin          modules.symbols

Compile a new fresh kernel...
Where did you get
5.10.34-1-lts
How did you build it?
_________________
:)
Back to top
View user's profile Send private message
Daemon14
Tux's lil' helper
Tux's lil' helper


Joined: 05 Feb 2005
Posts: 120
Location: Poland / Colombia

PostPosted: Wed Jun 02, 2021 5:35 pm    Post subject: Reply with quote

Quote:
Where did you get
5.10.34-1-lts
How did you build it?


that's actually my question. I have no idea where it comes from. I have a fresh Gentoo installation and the only kernel I built is 5.12.8-gentoo.

ls /lib/modules/
Quote:
5.12.8-gentoo-x86_64


all modules I need are in this directory, some of them load automatically but when I try to modprobe the missing ones, it tries to load them from /lib/modules/5.10.34-1-lts which doesn't even exist
_________________
Dell Optiplex 7010 / CPU Core i7-3770K / RAM 16GB Patriot Viper III / GTX 1050 2GB / SSD 500GB + 2x HDD 2TB
Dell Latitude E6440 / CPU Core i5-4300M / RAM 8GB / SSD 120GB + HDD 500GB
Back to top
View user's profile Send private message
alamahant
Advocate
Advocate


Joined: 23 Mar 2019
Posts: 3879

PostPosted: Wed Jun 02, 2021 5:40 pm    Post subject: Reply with quote

Plz try
Code:

ls /boot
ls -l /usr/src
uname -r
grub-mkconfig -o /boot/grub/grub.cfg

_________________
:)
Back to top
View user's profile Send private message
Daemon14
Tux's lil' helper
Tux's lil' helper


Joined: 05 Feb 2005
Posts: 120
Location: Poland / Colombia

PostPosted: Wed Jun 02, 2021 5:52 pm    Post subject: Reply with quote

ls /boot
Code:

amd-uc.img  initramfs-5.12.8-gentoo-x86_64.img      System.map-5.12.8-gentoo-x86_64      vmlinuz-5.12.8-gentoo-x86_64
grub        initramfs-5.12.8-gentoo-x86_64.img.old  System.map-5.12.8-gentoo-x86_64.old  vmlinuz-5.12.8-gentoo-x86_64.old


ls /usr/src
Code:
linux  linux-5.12.8-gentoo


uname -a
Code:
Linux DellE6440 5.12.8-gentoo-x86_64 #1 SMP Fri May 28 17:48:06 EDT 2021 x86_64 Intel(R) Core(TM) i5-4300M CPU @ 2.60GHz GenuineIntel GNU/Linux


grub-mkconfig -o /boot/grub/grub.cfg
Code:
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-5.12.8-gentoo-x86_64
Found initrd image: /boot/amd-uc.img /boot/initramfs-5.12.8-gentoo-x86_64.img
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
done

_________________
Dell Optiplex 7010 / CPU Core i7-3770K / RAM 16GB Patriot Viper III / GTX 1050 2GB / SSD 500GB + 2x HDD 2TB
Dell Latitude E6440 / CPU Core i5-4300M / RAM 8GB / SSD 120GB + HDD 500GB
Back to top
View user's profile Send private message
alamahant
Advocate
Advocate


Joined: 23 Mar 2019
Posts: 3879

PostPosted: Wed Jun 02, 2021 5:54 pm    Post subject: Reply with quote

Perfect
Just reboot and it should be ok.
_________________
:)
Back to top
View user's profile Send private message
Daemon14
Tux's lil' helper
Tux's lil' helper


Joined: 05 Feb 2005
Posts: 120
Location: Poland / Colombia

PostPosted: Wed Jun 02, 2021 6:17 pm    Post subject: Reply with quote

ok, it solved. The problem was that I was building it from my "main" Gentoo system, in chroot. In order to boot the "second" system I was using SystemRescueCD, the module directory probably came from it.
grub-mkconfig doesn't discover both systems. I have my main, working system on sda1 and the new, experimental one on sda2. So now I have access to the sda2 system but not to the sda1 one.
But anyway, thanks for your ideas!
_________________
Dell Optiplex 7010 / CPU Core i7-3770K / RAM 16GB Patriot Viper III / GTX 1050 2GB / SSD 500GB + 2x HDD 2TB
Dell Latitude E6440 / CPU Core i5-4300M / RAM 8GB / SSD 120GB + HDD 500GB
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware 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