Welcome to the Linux Foundation Forum!

Lab 21.3 NBD Kernel Module Not Loading!!!

Options

When attemptng task 6: "Install the nbd kernel module, verify the block devices are present." on my raspberry pi running ubuntu, I get:
modprobe: "FATAL: Module nbd not found in directory /lib/modules/6.2.0-1010-raspi"
However, both the nbd-client and nbd-server modules are installed and working. Also the command: "lsmod | grep nbd" returns nothing.

The command ls /dev/nbd* returns:
"ls: cannot access '/dev/nbd*': No such file or directory"

The web is not very helpful on this one. I tried updating/upgrading packages but that hasn't worked either. If anyoneknows of a potential solution I would definitely appreciate it!
Thanks!!!

Answers

  • luisviveropena
    Options

    Hi @tpcm,

    I don't have a Raspberry Pi, so I can't do any test on it. So I tested the lab on Ubuntu 22.04.2 LTS on a VM, and it worked.

    modprobe: "FATAL: Module nbd not found in directory /lib/modules/6.2.0-1010-raspi"
    However, both the nbd-client and nbd-server modules are installed and working. Also the command: >"lsmod | grep nbd" returns nothing.

    Did you execute the 'sudo modprobe -i nbd' command? After that the devices on /dev/nbd* should be created.

    On my system I see the nbd module loaded:

    luis@ubuntuserver:~$ lsmod | grep nbd
    nbd 61440 1

    I recommend you to try in a VM using x86_64, so I can assist you more properly.

    Regards,
    Luis.

  • tpcm
    tpcm Posts: 6
    Options

    Hi @luisviveropena , thanks for getting back to me.
    Yeah I executed that command and got:
    thomas@thomas-desktop:~$ sudo modprobe -i nbd
    [sudo] password for thomas:
    modprobe: FATAL: Module nbd not found in directory /lib/modules/6.2.0-1011-raspi

    I have now spun up an Ubutu VM and its working, thanks for the suggestion.

    Do you think building the module from source is feasible if I want it to run on my pi?

    Thanks again!

  • luisviveropena
    Options

    Hi @tpcm,

    It's a pleasure!

    I have now spun up an Ubutu VM and its working, thanks for the suggestion.

    That's good :)

    Do you think building the module from source is feasible if I want it to run on my pi?

    In this case I would want to ask you: why do you want to do it on your Raspberry Pi?
    Well, you would need to recompile the kernel from the sources, including the support for the specific module we are talking about. There is documentation in the official website that you can take a look at:

    https://www.raspberrypi.com/documentation/computers/linux_kernel.html

    I hope that helps.

    Regards,
    Luis.

Categories

Upcoming Training