Community Forum

Resolved
0 votes
This howto has spawned out of another long kernel thread which included a lot of testing / development related posts that are now not relevant to the end product. If you wish you can read it over here

BACKGROUND
The basic kernel provided with ClearOS is from Red Hat Enterprise 5.x. Therefore this version is relatively speaking old in terms of kernel developement and features, 2.6.18 versus 2.6.37 being the latest from kernel.org. What RHEL do is back port important security features (and some new drivers) into this older stable kernel to keep it up to date. This is a good thing, and it's important that all production servers run flawlessly 24/7 without a hiccup. A kernel failure every other monday or when its dark or when the moon is facing the wrong side of the earth is not acceptable.

However, as a home or non production user, you maybe interested in a more up to date kernel from Fedora (which is the upstream version of RHEL), with a slightly increased risk of stability. This provides better hardware support often found in desktop PC's and some newer features. I have been testing and running the Fedora kernel for quite a while, over 9months and counting; and it's been rock solid on my hardware :) Note that Fedora also have their own QA and apply their own patches to ensure buildability and stability for their users

This kernel is built from their sources from FC12 Updates. 2.6.32.26-175

FEATURES
Generally improved I/O and bootup / responsiveness
Connlimit support (with installation of custom iptables RPM)
Ext4
USB3.0
Wireless stack updates
Video Tuner drivers, more network card drivers etc
New Nouveau (open source Nvidia) driver

And many many other driver updates, etc. More here:-
http://kernelnewbies.org/Linux_2_6_31
not to mention
http://kernelnewbies.org/Linux_2_6_30
http://kernelnewbies.org/Linux_2_6_29
http://kernelnewbies.org/Linux_2_6_28 etc

INSTALLATION
1. Find the kernel you want from here
http://download.clearfoundation.com/community/timb80/repo/clearos/5.2/testing/
Note that i686 and PAE variants exist (use the latter if you have more than 4GB RAM installed)
Also, the kernel-devel RPM provided if you need to compile a driver module. Kernel-headers is not generally needed

2.Open up a console window by pressing Ctrl+Alt+F2, or login via Putty, and run the following commands
cd /var/tmp
wget http://download.clearfoundation.com/community/timb80/repo/clearos/5.2/testing/kernel-2.6.32.26-175.timb1.i686.rpm
rpm -ivh kernel-2.6.32.26-175.timb1.i686.rpm

Note DO NOT use -Uvh to upgrade the kernel, as you will lose your existing functional kernel. It is perfectly acceptable to have more than one kernel at a time. You can select the old on during boot if you have problems.

3. This kernel will now become the default, reboot and you will see a new default grub entry which will boot.

PROBLEMS?
First take a browse over the Fedora F12 common bugs Then please post here.
NOTE - The protocol filter is known to break with the new kernel (due to the netfilter module name changes)

You can revert to your old kernel by selecting the second entry from grub during boot. Then you can amend the default by editing /etc/grub.conf and changing DEFAULT = 0 to 1
You can also uninstall this kernel by running
rpm -e kernel-2.6.32.26-175.timb1

If you find you have problems with the display during bootup (usually at the udev or graphical console stage) it is probably driver related. During testing we found that Nvidia Nv04 (Riva TNT) cards and Intel i915 cards need 'nomodeset' to be added to the kernel boot line. Not to be confused with X failing to start which is a seperate issue altogether.

Edit /etc/grub.conf, find the line that looks like:-
 kernel /vmlinuz-2.6.32.26-175.timb1.i686 ro root=LABEL=/ nomodeset


SIDE EFFECTS
All hard drives are now referred to as /dev/sdX not /dev/hdX
Note that there is no kABI for Fedora kernels, so Elrepo-kmod drivers will not work with it
NOTE: The L7 protocol filter or Multiwan does not work with this kernel

If you wish you can now also create connlimit type rules for iptables, with the help of a patched iptables-1.3.5-5.1custom
http://download.clearfoundation.com/community/timb80/repo/clearos/5.2/testing/
rpm -Uvh iptables-1.3.5-5.1custom.i386.rpm



FUTURE UPSTREAM ISSUES / NOTES
This is in case some one else wants to roll their own, and will save you some grief.

1. Fedora now uses Dracut to generate the ram disk (initrd) however the rpm spec can be flagged (correct as of 2.6.31.x) still to use mkinitrd
2. Config MUSTS:-
Conntrack must have it's 'compat config' flag enabled to remain compatible with the old connection monitoring reports in the webconfig
USB controllers *_hcd must be compiled as modules, so must the hard drive controllers.
Config_SYSFS_Deprecated_V2 must be enabled or the kernel will not boot on old RHEL Volumes. It will be unable to mount the partitions.
config-RHEL-generic will overwrite the manual configuration made...need to edit this to get XFS,JFS,ReseirRS support.
3. Additonal ClearOS Patches Applied:-
ClearOS logo
Dm-raid45
IMQ
Advanced routing
4. General note on Fedora 11 and newer RPM packages, they now use sha256 checksums. So if you download any Fedora RPM's they appear to fail when you try and install on an older system. You can circumnavigate this by specifying --nomd5 on the command line.
5. i686 is being phased out and in future only PAE builds will exist, in conjunction with future x84_64 builds
6. Build flags (spec modified to disable dracut default)
rpmbuild -ba --target=`uname -i` --with baseonly --without debuginfo kernel.spec 2>builderr.log | tee buildout.log

7. Kernel-firmware RPM dependancy removed as RHEL doesn't come with kernel-firmware unlike Fedora
8. Fix $rpm_build_root path lost during make headers (redefined in %install as a workaround)

Enjoy! :) this took a *long* time to get it to work and build reliably, with a lot of head bashing. (To give you a clue a kernel build is 2-4hours long) so if it works - please report back in the forums!

Small disclaimer: I take no responsibility for any system you may bork by trying this out, I will attempt to help where I can but cannot be held responsible for the pieces! USE AT YOUR OWN RISK
Monday, March 29 2010, 01:42 PM
Share this post:
Responses (245)
  • Accepted Answer

    Thursday, September 11 2014, 10:00 AM - #Permalink
    Resolved
    0 votes
    My CLearos 5.2
    error booting
    Kernel Panic - not syncing: Fatal Exception in interrupt
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, January 14 2014, 02:51 PM - #Permalink
    Resolved
    0 votes
    Well the joke's on me; I'd moved the kernels to my own repo some time ago... When I wanted the SRPMs, I checked your repo last night and got a 550 error so I thought perhaps you took your repo down - but now I see it was my own browser glitch.

    Thanks for all that kernel work...
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, January 14 2014, 12:53 PM - #Permalink
    Resolved
    0 votes
    Hey Dave - thanks for the interest, your right I've not been messing around with the kernels for some time... as an aside I've looked at bringing the Elrepo 3.x Kernels to ClearOS 6 for these odd hardware problems :)

    You can find the kernel source RPM for ClearOS 5.2 on my FTP site
    ftp://timburgess.net/repo/clearos/5.2/source/kernel-2.6.32.26-175.timb1.src.rpm
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, January 14 2014, 01:39 AM - #Permalink
    Resolved
    0 votes
    Hello Tim; sorry to resurrect an old thread...

    I'm using your unofficial kernel on quite a few systems and will continue to do so for quite some time into the future. It resolves a kernel bug in the stock kernel that I've encountered and the 2.6.32 kernel is the oldest supported by the Go programming language. So it answers a real need for me.

    Would you have the spec file used to build the kernal and any extra SRPMs in the build? It would be worth some chicken dinner / coffee money to have those files - hope you still have them and don't mind sharing them with me!

    -Dave
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, April 16 2013, 11:27 AM - #Permalink
    Resolved
    0 votes
    For the USB I think you need to explore /etc/udev. Under there (and this is from memory) there is a file 70-then_somthing_to_do_with_networking. In it there is a rule for your USB NIC. You should be able to change it from eth0 to eth1. You may also need to create an ifcfg-eth1 file.

    For ifcfg-eth3 and ifcfg-eth4 have you checked ther is a HWADDR line? If there is not, make sure you add one. I would do it for the other files as well. Use "ifconfig | grep HW" to find the MAC's.
    The reply is currently minimized Show
  • Accepted Answer

    Monday, April 15 2013, 11:22 PM - #Permalink
    Resolved
    0 votes
    I deleted all the eth devices using webgui

    Turned off the machine
    Removed all cards except the on board card

    Then reinstalled all the cards after a reboot with only the onboard card

    Now they detect as

    Onboard - eth0
    Net gear r8189 - eth2
    Intel dual port e1000e eth3
    Dual port e1000e eth4

    But when I plug the USB Ethernet in now it overrides the eth0

    I don't need the USB Ethernet now, but it would be good to have it as a spare

    Thanks for your help

    Hope fully I can backup the mail and websites and just upgrade to 6.4 pro
    The reply is currently minimized Show
  • Accepted Answer

    Monday, April 15 2013, 11:50 AM - #Permalink
    Resolved
    0 votes
    Out of order, the lspci command was checking for a possible issue which you do not have so there is no problem there. lspci lists PCI devices. You would need lsusb for your USB NIC but that does ont have the issue I was checking for.

    The next bit should be up to you. Apart from eth2 which is PPPoE so I'd rather not touch, you can play around with the rest as you want. The key things are that in the ifcfg-ethX file the DEVICE line should match the ifcfg-ethX file name and if you have more than one device using the same NIC driver you should also have an HWADDR line (although it is safest if that all have it). Each LAN NIC should be on a differnt LAN subnet. The /etc/modprobe.conf file should match the ethX to the correct device.

    You could, for example, switch your Broadcom NIC back to eth0 by renaming ifcfg-eth1 -> ifcfg-eth0 and changing the DEVICE line in the file. Then reboot. Really there should be a line in /etc/modprobe.conf "alias ethX tg3" for this card.

    For the Intel card, I am wondering if we should not trust the MAC address from the dmesg file. In this case, use your current ifcfg-eth1 file to create 2 new files (one of which could be ifcfg-eth1 if you decide to switch the Broadcom device back to eth0). In the new files make sure the DEVICE entry matches the file name. Remove the HWADDR line and put each file on a different subnet. Sort out the /etc/modprobe.conf file removing the invalid alias ethX lines (there are too many e1000e lines). You should be left with one line for each ethX (and possibly other entries for things which are not ethX which you should leave alone), so there should be two e1000e lines.

    At this point you should be able to reboot and see your Intel NIC. Then do a "ifconfig | grep HW" to pick up the MAC addresses for the Intel NIC and put the HWADDR lines back in the relevant ifcfg-ethX file. This is important as it is otherwise conceivable that the NIC's will swap their identities occasionally when you reboot.
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, April 14 2013, 09:26 PM - #Permalink
    Resolved
    0 votes
    Nick Howitt wrote:
    Please do:
    ifconfig | grep HW
    lspci -v | grep Eth

    I got the wrong case in the first command before (hw -> HW). The second should work. Just copy and paste the commands (together if you want) into your terminal session.

    [edit]
    My advice to put in the HWADDR into ifcrg-eth1 may have been bad as different bits of the system are giving different results.

    Can you also do a:
    grep HW /etc/sysconfig/network-scripts/ifcfg-eth*

    [/edit]


    here are the outputs


    [root@gateway ~]# ifconfig | grep HW
    eth1 Link encap:Ethernet HWaddr 00:1A:4B:ED:92:73
    eth2 Link encap:Ethernet HWaddr 00:22:3F:F4:EE:5A
    eth3 Link encap:Ethernet HWaddr 00:E0:4C:03:38:AF
    eth3:200 Link encap:Ethernet HWaddr 00:E0:4C:03:38:AF
    imq0 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 -00
    imq1 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 -00
    imq2 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 -00
    imq3 Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 -00
    [root@gateway ~]# lspci -v | grep Eth
    01:09.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8169 PCI Gigabit Ethernet Controller (rev 10)
    02:00.0 Ethernet controller: Intel Corporation 82571EB Gigabit Ethernet Controll er (rev 06)
    02:00.1 Ethernet controller: Intel Corporation 82571EB Gigabit Ethernet Controll er (rev 06)
    06:00.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5721 Gigabit Ethe rnet PCI Express (rev 21)


    the last one is missing the USB plugin ETHERNET Card details however which is ethernet 3




    [root@gateway ~]# grep HW /etc/sysconfig/network-scripts/ifcfg-eth*
    /etc/sysconfig/network-scripts/ifcfg-eth1:HWADDR="00:1a:4b:ed:92:73"
    /etc/sysconfig/network-scripts/ifcfg-eth2:HWADDR="00:22:3f:f4:ee:5a"
    /etc/sysconfig/network-scripts/ifcfg-eth3:HWADDR="00:e0:4c:03:38:af"
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, April 14 2013, 12:19 PM - #Permalink
    Resolved
    0 votes
    Please do:
    ifconfig | grep HW
    lspci -v | grep Eth

    I got the wrong case in the first command before (hw -> HW). The second should work. Just copy and paste the commands (together if you want) into your terminal session.

    [edit]
    My advice to put in the HWADDR into ifcrg-eth1 may have been bad as different bits of the system are giving different results.

    Can you also do a:
    grep HW /etc/sysconfig/network-scripts/ifcfg-eth*

    [/edit]
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, April 14 2013, 09:52 AM - #Permalink
    Resolved
    0 votes
    luke gunton wrote:
    [quote]Nick Howitt wrote:
    [quote]How odd dmesg gives eth2 as an e1000e card and modprobe gives it as an r8169 card. Is your eth2 interface working and is it the r8169? I will assume it is. yes eth2 is working, it is the ADSL/PPPoE Portidconfig

    Make sure in ifcfg-eth1 there is a line:
    HWADDR="68:05:ca:11:1b:f1"
    Copy the file ifcfg-eth4, change the DEVICE and IPADDR, making sure the IPADDR is in a new subnet. Set the HWADDR line to "68:05:ca:11:1b:f0". Then, at best, try an "ifup eth4". At worst reboot and see what happens.

    tried creating a new eth4 config file but on ifup it says incorrect mac address - ignoring
    The reply is currently minimized Show
Your Reply