Performance Tools for Software Developers - Warning message: Current running kernel is version...

Symptom(s):

When executing the build-driver script (part of the VTune™ Amplifier XE for Linux* performance profiler), you see a message similar to the following:

Warning: current running kernel is version 2.4.18-e.31smp

And, after successfully building the driver and invoking insmod-sep3, you get the message:

No pre-built driver exists for this system.

Cause:
The kernel sources are not configured, correctly, that is, they do not match the kernel that is running.

Solution:

To configure the kernel sources, execute the following commands:

cd /usr/src/linux
make mrproper
cp /boot/config-`uname-r` .config
vi Makefile # check EXTRAVERSION, change if necessary
make oldconfig
make dep

Prior to make oldconfig, ensure that EXTRAVERSION matches the tail of the output of uname -r. The resulting /usr/src/linux/include/version.h should have a UTS_RELEASE that matches the output of uname -r. Once that is true, run the build-driver script to build the sampling driver against the kernel sources in /usr/src/linux.

Operating System:

Linux*
 
For more complete information about compiler optimizations, see our Optimization Notice.