Click to See Complete Forum and Search --> : recompiling for vmware modules


geetha
07-08-2008, 11:51 PM
Hi all,

I am using Slackware 12.1 guest os in Vmware 1.0.1 on WinXp. I have installed minimal packages needs for kernel compilation,

I have installed below kernel,

kernel-source-2.6.24.5_smp-noarch-2
kernel-huge-2.6.24.5-i486-2
kernel-modules-2.6.24.5-i486-2
kernel-headers-2.6.24.5-x86-2

The uname -a lists,

root@ang191:~# uname -a
Linux ang191 2.6.24.5 #1 Mon Jul 7 12:33:19 IST 2008 i686 Intel(R) Core(TM)2 CPU 4400 @ 2.00GHz GenuineIntel GNU/Linux

Here is my kernel rebuilding steps,



#mv /boot/vmlinuz /boot/vmlinuz-old



#mv /boot/System.map /boot/System.map-old



#mv /boot/config /boot/config-old



After this, we'll make the system configure the kernel source using this new configuration with the following command:



#make mrproper



#make menuconfig



Enable the Modules needed for VMware, I have selected (*) not physically modules (M), I have followed below url adapted to slackware, http://gentoo-wiki.com/HOWTO_Install_Gentoo_on_VMware



#make



#make install



#make modules



#make modules_install



Copy the new build config to booting location



#cp .config /boot/config





Add the new kernel in lilo.conf file



#vi /etc/lilo.conf



# use a boot message with the standard menu:

#message = /boot/boot_message.txt



# Wait until the timeout to boot (if commented out, boot the

# first entry immediately):

prompt

# Timeout before the first entry boots.

# This is given in tenths of a second, so 600 for every minute:

timeout = 1200

lba32



# Override dangerous defaults that rewrite the partition table:

change-rules

reset

# VESA framebuffer console @ 1024x768x256

# vga = 773

# Normal VGA console

vga = normal

# VESA framebuffer console @ 1024x768x64k

# vga=791

# VESA framebuffer console @ 1024x768x32k

# vga=790

# VESA framebuffer console @ 1024x768x256

# vga=773

# VESA framebuffer console @ 800x600x64k

# vga=788

# VESA framebuffer console @ 800x600x32k

# vga=787

# VESA framebuffer console @ 800x600x256

# vga=771

# VESA framebuffer console @ 640x480x64k

# vga=785

# VESA framebuffer console @ 640x480x32k

# vga=784

# VESA framebuffer console @ 640x480x256

# vga=769

# End LILO global section

# Linux bootable partition config begins

image = /boot/vmlinuz

root = /dev/sda2

label = LinuxNew

read-only

# Linux bootable partition config ends




# Linux bootable partition config begins

image = /boot/vmlinuz-old

root = /dev/sda2

label = Linux

read-only

# Linux bootable partition config ends




Note: We have to add lba32 and vga=normal



Update the new kernel


#/sbin/lilo –v



I have installed vmware modules, vmmon and vmnet using



referred url - http://koo.fi/tech/2007/10/17/how-to-get-vmware-server-working-with-an-unsupported-kernel-and-the-vmware-any-any-patch/



After restarting, it is working fine on recompiled slackware.





Finally I have build kernel packages of modules and booting kernel using slackbuild scripts,



referred url - http://slackware.osuosl.org/slackware_source/k/



While installing these packages on new slackware with same configuration getting error



version magic error - " intel_agp: version magic '2.6.24.5 mod_unload 686' should be '2.6.24.5 mod_unload 486''



I have tried again but network not reachable, ip has not



I cant make out where I loss the configuration



Please help me , I am trying this for long time



Regards,

Geetha

furrycat
07-09-2008, 06:05 AM
> intel_agp: version magic '2.6.24.5 mod_unload 686' should be '2.6.24.5 mod_unload 486''

This message would appear if you compiled the kernel and modules with a different compiler or different compiler options. Since you recompiled them both together I would hazard a guess that perhaps you ended up booting the original kernel and tried to load your newly-compiled modules, or vice versa.

One of the options in the kernel configuration menu allows you to append a version string to your kernel, such that the /lib/modules path is different. For example /lib/modules/2.6.24.5-geetha. Doing this would eliminate the possibility of making the above mistake. As would downloading and building the latest available kernel.

geetha
07-09-2008, 06:40 AM
> intel_agp: version magic '2.6.24.5 mod_unload 686' should be '2.6.24.5 mod_unload 486''

This message would appear if you compiled the kernel and modules with a different compiler or different compiler options. Since you recompiled them both together I would hazard a guess that perhaps you ended up booting the original kernel and tried to load your newly-compiled modules, or vice versa.

I compiled the kernel and modules same compiler.. while menuconfig enabled (*) needs vmware devices then reboot with recompiled kernel.. after that installed the vmware modules.. finally build the tgz packages for both..

I need to install these packages to another new slackware guest..

first i loaded with old kernel and remove old one then installed my kernel and kernel module packages on new slackware guest.. I removed /lib/modules/2.6.24.5 before installing my kernel-module package.

I tried to installed slackware guest without kernel packages, but getting MBR error..

Can you explain me what is the procedure to install my own kernels without error?



One of the options in the kernel configuration menu allows you to append a version string to your kernel, such that the /lib/modules path is different. For example /lib/modules/2.6.24.5-geetha. Doing this would eliminate the possibility of making the above mistake. As would downloading and building the latest available kernel.

Thanks
geetha

furrycat
07-09-2008, 09:01 AM
You mentioned that you used the Slackbuild scripts to make your packages. Perhaps things got mixed up here.

You could make a package by hand and see if that works.# mkdir /tmp/build
# cd /
# tar cp boot/vmlinuz lib/modules/2.6.24.5 | tar xp -C /tmp/build
# cd /tmp/build
# makepkg /tmp/kernel-2.6.24.5-i686-1geetha.tgzNote that this is just a proof of concept package and that you'd need to run lilo yourself after installing it. It's inelegant but that's what virtual machines are for.

> I tried to installed slackware guest without kernel packages, but getting MBR error..

Such an error would be consistent with lilo not being installed. As it could not be if there are no kernels to boot.

> Can you explain me what is the procedure to install my own kernels without error?

You've pretty much got it. Compile your kernel and modules and either build a package or dump the directory tree on to your destination machine and run lilo. Although you're experiencing the frustration of it not working you are doing essentially the right thing.

geetha
07-10-2008, 01:50 AM
Thanks for your valuable guide..

So far i didnt update lilo file on destination guest.. I got my mistake..


Thanks a lot.. :)