WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: How to recompile the kernel?  (Read 16062 times)

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to recompile the kernel?
« Reply #15 on: September 07, 2014, 02:20:53 PM »
No, this can be used if you want to build one module without needing to compile all of them

Offline lid

  • Jr. Member
  • **
  • Posts: 62
Re: How to recompile the kernel?
« Reply #16 on: September 07, 2014, 05:52:49 PM »
No, this can be used if you want to build one module without needing to compile all of them

So this file has all the modules from the kernel make process?

Another quick question: Is linux-3.8.13-patched.txz  the kernel already patched for TC? In other words, do I need to patch it with the TC patches?




Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11704
Re: How to recompile the kernel?
« Reply #17 on: September 07, 2014, 07:58:45 PM »
hi lid
The patches are already applied to that version.

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to recompile the kernel?
« Reply #18 on: September 08, 2014, 12:10:59 AM »
No, the file has the deps for all of the modules rather than the modules themselves

Offline lid

  • Jr. Member
  • **
  • Posts: 62
Re: How to recompile the kernel?
« Reply #19 on: September 08, 2014, 04:39:19 PM »
No, the file has the deps for all of the modules rather than the modules themselves

Here is my first build attempt on a RHEL6 server. My target machine is also a x86_64.

1. Downloaded config-3.8.13-tinycore64 (renamed it to .config) and linux-3.8.13-patched.
2. make ARCH=x86_64 silientoldconfig
3. make ARCH=x86_64 and copied the arch/x86_64/boot/bzImage to my PXEboot server as vmlinuz
4. The initrd files are the same as before. The first initrd file was extracted from Core-current.iso and second one is what I built myself that includes the Broadcom NIC driver.  They both worked well in previous PXE boots using the vmlinuz extracted from Core-current.iso.
5. Now reboot using the newly built vmlinuz.  It booted up ok but it didn't seem to load my second initrd and so my NIC card doesn't work anymore.
6. Also this new vmlinuz is 3.3 MB compare to 2.9 MB of the previous one.

Any idea what's wrong with step 5?




Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to recompile the kernel?
« Reply #20 on: September 09, 2014, 12:40:30 AM »
The gcc version used with rhel is causing the problem?

Offline lid

  • Jr. Member
  • **
  • Posts: 62
Re: How to recompile the kernel?
« Reply #21 on: September 09, 2014, 12:40:55 PM »
The gcc version used with rhel is causing the problem?

Hmm, not quite sure why GCC version might have caused this. Here is the info:

$ gcc --version
gcc (GCC) 4.4.5 20110214 (Red Hat 4.4.5-6)


Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: How to recompile the kernel?
« Reply #22 on: September 09, 2014, 01:26:10 PM »
I mentioned it because we've seen issues with re-compiling the x86_64 kernel using the tc gcc extension that do not appear with the x86 kernel, not with Curaga's cross-compiler extension

Offline lid

  • Jr. Member
  • **
  • Posts: 62
Re: How to recompile the kernel?
« Reply #23 on: September 10, 2014, 01:15:31 PM »
The gcc version used with rhel is causing the problem?

I set up a VM using microcore, installed coreplay2's linux-kernel-source-env extension and ran the script. It seems it sets up the build environment nicely. Great work!

I wonder what's the next step for me. Should I go to /usr/src/linux-3.8.13 and do "make" and then use the "bzImage" as my new vmlinuz in the PXEboot?

Offline lid

  • Jr. Member
  • **
  • Posts: 62
Re: How to recompile the kernel?
« Reply #24 on: September 10, 2014, 05:30:33 PM »
The gcc version used with rhel is causing the problem?

I set up a VM using microcore, installed coreplay2's linux-kernel-source-env extension and ran the script. It seems it sets up the build environment nicely. Great work!

I wonder what's the next step for me. Should I go to /usr/src/linux-3.8.13 and do "make" and then use the "bzImage" as my new vmlinuz in the PXEboot?

This time the kernel image booted up OK.