Use HTTP instead of TFTP for fetching WIM files
-
I had this set up previously, where the WIM file of my WinPE Image was downloaded via HTTP instead of TFTP. I guess during a FOG update it cleared whatever folders I had put in /var/www/fog. I can do it again, but is there a way to set a secondary web root? TFTP takes a long time to download a 500MB WIM file.
-
@brakcounty That is the risk with putting files in
/var/www/fog
directory. I would have put the files into/var/www/os
directory. That fog directory is totally under control of the fog installer script to do with as it pleases. -
@george1421 Gotcha. So is the /var/www/ directory still part of the web server or do I have to add it?
-
@brakcounty said in Use HTTP instead of TFTP for fetching WIM files:
So is the /var/www/ directory still part of the web server or do I have to add it?
Depends on the Linux OS you use. Check the Apache config to see what
DocumentRoot
is set to. -
@brakcounty said in Use HTTP instead of TFTP for fetching WIM files:
var/www/
yes and no. Depending on your linux distro the document root is in
var/www/
for debian and variants andvar/www/html
for rhel variants.As Sebastian said, if you look into the apache configuration the DocumentRoot value will point to the base directory, but it will be one of the above. Just make a new directory for your wim files no in the fog directory in the DocumentRoot.
-
@sebastian-roth
I am running Ubuntu Server 20.04
I did not see DocumentRoot in /etc/apache2/apache2.conf, but I did see this: (I marked it with **). Leads me to believe that /var/www is the root share of the apache server.# Sets the default security model of the Apache2 HTTPD server. It does # not allow access to the root filesystem outside of /usr/share and /var/www. # The former is used by web applications packaged in Debian, # the latter may be used for local directories served by the web server. If # your system is serving content from a sub-directory in /srv you must allow # access here, or in any related virtual host. <Directory /> Options FollowSymLinks AllowOverride None Require all denied </Directory> <Directory /usr/share> AllowOverride None Require all granted </Directory> **<Directory /var/www/> Options Indexes FollowSymLinks AllowOverride None Require all granted**
-
Success! Dropped the files into /var/www and used set web-path to ${fog-ip}. In case anyone else has this issue this is my iPXE menu item parameters:
set tftp-path tftp://${fog-ip}/os
set web-path http://${fog-ip}
set pe-path ${web-path}/pm11_winpe
kernel ${tftp-path}/wimboot gui
imgfetch --name BCD ${pe-path}/BCD BCD
imgfetch --name boot.sdi ${pe-path}/boot.sdi boot.sdi
imgfetch --name bootmgr ${pe-path}/bootmgr bootmgr
imgfetch --name boot.wim ${pe-path}/boot.wim boot.wim
boot || goto MENU