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

    Change to gpxelinux.0

    Scheduled Pinned Locked Moved
    Tutorials
    4
    6
    3.3k
    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.
    • J
      Jimmy Hansen
      last edited by

      [SIZE=4]As a part of my studies in IT Technology, I have been working on how to get an FOG server on the cloud. One of many problems was if the client was behind a firewall and NAT, secondly, speed, as FOG server uses tftp, but I have figured out how to change to http for a big speed boost, this is tested on VM’s and even on VM’s on Microsoft Azure. [/SIZE]

      [SIZE=4]So here is my 2 cent on how to do it.[/SIZE]

      [COLOR=black][FONT=Arial][SIZE=4]On Ubuntu 12.04lts server with FOG 0.32[/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]Start by chmod -R 777 /tftpboot/ (case sensetiv)[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]This will give RW access to the /tftpboot dir.[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4](change to chmod -R 755 /tftpboot after guide)[/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]1 -6 can be done in FileZilla or directly on server[/SIZE][/FONT][/COLOR]

      [LIST=1]
      [][COLOR=black][SIZE=4]Download and extract syslinux - [url]https://www.kernel.org/pub/linux/utils/boot/syslinux/[/url][/SIZE][/COLOR]
      [
      ][COLOR=black][SIZE=4]Copy /gpxe/gpxelinux.0 to /tftpboot[/SIZE][/COLOR]
      [][COLOR=black][SIZE=4]Rename /tftpboot/vesamenu.c32 to /tftpboot/vesamenu.c32.ol[/SIZE] [/COLOR]
      [
      ][COLOR=black][SIZE=4]Copy /com32/menu/vesamenu.c32 to /tftpboot [/SIZE][/COLOR]
      [][COLOR=black][SIZE=4]Copy /memdisk/memdisk and replace /tftpboot/fog/images/memdisk and to /tftpboot[/SIZE][/COLOR]
      [
      ][COLOR=black][SIZE=4]Create a new folder named backup and move pxelinux.0 and vesamenu.c32.old to this folder[/SIZE][/COLOR]
      [][COLOR=black][SIZE=4]Edit /etc/dhcp/dhcpd.conf, replacing pxelinux.0 with gpxelinux.0 [COLOR=#e84c22][I][B](IF FOG server is DHCP server)[/B][/I][/COLOR][/SIZE][/COLOR]
      [
      ][COLOR=black][SIZE=4][FONT=Arial]Go to cd /var/www/ and type[/FONT][/SIZE][/COLOR]
      [/LIST]
      [COLOR=black][FONT=Arial][SIZE=4]ln -s /tftpboot/fog fogboot [/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]ln –s /tftpboot pxe[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4] ln[/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]ls -l should now show[/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]drwxr-xr-x. 12 apache apache 4096 Dec 31 18:27 fog[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]lrwxrwxrwx. 1 root root 13 Jan 28 18:31 fogboot -> /tftpboot/fog[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]-rw-r–r–. 1 root root 45 Dec 31 18:27 index.php[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]Lrwxrwxrwx. 1root root 9 jan 28 15:57 pxe -> /tftpboot[/SIZE][/FONT][/COLOR]

      [LIST]
      [][COLOR=black]SIZE=4pxelinux.0 seems to be strict on the configuration file, and complains about the newline characters in the config file so edit /tftpboot/pxelinux.cfg/default to remove any newlines[I][B] (\n)[/B][/I][/SIZE][/COLOR]
      [
      ][SIZE=4]Change the IP’s to http in /tftpboot/pxelinux.cfg/default[/SIZE]
      [/LIST]
      [FONT=Arial][SIZE=4] LABEL fog.reg[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] kernel fog/kernel/bzImage[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] append initrd=[url]http://Myfogserver.com/fogboot/images/init.gz[/url] root=/dev/ram0 rw ramdisk_size=127000 ip=dhcp dns=8.8.8.8 mode=autoreg web=137.135.203.249/fog/ loglevel=4[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] MENU LABEL Quick Host Registration and Inventory[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] TEXT HELP[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] Automatically register the client computer,[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] and perform a hardware inventory.[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] ENDTEXT[/SIZE][/FONT]

      [FONT=Arial][SIZE=4](example, after append initrd you can use URL or ip to your server)[/SIZE][/FONT]

      [COLOR=black][FONT=Arial][SIZE=4][I][B]Reboot[/B][/I], to restart services. [/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]Check by typing :[URL=‘http://%22Your_fog-server%22.com/fogboot/kernel/bzimage’][B]http://[/B][I][B]“Your_fog-server”.com/fogboot/kernel/bzimage[/B][/I][/URL][I][B] (handle can be swapped with IP)[/B][/I][/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]And make sure it can download the bzimage [I][B](No need to download it)[/B][/I][/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4][URL=‘http://%22your_fog-server%22.com/pxe/gpxelinux.0’][I][B]http://“your_fog-server”.com/pxe/gpxelinux.0[/B][/I][/URL] [I][B](handle can be swapped with IP)[/B][/I][/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]And make sure it can download the gpxelinux.0 [I][B](no need to download it)[/B][/I][/SIZE][/FONT][/COLOR]

      [FONT=Arial][SIZE=4]In the web interface you will also need to change to[/SIZE][/FONT]
      [FONT=Arial][SIZE=4] Http[/SIZE][/FONT]

      [FONT=Arial][SIZE=4][B]Tftp server[/B][/SIZE][/FONT]

      [FONT=Arial][SIZE=4]Fog_tftp_pxe_kernel to [url]http://myfogserver.com/fogboot/kernel/bzImage[/url] (change URL to match, or use IP)[/SIZE][/FONT]

      [FONT=Arial][SIZE=4]Fog_pxe_boot_image to [url]http://myfogserver.com/fogboot/images/init.gz[/url] (change URL to match, or use IP) [/SIZE][/FONT]

      [COLOR=black][FONT=Arial][SIZE=4]chmod -R 755 /tftpboot/ (case sensetiv)[/SIZE][/FONT][/COLOR]
      [COLOR=black][FONT=Arial][SIZE=4]To change rights again[/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]I hope this was usefull to someone, and if you have questions I will do my best to answer them.[/SIZE][/FONT][/COLOR]

      [COLOR=black][FONT=Arial][SIZE=4]/Jimmy S. Hansen[/SIZE][/FONT][/COLOR]

      1 Reply Last reply Reply Quote 0
      • D
        Dave Smith
        last edited by

        Going to give this a Try, thanks for posting.

        1 Reply Last reply Reply Quote 0
        • J
          Jimmy Hansen
          last edited by

          Hope you will have luck with it.

          1 Reply Last reply Reply Quote 0
          • Tom ElliottT
            Tom Elliott
            last edited by

            Jimmy Hansen,

            Have you, by chance, looked into using iPXE for these same actions?

            I make this suggestion as gpxe is no longer actively maintained. iPXE is the spawn after gpxe. It uses many of the same protocols and scripts, only replaced #!gpxe with #!ipxe and is actively maintained.

            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! Get in contact with me (chat bubble in the top right corner) if you want to join in.

            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
            • J
              Jimmy Hansen
              last edited by

              I did not look that way no. But as far as i understand, you actually don’t need to use gpxe since the latest version of pxe already supports http transfer, so it could look like step 1-6 of my guide is not a must.
              If i have a spare moment I will look further into IPXE vs PXE vs GPXE

              1 Reply Last reply Reply Quote 0
              • JunkhackerJ
                Junkhacker Developer
                last edited by

                if you are interested in this stuff, you really need to look at the development going on in fog 0.33b.

                signature:
                Junkhacker
                We are here to help you. If you are unresponsive to our questions, don't expect us to be responsive to yours.

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

                150

                Online

                12.0k

                Users

                17.3k

                Topics

                155.2k

                Posts
                Copyright © 2012-2024 FOG Project