NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.

Forum Discussion

croque's avatar
croque
Aspirant
Nov 27, 2013

Compiling ppp-modules on ReadyNAS OS 6.1.4: invalid module f

I tried to compile and install the ppp-modules on a RN314 with no luck. I downloaded the source and set it up in /usr/src/linux. Did a

make oldconfig
make menuconfig
make prepare
make modules

installed the modules manaully with installl -m 744 under the /lib/modules/$(uname -r)/kernel directory. Updated with 'depmod -a' and the modules are now listed in modprobe -l. When trying to load it with modprobe ppp_generic I got the

modprobe: can't load module slhc (kernel/drivers/net/slhc.ko): invalid module format

The gcc versions shows:
gcc (Debian 4.7.2-5) 4.7.2

/proc/version shows
Linux version 3.0.93.RNx86_64.2.1 (jenkins@blocks) (gcc version 4.7.2 (Debian 4.7.2-5) ) #1 SMP Mon Sep 30 11:46:22 PDT 2013

Inspecting the module with 'modinfo ppp_generic' shows:
filename: kernel/drivers/net/ppp_generic.ko
license: GPL
vermagic: 3.0.93.RNx86_64.2.1 SMP mod_unload modversions
depends: slhc

Inspecting a (random) loaded module from the ReadyNAS OS6 6.1.4 distribution shows
filename: kernel/drivers/media/rc/ir-rc6-decoder.ko
description: RC6 IR protocol decoder
author: David Härdeman <david@hardeman.nu>
license: GPL
vermagic: 3.0.93.RNx86_64.2.1 SMP mod_unload modversions
depends: rc-core

So the module information seems to be the same for my newly compiled module and the out-of-the-box-delivered module.

I browsed the forum but did not se a solution for similar problem. Anyone could have an idea what the problem is?

3 Replies

Replies have been turned off for this discussion
  • Tried copying defconfig.smp over .config, not using oldconfig ?
  • This question I can answer myself after doing some more research. The problem was the lack of the Module.symvers.

    From kernel.org (https://www.kernel.org/doc/Documentation/kbuild/modules.txt):
    NOTE: "modules_prepare" will not build Module.symvers even if CONFIG_MODVERSIONS is set; therefore, a full kernel build needs to be

    Right workflow for building modules is:

    make oldconfig
    make menuconfig
    make prepare
    make modules_prepare
    make
    make SUBDIRS=scripts/mod
    make SUBDIRS=path/to/module modules

    installation and depmot -a. Now my modules loads like a charm. =)

NETGEAR Academy

Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology! 

Join Us!

ProSupport for Business

Comprehensive support plans for maximum network uptime and business peace of mind.

 

Learn More