• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Compiling custom kernel / network driver missing issue

    Scheduled Pinned Locked Moved
    FOG Problems
    3
    8
    915
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      dnajosh
      last edited by

      Hello and thank you for the FOG project.

      I am trying to set up a build environment so that I may custom compile kernels for fog.

      The instructions located at https://wiki.fogproject.org/wiki/index.php?title=Building_a_Custom_Kernel instruct us to

      Copy the .config file from the fog release package which is located in the Fog Setup ./kernel directory:
      cp /opt/fog-setup/fog_0.29/kernel/kitchensink.config /usr/src/linux-2.6.35.3/.config

      I am unable to locate the kitchensink.config file. Are these instructions still applicable? My environment has a large variety of hardware and I hope to be able to handle this in house.

      Thank you for your help.

      1 Reply Last reply Reply Quote 0
      • george1421G
        george1421 Moderator
        last edited by

        Ok lets backup a second. What kernel version are you trying to compile and what hardware are you trying to match up?

        What version of FOG are you using?

        For your kernel build environment what OS will you be compiling under?

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

        1 Reply Last reply Reply Quote 0
        • D
          dnajosh
          last edited by

          Kernel 5.6 should suffice. The hardware changes constantly as computers come and go. The most recent need were network drivers for “Intel® I225-V 2.5Gb Ethernet” on an ASUS ROG Strix itx motherboard.

          FOG 1.5.9

          Ubuntu 18.04.5

          Thank you for the prompt response sir. In my searches I came across many threads where you supplied kernels with the drivers needed. Due to my environment constantly changing I figured I had better get this going myself so as not to bother you regularly.

          george1421G 1 Reply Last reply Reply Quote 0
          • george1421G
            george1421 Moderator @dnajosh
            last edited by george1421

            @dnajosh OK there is already a supported kernel at 5.6.18 in the fog kernel repository. That addresses all of the current hardware. The reason why its not part of 1.5.9 is that the linux kernel developers haven’t released a LTS version of the kernel after 5.5.0 (when all of the new hardware was added). As soon as they announce an LTS version then that version will be included as the default kernel for FOG.

            BUT if you still want to setup your own build environment I can help you get started.

            Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

            1 Reply Last reply Reply Quote 0
            • D
              dnajosh
              last edited by

              Thank you for the prompt responses. I am using the 5.6 kernel but it is lacking some needed network drivers. It appears the drivers I needed a few days ago are in 5.9 RC6.

              I think 5.6 will be fine I just need to add drivers.

              If you can assist with creating a build environment so that I may add needed drivers that would be appreciated.

              george1421G 1 Reply Last reply Reply Quote 0
              • george1421G
                george1421 Moderator @dnajosh
                last edited by george1421

                @dnajosh OK lets get started.

                I had to translate this because my build environment is based on centos.

                sudo apt-get update
                sudo apt-get install kernel-package libncurses5-dev fakeroot wget bzip2 git
                

                Now that you have the necessary packages on your ubuntu server the next bits are around getting the needed stuff to start compiling

                mkdir ~/fog
                cd ~/fog
                wget https://git.kernel.org/torvalds/t/linux-5.9-rc6.tar.gz
                tar -zxf linux-5.9-rc6.tar.gz
                git clone https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git
                

                Now you have the kernel you want to build and the needed firmware. The next part you need to grab the kernel config file for the current release of FOG from github site.

                Grab the kernelx64.config from this web site. https://github.com/FOGProject/fos/tree/master/configs

                Move that file to your ubuntu server and save it in ~/fog/linux-5.9-rc6 directory. Then rename kernelx64.config as .config

                You need to edit the .config file to adjust for where the linux-firmware is located. Because in this build environment its up one level from where the config file says its in. Edit the .config file and modify the field CONFIG_EXTRA_FIRMWARE_DIR to look like this:

                CONFIG_EXTRA_FIRMWARE_DIR="../linux-firmware"
                

                Now you need to load that config into the menus key in make nconfig Make should build the menu. Confirm that fog is listed in the default host name parameter. Under General -> default host name.

                kernel_build.png

                If that is set then the proper fog kernel configuration file is loaded. Save and Exit out of the configuration menu. Yes SAVE even if you have not changed anything. This ensures all of the current kernels rules are in line with expectations.

                Now key in make bzImage

                That will produce the updated kernel.

                Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!

                1 Reply Last reply Reply Quote 0
                • S
                  Sebastian Roth Moderator
                  last edited by Sebastian Roth

                  @dnajosh Good to see you engaging and wanting to learn how to build a kernel yourself. The wiki page you found is pretty old and you better use this one: https://wiki.fogproject.org/wiki/index.php/Build_TomElliott_Kernel (combined with George’s instructions)

                  @george1421 I am wondering if we can try to move such important information that you give back to the wiki or start a complete new documentation altogether? I will start a new topic in this soon.

                  Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

                  Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

                  1 Reply Last reply Reply Quote 0
                  • D
                    dnajosh
                    last edited by

                    Thank you, your instructions worked great. I needed to install flex and workaround a kernel specific issue (http://rglinuxtech.com/?p=2834) but otherwise things went very smoothly.

                    1 Reply Last reply Reply Quote 2
                    • 1 / 1
                    • First post
                      Last post

                    197

                    Online

                    12.0k

                    Users

                    17.3k

                    Topics

                    155.2k

                    Posts
                    Copyright © 2012-2024 FOG Project