For networks where PXE cannot be configured we have replicated the content of the /tftpboot folder onto a bootable USB stick and tweaked the fog and fog.quickimage scripts to allow quickimage of machine without needing reboot between job creation and actual imaging process.
Usually when "quickimage" option is chosen at pxe boot from the fog menu it contacts the fog server to create a job if needed and then initiates a reboot. At reboot, if no other option is activated i.e. no "mode" is passed to the initrd.gz during load it boots up to execute the "fog" script which then handles imaging.
Our modifications allow the fog.quickimage script to first check that it is running off a USB stick or not. If yes, then it proceeds to register a job on the server and rather than reboot it calls the "fog" script which verifies the MAC address of the host and copies down the job file from the fog server for local execution. Details from this job file are then extracted and used during the execution of "fog" commands to proceed with imaging.
We have found this nifty edit to be a saviour as we were testing fog deployments in absence of an active pxe boot service.
The modified "fog" and "fog.quickimage" files are attached within the 7 zip archive along with appropriate diff files for the edits. Also note that you will need to create a sym link from your var/www/fog/service directory to the /tftpboot/pxelinux.cfg/ directory to allow the "download" of the job file to work.
We appreciate that this may not be the perfect solution for open deployments (as the job files are downloaded directly off a sym linked web folder) and are hopeful that if this suggestion gets incorporated into future releases then a more appropriate solution / secure method would be developed within the community.
A Cowley & MD Sharma
Log in to post a comment.