Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

vboxdrv setup says src/kernel don't match [solved]

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

vboxdrv setup says src/kernel don't match [solved]

#1 Post by nadir »

I did: /etc/init.d/vboxdrv setup

Code: Select all

# cat /var/log/vbox-install.log 
Makefile:170: *** Error: /usr/src/linux (version 2.6.36-rc5) does not match the current kernel (version 2.6.36-rc5-mt-localmodconfig-0).  Stop.

Code: Select all

# ls -l /lib/modules/2.6.36-rc5-mt-localmodconfig-0/build
lrwxrwxrwx 1 root root 54 Oct  1 23:13 /lib/modules/2.6.36-rc5-mt-localmodconfig-0/build -> /usr/src/linux-headers-2.6.36-rc5-mt-localmodconfig-0/
# ls -l /lib/modules/2.6.36-rc5-mt-localmodconfig-0/source
lrwxrwxrwx 1 root root 51 Oct  1 12:51 /lib/modules/2.6.36-rc5-mt-localmodconfig-0/source -> /home/m1arkust/Kernel/Linux/linux-source-2.6.36-rc5
In this old thread i found some ln commands:

Code: Select all

    ln -nfs  /usr/src/linux-headers-2.6.26mt1/ build
but that did not help.
Last edited by nadir on 2010-10-11 19:18, edited 1 time in total.
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

User avatar
craigevil
Posts: 5391
Joined: 2006-09-17 03:17
Location: heaven
Has thanked: 28 times
Been thanked: 39 times

Re: vboxdrv setup says src/kernel don't match

#2 Post by craigevil »

No problems using the liquorix kernel.

/lib/modules/2.6.35-6.dmz.2-liquorix-686/misc/vboxdrv.ko
/lib/modules/2.6.35-6.dmz.2-liquorix-686/misc/vboxnetadp.ko
/lib/modules/2.6.35-6.dmz.2-liquorix-686/misc/vboxnetflt.ko

But I am lazy I just use svmi. http://smxi.org/site/about.htm#svmi

$ apt-cache policy virtualbox-ose
virtualbox-ose:
Installed: 3.2.8-dfsg-2
Candidate: 3.2.8-dfsg-2
Version table:
*** 3.2.8-dfsg-2 0
500 http://mirrors.kernel.org/debian/ sid/main i386 Packages
100 /var/lib/dpkg/status
Raspberry PI 400 Distro: Raspberry Pi OS Base: Debian Sid Kernel: 5.15.69-v8+ aarch64 DE: MATE Ram 4GB
Debian - "If you can't apt install something, it isn't useful or doesn't exist"
My Giant Sources.list

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: vboxdrv setup says src/kernel don't match

#3 Post by nadir »

What?
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: vboxdrv setup says src/kernel don't match

#4 Post by nadir »

I have thought i would already know it, but it never hurts to check stuff:
Please type the appropriate number and hit enter
------------------------------------------------------------------
1) virtualbox-options 4) build-vbox-module-non-ose
2) vmware-options 5) build-vmplayer-module
3) build-vbox-module-ose 6) quit

Running /etc/init.d/vboxdrv setup on virtualbox-3.2...
Stopping VirtualBox kernel module:done..
Recompiling VirtualBox kernel module:
Look at /var/log/vbox-install.log to find out what went wrong ... failed!
FATAL: Module vboxdrv not found.
vboxdrv module should now be up and running.
------------------------------------------------------------------
Please hit enter to continue
------------------------------------------------------------------
I got problems to understand why running a single command from cli should give a different output than running it from a script (or if there really is the need for a script, where i gotta make several select-menu choices before i can do what needs to be done, instead of running the command straight from cli).
I guess there is an smxi script which explains that to me too...
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

User avatar
stevepusser
Posts: 12930
Joined: 2009-10-06 05:53
Has thanked: 41 times
Been thanked: 71 times

Re: vboxdrv setup says src/kernel don't match

#5 Post by stevepusser »

It sure looks like you ( or somebody) rebuilt your kernel and ran localmodconfig during the config to strip out the drivers you did not need. I always end up with screwed up header symlinks for my homebuilt kernel too, but these commands remove the links and remake them for the running kernel. (as root)

c

Code: Select all

d /lib/modules/$(uname -r)
rm build
rm source
ln -s /usr/src/linux-headers-$(uname -r) build
ln -s /usr/src/linux-headers-$(uname -r) source
You can also stick those into a little script.
MX Linux packager and developer

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: vboxdrv setup says src/kernel don't match

#6 Post by nadir »

Thanks.
I am sure i did that, but you know how it is...

Yes, localmodconfig, you are right (i first tried to cp the config of the localmodconfig-35-kernel, but that didn't work at all).
I did check manually (during make menuconfig) the things that i know of (but that are not very much).

----------------------
In the meantime i ran into a different problem:
I booted into the 35-localmodconfig-kernel and vboxdrv-module got loaded just fine (during boot). So as a test i ran "/etc/init.d/vboxdrv setup" and that failed too. What? The error message is a complete different one:
warning: "LINUX_VERSION_CODE" is not defined ...
Now i was in a bad mood. I did like you said: remove the old links and set them new and at least that kernel does boot again.

Will try to first remove source/build again with the new (36-) kernel
(will also put it in a script: as a reminder what to link from where to where :wink: Good idea)

For now i am happy that my "old" 35-kernel is up and running again.

[0] search results for the new error (just as a reference):
http://www.google.co.uk/search?hl=en&q= ... tnG=Search
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: vboxdrv setup says src/kernel don't match

#7 Post by nadir »

Didn't work for the 36-kernel.
Error-message stays the same:
Makefile:170: *** Error: /usr/src/linux (version 2.6.36-rc5) does not match the current kernel (version 2.6.36-rc5-mt-localmodconfig-0). Stop.
Searching for that leads from nowhere to eternity.

Does anyone know which modules are needed in the kernel for Vbox to work?
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: vboxdrv setup says src/kernel don't match

#8 Post by nadir »

I have asked at the #kernel IRC and got some advice and info there
(in case you are here too, with a different nick: thanks again)
I decided to compile again, this time i left away the --append-to-version string:

Code: Select all

$ fakeroot make-kpkg   --revision  "101003" --initrd kernel_headers kernel_image
/etc/init.d/vboxdrv setup
failed again, but at a later point. So i got new error-messages:

Code: Select all

make[2]: *** [/tmp/vbox.0/linux/VBoxNetAdp-linux.o] Error 1
And voila, second result from my web-search:
http://www.virtualbox.org/ticket/7507

As i understand it is the most easy solution: waiting (why the --append-to-version gave me naming-mismatch trouble is still beyond me...)
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

User avatar
nadir
Posts: 5961
Joined: 2009-10-05 22:06
Location: away

Re: vboxdrv setup says src/kernel don't match

#9 Post by nadir »

Todays upgrade of VirtualBox (PUEL) solved the issue. [0]
/etc/init.d/vboxdrv setup ; like usual. A bit of odd output, which i will investigate later (well: i won't, cause i can't reproduce it... if someone runs into it write it down, it is not in the log)

$ apt-cache policy virtualbox-3.2
virtualbox-3.2:
Installed: 3.2.10-66523~Debian~squeeze
Candidate: 3.2.10-66523~Debian~squeeze
Version table:
*** 3.2.10-66523~Debian~squeeze 0
500 http://download.virtualbox.org/virtualbox/debian/ squeeze/non-free i386 Packages
100 /var/lib/dpkg/status

[0] as far i can tell.
"I am not fine with it, so there is nothing for me to do but stand aside." M.D.

fazul
Posts: 1
Joined: 2010-10-22 15:31

Re: vboxdrv setup says src/kernel don't match [solved]

#10 Post by fazul »

Hi,

I tried stevepusser's suggestion but the compilation still failed for me (using kernel 2.6.36 and virtualbox 3.2.10). As I'm sure that my kernel's version is correct, I just commented out the following (in the three Makefiles in /usr/src/vboxhost-3.2.10/vboxdrv/, /usr/src/vboxhost-3.2.10/vboxnetadp/ and /usr/src/vboxhost-3.2.10/vboxnetflt/):

# ifneq ($(VBOX_KERN_VER),)
# ifneq ($(VBOX_KERN_VER),$(shell uname -r))
# $(error Error: /usr/src/linux (version $(VBOX_KERN_VER)) does not match \
# the current kernel (version $(shell uname -r)))
# endif
# endif

Afterwards "/etc/init.d/vboxdrv setup" worked as usual.

Regards.

Post Reply