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

    centos 7 kickstart - were to put ks file

    Scheduled Pinned Locked Moved
    FOG Problems
    3
    18
    2.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.
    • george1421G
      george1421 Moderator @robertkwild
      last edited by

      @robertkwild said in centos 7 kickstart - were to put ks file:

      but ${fog-ip} means the above doesnt it?

      that is only the IP address that represents the fog server. This is filled in automatically by the FOG boot.php code.

      I would not place your file in the fog directory directly, but up one level in the docroot of the web server.

      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
      • R
        robertkwild
        last edited by

        should i chown it apache:apache?

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

          @robertkwild You can change it if you want. It should work as long as world has read access. You can test by a second computer, just open a browser and connect to the FOG ip address and then the name of the file to see if you can download it with a browser.

          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
          • R
            robertkwild
            last edited by

            thanks @george1421 i can access the kickstart script via the web gui so all is good

            i can view it but i cant download it

            if i go here

            https://fog-ip/ks.cfg

            i can view it on the web

            but if i go here

            https://fog-ip/

            it re directs me to the fog dashboard, ie

            https://fog-ip//fog/management/index.php?node=home

            i was hoping it would list the dir listing of apache and when i click the file i could download it

            maybe i need to make a dir and put the file in the dir and then i can download it

            many thanks,
            rob

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

              @robertkwild If you can access the file via a web browser then you should be pretty confident that the centos linux kernel can get it when its time. As for directory browsing of the apache docroot that is turned off. The redirect asking for no specific file and then being redirected to the fog web ui is by design. You would need to do some changing in the web configuration if you wanted to do that. I would advise against changing the web configuration in apache because it may stop fog from operating.

              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 1
              • R
                robertkwild
                last edited by

                @george1421 im getting closer, ive tried all different variants but this is the best one, this one actually tries to load the “kickstart” file

                kernel tftp://${fog-ip}/os/centos/7/vmlinuz ks=http://${fog-ip}/listing/ks.cfg
                initrd tftp://${fog-ip}/os/centos/7/initrd.img
                boot || goto MENU

                but this is the error i get when trying it out

                ks.JPG

                george1421G 1 Reply Last reply Reply Quote 0
                • R
                  robertkwild
                  last edited by

                  changed it like so and so far so good, will let you know the outcome, big shout out to @george1421

                  kernel tftp://${fog-ip}/os/centos/7/vmlinuz ks=nfs:${fog-ip}:/images/os/centos/7/ks.cfg
                  initrd tftp://${fog-ip}/os/centos/7/initrd.img
                  boot || goto MENU

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

                    @robertkwild Again I would confirm if you can download the config file via a browser first. If you can and you are on the same subnet as the pxe booting computer then the problem is elsewhere. I see you’ve taken the minimalist approach to the kernel args. If that’s kind of working for you, I think I might just tack a few on for good measure since some kernels get cranky without the initrd line.

                    Using your ipxe menu config.

                    kernel tftp://${fog-ip}/os/centos/7/vmlinuz initrd=initrd.img ip=dhcp ks=http://${fog-ip}/listing/ks.cfg
                    initrd tftp://${fog-ip}/os/centos/7/initrd.img
                    boot || goto MENU
                    

                    And since we don’t know if it can’t pull the config file because of the http server or the client lets add in ip=dhcp for good measure.

                    FWIW imgargs command should do the same thing as appending the values after the kernel call, but I’ve seen some kernels not accept the imgargs line but take the kernel parameters the way you have presented them.

                    EDIT: I just noticed the certificate error. Your fog server is running configured under https:// but your curl call is using http:// This might also cause the error. Its not clear if all you need to do is change the kernel call to the ks file to https or have to do something different because fog is using a privately created certificate for https.

                    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!

                    R 1 Reply Last reply Reply Quote 1
                    • M
                      makswojciech
                      last edited by

                      Hey,
                      Recently I have been doing exactly same think as you are doing now and in my case worked:
                      kernel tftp://${fog-ip}/os/centos/7/vmlinuz
                      initrd tftp://${fog-ip}/os/centos/7/initrd.img
                      imgargs vmlinuz initrd=initrd.img root=live:nfs://${fog-ip}:/images/os/centos/7/LiveOS/squashfs.img ip=dhcp inst.repo=nfs:${fog-ip}:/images/os/centos/7 inst.ks=nfs:${fog-ip}:/images/dev/ks.cfg splash quiet
                      boot || goto MENU

                      Note, that in my case I had to have kickstart file located in /images/dev.

                      1 Reply Last reply Reply Quote 1
                      • R
                        robertkwild
                        last edited by

                        ive tested it and all works perfect!!!

                        heres my kickstart script

                        #platform=x86, AMD64, or Intel EM64T
                        #version=DEVEL
                        # Install OS instead of upgrade
                        install
                        # Keyboard layouts
                        keyboard 'uk'
                        # Root password
                        rootpw --iscrypted
                        # System language
                        lang en_GB
                        # System authorization information
                        auth  --useshadow  --passalgo=sha512
                        # Use text mode install
                        text
                        # SELinux configuration
                        selinux --disabled
                        # Do not configure the X Window System
                        skipx
                        
                        # Use NFS installation media
                        nfs --server=10.110.10.60 --dir=/images/os/centos/7
                        
                        # Firewall configuration
                        firewall --disabled
                        # Network information
                        network  --bootproto=dhcp --device=eth0
                        # Reboot after installation
                        reboot
                        # System timezone
                        timezone Europe/London
                        # System bootloader configuration
                        bootloader --location=mbr
                        # Clear the Master Boot Record
                        zerombr
                        # Partition clearing information
                        clearpart --drives=sda --all --initlabel
                        #Create Partitions automatically
                        autopart --type=lvm
                        
                        1 Reply Last reply Reply Quote 0
                        • R
                          robertkwild @george1421
                          last edited by

                          @george1421 thanks george about this, i will edit my syntax and get back to you about this

                          1 Reply Last reply Reply Quote 0
                          • R
                            robertkwild
                            last edited by

                            my dir listing works but when i click the kickstart file, it doesnt ask me to download it, where as it should instead of just viewing me the contents of it

                            is it ok to add this line in my httpd.conf as i know @george1421 advised against it

                            <Directory /var/www/html/listing>
                            Options +Indexes
                            </Directory>

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

                            222

                            Online

                            12.1k

                            Users

                            17.3k

                            Topics

                            155.2k

                            Posts
                            Copyright © 2012-2024 FOG Project