As I plow through the Kernel source to figure out why the BEET patch is not working, I notice that there are two similar directories under ~/rpmbuild/BUILD/kernel-2.6.18:
linux-2.16.18.i386 and linux-2.16.18.i686
So which one am I suppose to be patching?
Currently, the patch starts out with:
diff -urN a/net/ipv4/xfrm4_input.c b/net/ipv4/xfrm4_input.c
I followed the kernel source setup instructions on the wiki:
http://wiki.centos.org/HowTos/I_need_the_Kernel_Source
tells me to supply i686 for getting and setting up the source.
But http://wiki.centos.org/HowTos/Custom_Kernel
has me setting up a .config file with '# i386' as the first line. Now that is a comment, right? So why add such a comment. Perhaps it is NOT a comment? Shesh...
Anyway, which directory structure gets used in the rpmbuild:
rpmbuild -bb --target=`uname -m` kernel-2.6.spec 2> build-err.log | tee build-out.log
Do I add this to the patch?
On Tue, Sep 16, 2008 at 5:38 AM, Robert Moskowitz rgm@htt-consult.com wrote:
As I plow through the Kernel source to figure out why the BEET patch is not working, I notice that there are two similar directories under ~/rpmbuild/BUILD/kernel-2.6.18:
linux-2.16.18.i386 and linux-2.16.18.i686
So which one am I suppose to be patching?
Currently, the patch starts out with:
diff -urN a/net/ipv4/xfrm4_input.c b/net/ipv4/xfrm4_input.c
I followed the kernel source setup instructions on the wiki: http://wiki.centos.org/HowTos/I_need_the_Kernel_Source
tells me to supply i686 for getting and setting up the source.
But http://wiki.centos.org/HowTos/Custom_Kernel
has me setting up a .config file with '# i386' as the first line. Now that is a comment, right? So why add such a comment. Perhaps it is NOT a comment? Shesh...
It is NOT a comment. That line is read during the build procedure for identification of the arch.
[code] # now run oldconfig over all the config files for i in *.config do mv $i .config Arch=`head -1 .config | cut -b 3-` make ARCH=$Arch nonint_oldconfig > /dev/null echo "# $Arch" > configs/$i cat .config >> configs/$i done [/code]
Anyway, which directory structure gets used in the rpmbuild:
rpmbuild -bb --target=`uname -m` kernel-2.6.spec 2> build-err.log | tee build-out.log
Do I add this to the patch?
You need to add the patch file to the SOURCES directory and edit the .spec file to include that patch. This is explained in the wiki article you referred to. If the build fails, please post relevant portions of the log files so that we can figure out what went wrong.
Akemi
Akemi Yagi wrote:
On Tue, Sep 16, 2008 at 5:38 AM, Robert Moskowitz rgm@htt-consult.com wrote:
As I plow through the Kernel source to figure out why the BEET patch is not working, I notice that there are two similar directories under ~/rpmbuild/BUILD/kernel-2.6.18:
linux-2.16.18.i386 and linux-2.16.18.i686
So which one am I suppose to be patching?
Currently, the patch starts out with:
diff -urN a/net/ipv4/xfrm4_input.c b/net/ipv4/xfrm4_input.c
Anyway, which directory structure gets used in the rpmbuild:
rpmbuild -bb --target=`uname -m` kernel-2.6.spec 2> build-err.log | tee build-out.log
Do I add this to the patch?
You need to add the patch file to the SOURCES directory and edit the .spec file to include that patch. This is explained in the wiki article you referred to.
Did that. I believe I followed the instructions to a tee.
If the build fails, please post relevant portions of the log files so that we can figure out what went wrong.
I did that a couple of days ago:
Patch #40000 (centos-5.2-hipmod-sleep-beet-and-interfamily-all-in-one.patch): 1 out of 4 hunks FAILED -- saving rejects to file net/ipv4/xfrm4_output.c.rej 2 out of 3 hunks FAILED -- saving rejects to file net/ipv4/esp4.c.rej 1 out of 1 hunk FAILED -- saving rejects to file net/ipv6/udp.c.rej 1 out of 1 hunk FAILED -- saving rejects to file net/ipv6/tcp_ipv6.c.rej 1 out of 1 hunk FAILED -- saving rejects to file net/ipv6/esp6.c.rej 2 out of 2 hunks FAILED -- saving rejects to file net/ipv6/icmp.c.rej 2 out of 2 hunks FAILED -- saving rejects to file net/xfrm/xfrm_state.c.rej 1 out of 2 hunks FAILED -- saving rejects to file include/net/xfrm.h.rej Reversed (or previously applied) patch detected! Assume -R? [n] Apply anyway? [n] 1 out of 1 hunk ignored -- saving rejects to file include/linux/net.h.rej
====================================
Oh, I had tried patching the kernel both as userid me and as root (this is set up as a 'throughaway system', so if I mess up as root, I can just rebuild. The reason for trying with root is one of the developers does all his compiles as root in fc8, so I was trying to see if there was something specific to the setup that was not right for building as non-root.
Well anyway, I just checked the system over for one of the 'reject' files: esp4.c.rej
As userid me, it is in ~/rpmbuild/BUILD/kernel-2.6.18/linux-2.6.8.i386/net/ipv4. As root it is in /usr/src/redhat/kernel-2.6.18/linux-2.6.8.i686/net/ipv4. Both versions ov esp4.c.rej appear identical.
On Tue, Sep 16, 2008 at 7:49 AM, Robert Moskowitz rgm@htt-consult.com wrote:
Akemi Yagi wrote:
You need to add the patch file to the SOURCES directory and edit the .spec file to include that patch. This is explained in the wiki article you referred to.
Did that. I believe I followed the instructions to a tee.
If the build fails, please post relevant portions of the log files so that we can figure out what went wrong.
I did that a couple of days ago:
Patch #40000 (centos-5.2-hipmod-sleep-beet-and-interfamily-all-in-one.patch): 1 out of 4 hunks FAILED -- saving rejects to file net/ipv4/xfrm4_output.c.rej 2 out of 3 hunks FAILED -- saving rejects to file net/ipv4/esp4.c.rej 1 out of 1 hunk FAILED -- saving rejects to file net/ipv6/udp.c.rej 1 out of 1 hunk FAILED -- saving rejects to file net/ipv6/tcp_ipv6.c.rej 1 out of 1 hunk FAILED -- saving rejects to file net/ipv6/esp6.c.rej 2 out of 2 hunks FAILED -- saving rejects to file net/ipv6/icmp.c.rej 2 out of 2 hunks FAILED -- saving rejects to file net/xfrm/xfrm_state.c.rej 1 out of 2 hunks FAILED -- saving rejects to file include/net/xfrm.h.rej Reversed (or previously applied) patch detected! Assume -R? [n] Apply anyway? [n] 1 out of 1 hunk ignored -- saving rejects to file include/linux/net.h.rej
====================================
Now I remember this one. I believe you got this one answered that time. The patch cannot be directly applied to the CentOS kernel because it was written for the vanilla kernel.
Akemi
On Tue, Sep 16, 2008 at 8:15 AM, Akemi Yagi amyagi@gmail.com wrote:
Now I remember this one. I believe you got this one answered that time. The patch cannot be directly applied to the CentOS kernel because it was written for the vanilla kernel.
Not just vanilla kernel but rather "more recent or newer kernel".
Akemi
Akemi Yagi wrote:
On Tue, Sep 16, 2008 at 8:15 AM, Akemi Yagi amyagi@gmail.com wrote:
Now I remember this one. I believe you got this one answered that time. The patch cannot be directly applied to the CentOS kernel because it was written for the vanilla kernel.
Not just vanilla kernel but rather "more recent or newer kernel".
No. It was written for the 2.6.18 kernel. But I think it was written a few patches back. The patch author has a patch for pretty much all the kernels up to 2.6.26, as BEET is now officially in 2.6.27. But my first hunch was that he did this for the 2.6.18 kernel in FC6 that does not have all the patches that are in RHEL 5.2 (and thus Centos 5.2), and so his patches were off.
Then last night I thought, well there are these two directories under kernel-2.6.18 and which one is being used? Now I see that I had used both of them and it made no difference. Thus going back to my earlier thoughts about being a patch for this kernel, but not at the patch-point this kernel is at.
I have found a number of problems with the HIPL code that the developers are working to correct. I think becuase they had gotten focused on HIP over IPv4 and had let the IPv6 side slide a bit. The NETBSD developers claim that their code is ready, but that would be a bigger switch for me than going to FC8 where most of the HIPL development is being done...