Post Reply 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Deploy Linux/Windows with IPXE + WDS + MDT
2020-06-09, 15:54
Post: #1
Deploy Linux/Windows with IPXE + WDS + MDT
Hello,

I meet a problem with my installation.

DHCP: no 60, 67

Step 1 : Install Server and Roles
I installed a windows 2016 server containing a WDS, MDT & IIS.

Step 2 : Install ubuntu
I installed an ubuntu on a laptop

Step 3 : Create the iPXE boot file

On the ubuntu, i start a terminal :

sudo apt-get install -y build-essential liblzma-dev git
git clone https://git.ipxe.org/ipxe.git ipxe
cd ipxe/src
gedit chain.ipxe

paste the following code into this file, then save:
#!ipxe

dhcp
chain http://%IP-address-your-IIS-server%/install.ipxe

We return to the terminal and start the compilation:
make bin-x86_64-efi/ipxe.efi EMBED=chain.ipxe

File : ipxe/src/bin-x86_64-efi/ipxe.efi

Step 4: Copy file to WDS
Copy ipxe/src/bin-x86_64-efi/ipxe.efi to %WDSpath%\Boot\x64\PXE\EFI\BOOT\ and rename file to BOOTX64.EFI

Execute on WDS CMD with run as Administrator:
wdsutil /set-server /bootprogram:Boot\x64\PXE\EFI\BOOT\BOOTX
64.EFI /architecture:x64uefi

wdsutil /set-server /N12bootprogram:Boot\x64\PXE\EFI\BOOT\BOOTX
64.EFI /architecture:x64uefi


Show config :
wdsutil /get-server /Show:Config

Step 5 : Create menu

IIS defaut root : C:\inetpub\wwwroot

Create file install.ipxe on the IIS defaut root

Step 6 change type mime on IIS
Add Type MIME
*.
test/plain

And
.
application/octet-stream



Until it works I get an IPXE menu, but I can't boot on my WDS or on a Linux installation.

My install.ipxe:

Code:
#!ipxe

# Figure out if client is 64-bit capable
cpuid --ext 29 && set arch x64 || set arch x86
cpuid --ext 29 && set archl amd64 || set archl i386

###################### MAIN MENU ####################################

:start
menu iPXE boot menu
item --gap --             -------------------------------Installation ------------------------------
item --key w wds          WDS
item --key l linux        Linux
item --gap --             ------------------------- Advanced options -------------------------------
item --key c config       Configure settings
item shell                Drop to iPXE shell
item reboot               Reboot computer
item
item --key x exit         Exit iPXE and continue BIOS boot
choose --timeout 5000 --default wds selected || goto cancel
set menu-timeout 0
goto ${selected}

:cancel
echo You cancelled the menu, dropping you to a shell

:shell
echo Type 'exit' to get the back to the menu
shell
set menu-timeout 0
set submenu-timeout 0
goto start

:failed
echo Booting failed, dropping to shell
goto shell

:reboot
reboot

:exit
exit

:config
config
goto start

:back
set submenu-timeout 0
clear submenu-default
goto start

############ MAIN MENU ITEMS ############

:wds
chain \Boot\x64\wdsmgfw.efi || goto failed
goto start

:linux
chain ${base_url}/ubuntu.ipxe
goto main


My ubuntu.ipxe
Code:
#!ipxe
cpuid --ext 29 && set arch_a amd64 || set arch_a i386
set ubuntu_mirror archive.ubuntu.com
set ubuntu_base_dir ubuntu

:ubuntu_main
clear menu
set space:hex 20:20
set space ${space:string}
menu HispaMSX Network Boot Services - Ubuntu GNU/Linux ${arch_a}
item bionic Ubuntu 18.04 LTS Bionic Beaver
item disco Ubuntu 19.04 Disco Dingo
item
item changebits Architecture: ${arch_a}
item back Back
choose ubuntu_version || goto ubuntu_exit

:mirrorcfg
set mirrorcfg mirror/suite=${ubuntu_version}
set dir ${ubuntu_base_dir}/dists/${ubuntu_version}-updates/main/installer-${arch_a}/current/images/netboot/ubuntu-installer/${arch_a}
iseq ${ubuntu_version} disco && set dir ${ubuntu_base_dir}/dists/${ubuntu_version}/main/installer-${arch_a}/current/images/netboot/ubuntu-installer/${arch_a} ||

:ubuntu_boot_type
menu ${os} [${ubuntu_version}] Installer
item --gap Install types
item install ${space} Install
item rescue ${space} Rescue Mode
item expert ${space} Expert Install
item preseed ${space} Unattended: specify preseed url...
choose --default ${type} type || goto ubuntu_main
echo ${cls}
goto ubuntu_${type}

:ubuntu_preseed
echo -n Specify preseed URL for ${ubuntu_version}: && read preseedurl
set kernelargs auto=true priority=critical preseed/url=${preseedurl}
goto ubuntu_boot

:ubuntu_expert
set kernelargs priority=low
goto ubuntu_boot

:ubuntu_rescue
set kernelargs rescue/enabled=true
goto ubuntu_boot

:ubuntu_install
:ubuntu_boot
imgfree
kernel http://${ubuntu_mirror}/${dir}/linux
initrd http://${ubuntu_mirror}/${dir}/initrd.gz
imgargs linux initrd=initrd.gz vga=788 ${kernelargs}
boot

:changebits
iseq ${arch} amd64 && set arch i386 || set arch amd64
goto main_ubuntu

:ubuntu_exit
clear menu
exit 0


So, I manage to boot on the ipxe, I arrive on the menu but that I select WDS, I have an error, could you help me?
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)