How To Install Windows Server 7 8 10 12 2008 2012 2014 2016 Servers Desktops using Linux tftp, dhcpd and samba

It has been a big pain for a long-time to install Windows from a Linux environment.  I used to run a windows install server and it never worked right for some reason (the install would fail on most servers).

Before getting start be sure to setup your samba share so once you boot into WinPE you can mount the install for whatever Windows you want

/etc/samba/smb.conf

[smbwinstall]
path = /tftpboot/images/winstall
guest ok = yes
directory mask = 0775

It's much easier and stable to deploy all OS's using a Linux tftp and dhcpd server:

 

WinPE Boot with pxelinux
It requires pxelinux 6.04 or higher so I've included that in winpe-libs.tar.gz

cd /tftpboot/images
wget realtechtalk.com/downloads/winpe-tftp.tar.gz
wget realtechtalk.com/downloads/winpe-tftp-root-libs.tar.gz
#Extract it into your /tftpboot/

cd /tftpboot/
tar -zxvf winpe-tftp-root-libs.tar.gz
ldlinux.c32
libcom32.c32
libutil.c32
linux.c32
menu.c32
pxelinux.0
wimboot


cp winpe-libs/* /tftpboot/

tar -zxvf winpe-tftp.tar.gz
Edit your /tftpboot/pxelinux.cfg/default

Add this:

MENU TITLE WinPE
label WinPE
com32 linux.c32
APPEND wimboot initrdfile=../images/winpe/bootmgr,../images/winpe/bcd,../images/winpe/boot.sdi,../images/winpe/boot.wim

#the next step is to make sure you have a samba or windows fileshare with the windows install you want

mkdir -p /tftpboot/images/winstall
#mount and copy the install you want

pxeboot the WinPE image then mount the remote share and install windows from it

Get booting!

If everything was done right you should be able to boot off your NIC, see the pxellinux menu for winpe and boot into it.

Once in WinPE type the following command to mount your install share:

net use z: \\192.168.5.20\winstall

z:

 

Of course change the IP and "winstall" share name to match what you have on your network.
 


#errors
linux.c32: not a COM32R image this means your pxelinux is probably trying to open an image like Winpe with wimboot and is too old (upgrade to at least pxelinux 6.04.  The pxelinux.0 file in the winpe-tftp.tar.gz file is from 6.04 so it will automatically update if you overwrite your pxelinux.0 file
 


Tags:

install, server, servers, desktops, linux, tftp, dhcpd, sambait, samba, winpe, mount, etc, smb, conf, smbwinstall, tftpboot, images, winstall, ok, directory, deploy, os, pxelinux, requires, ve, included, libs, tar, gz, wget, realtechtalk, downloads, extract, zxvf, ldlinux, libcom, libutil, wimboot, cp, edit, cfg, default, label, append, initrdfile, bootmgr, bcd, sdi, wim, fileshare, mkdir, pxeboot, booting, nic, pxellinux, z, ip, quot, errors, upgrade, automatically, update, overwrite,

Latest Articles

  • vi cannot copy and paste automatic visual mode solution
  • python3 error Ubuntu Linux error solution SyntaxError: invalid syntax line 12 pip{sys.version_info.major}
  • Could not read response to hello message from hook [ ! -f /usr/bin/snap ] || /usr/bin/snap advise-snap --from-apt 2>/dev/null || true: Connection reset by peer
  • -bash: expr: command not found Linux Debian Mint Ubuntu
  • How to remove metadata from pdf on Linux Ubuntu
  • How to install and configure haproxy on Linux Ubuntu Debian
  • Linux Ubuntu Mint Gnome keyboard Typing not working in certain application or window solution
  • talib/_ta_lib.c:747:10: fatal error: ta-lib/ta_defs.h: No such file or directory
  • How to install Windows or other OS and then bring to another computer by using a physical drive and Virtual Machine with QEMU
  • PXE-E23 Error BOOTx64.EFI GRUB booting is 0 bytes tftp pxe dhcp solution NBP filesize is 0 Bytes
  • vagrant install on Debian Mint Ubuntu Linux RHEL Quick Setup Guide Tutorial
  • RHEL 8 CentOS 8, Alma Linux 8, Rocky Linux 8 System Not Booting with RAID or on other servers/computers Solution for dracut and initramfs missing kernel modules
  • How to Upgrade to Debian 11 from Version 8,9,10
  • Ubuntu Linux Mint Debian Redhat Cannot View Files on Android iPhone USB File Transfer Not Working Solution
  • Virtualbox Best Networking Mode In Lab/Work Environment without using NAT Network or Bridged
  • debootstrap how to install Ubuntu, Mint, Debian install
  • Linux grub not using UUID for the root device instead it uses /dev/sda1 or other device name solution
  • How To Restore Partition Table on Running Linux Mint Ubuntu Debian Machine
  • Debian Ubuntu apt install stop daemon questions/accept the default action without prompting
  • iptables NAT how to enable PPTP in newer Debian/Ubuntu/Mint Kernels Linux