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

    Fog v1.2.0 - How to stop client "Disk surface Test" results window closing ?

    Scheduled Pinned Locked Moved
    FOG Problems
    2
    5
    1.8k
    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.
    • R
      Robin Commander
      last edited by

      Hi everyone, I’m hoping somebody can point me in the right direction please ?

      I have Fog 1.2.0 (stable release version) installed on my new server and it is working beautifully - kudos and thanks to all of the developers.

      I had modified the init.gz image on my old server which was running Fog 0.32 so that when I used the Basic Tasks > Advanced > Disk Surface Scan functionality I could make the client sit and wait for a keypress. In this way I was able to leave a group of client machines testing their hdd’s, go off and do something else and come back later to look at the results and hence know if I needed to swap a faulty hdd out before re-imaging.

      Previously I’d just added a line: read -p “Any key to continue…” at the end of the relevant script file, but in Fog 1.2.0 the relevant files have changed and I’m at a loss as to what file to edit now and how to get to it within the boot image ?

      Kind Regards,
      Robin

      Assumption is the mother of all f***ups !

      1 Reply Last reply Reply Quote 0
      • R
        Robin Commander
        last edited by

        Solved I think… In case anyone else is wondering the same thing…

        I happened on an earlier forum post from ‘G0dzilla’ here where somebody was trying to get Clam AV working.

        [url]http://fogproject.org/forum/threads/centos-clamav-and-fog-1-2-0.11508/[/url]

        Using the information within I realised that i needed to modify /var/www/fog/service/ipxe/init.xz - it needs to be decompressed and temporarily mounted first to allow the fog.surfacetest file to be edited and then compressed again afterwards.

        So basically:

        cd /var/www/html/fog/service/ipxe
        xz -d init.xz
        mkdir mountdir
        mount -o loop init mountdir
        cd mountdir
        Edit the fog.surfacetest file to add a line: read -p “Any key to continue…”; just before the script would normally end
        Save the file changes
        cd …
        umount mountdir
        xz -z -9 -C crc32 init
        rmdir mountdir

        That’s it I hope - just testing now.

        Thanks for the inspiration G0dzilla !

        Kind Regards,
        Robin

        Assumption is the mother of all f***ups !

        1 Reply Last reply Reply Quote 0
        • R
          Robin Commander
          last edited by

          Apologies - the first line should read cd /var/www/fog/service/ipxe

          The fog.surfacetest file can be found within /var/www/fog/service/ipxe/mountdir/bin

          Should have made better notes as I was doing this ! :oops:

          Assumption is the mother of all f***ups !

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

            To help out:
            [code]cd /var/www/fog/html
            mkdir mountdir
            xz -d init.xz
            mount -o loop init mountdir
            [/code]
            Add the line after line 50:
            For vi:
            [code]vi mountdir/bin/fog.surfacetest
            SHIFT+G
            i
            read -p “Any key to continue…”;
            ESC
            :wq!
            [/code]

            Copy the file so you can fix init_32.xz as well:
            [code]cp mountdir/bin/fog.surfacetest ./[/code]
            Unmount the mountdir and recompress the init:
            [code]umount mountdir
            xz -C crc32 -9 -z init
            [/code]

            Run these commands to fix init_32.xz as well:
            [code]xz -d init_32.xz
            mount -o loop init_32 mountdir
            cp ./fog.surfacetest mountdir/bin/fog.surfacetest
            umount mountdir
            xz -C crc32 -9 -z init_32
            rm -rf mountdir
            [/code]

            You should be all set.

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

              Hi Tom,

              Thanks for the update I’d forgotten that init_32 would also need to be amended.

              One thing though, on my box (Ubuntu 12.04 LTS alternate + added desktop + Webmin) there is no /var/www/fog/html folder, hence i’d gone to /var/www/fog/service/ipxe

              My original posting worked, at least for init.xz anyway. The test laptop was happily sitting there waiting for a keypress when I woke up this morning. Perhaps the filepath has changed between the latest and stable releases of Fog ? Anyway I’m a happy bunny.

              Would it be possible to add this change to the next version please ? It doesn’t make any sense for badblocks to write test results to the screen and then allow a reboot before you’ve had a chance to see them does it ?

              Kind Regards,
              Robin

              Assumption is the mother of all f***ups !

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

              143

              Online

              12.0k

              Users

              17.3k

              Topics

              155.2k

              Posts
              Copyright © 2012-2024 FOG Project