FOG

De wiki.franca.unesp.br
Revisão de 14h23min de 24 de março de 2022 por Guilherme (Discussão | contribs) (Configuração no DHCP)
Ir para: navegação, pesquisa

Configuração no DHCP

next-server <IP_do_servidor_FOG>;
option tftp-server-name "<IP_do_servidor_FOG>";  
class "pxeclient" {
    match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";

    if substring (option vendor-class-identifier, 15, 5) = "00000" {
        # BIOS client 
        filename "undionly.kpxe";
    }
    elsif substring (option vendor-class-identifier, 15, 5) = "00006" {
        # EFI client 32 bit
        filename   "ipxe32.efi";
    }
    else {
        # default to EFI 64 bit
        filename   "ipxe.efi";
    }
}
filename "ipxe.efi";  #opcao UEFI
filename "undionly.kpxe"; #opcao para maquinas antigas

Using FOG to PXE boot into your favorite installer images

https://forums.fogproject.org/topic/10944/using-fog-to-pxe-boot-into-your-favorite-installer-images/21?lang=pt-BR

WinPE 10 for BIOS and UEFI based systems

1. First we’ll create the required directories:

mkdir -p /tftpboot/os/winpe

2. Now we’ll mount the WinPE iso over the loop directory. Then we’ll copy the contents of the DVD to the directory we built above.

mount -o loop /{full path where you have the iso stored}/WinPE_amd64.iso /mnt/loop

cp /mnt/loop/Boot/BCD /tftpboot/os/winpe/
cp /mnt/loop/Boot/boot.sdi /tftpboot/os/winpe/
cp /mnt/loop/sources/boot.wim /tftpboot/os/winpe/
umount /mnt/loop

3. Download and install the latest wimboot kernel and extract it from the zip file.

cd /tmp
wget http://git.ipxe.org/releases/wimboot/wimboot-latest.zip
unzip wimboot-latest.zip

4. Copy the wimboot file from the archive directory to root of the /tftpboot directory (we’ll need this for every windows boot media, so we’ll place it in a common spot).

cp ./wimboot-2.6.0-signed/wimboot /tftpboot

5. The last bit of magic we need to do is setup a new FOG iPXE boot menu entry for this OS. 6. In the fog WebGUI go to FOG Configuration->iPXE New Menu Entry Set the following fields

Menu Item: os.WinPE10

Description: WinPE 10

Parameters:

set tftp-path tftp://${fog-ip}
set pe-path ${tftp-path}/os/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 boot.wim ${pe-path}/boot.wim boot.wim
boot || goto MENU

7. That’s it, just pxe boot your target system and pick WinPE 10 from the FOG iPXE boot menu.


Linux Mint

1. First we’ll create the required directories:

mkdir -p /images/os/mint/18.1
mkdir -p /tftpboot/mint/18.1

2. Now we’ll mount the Linux Mint 18.1 installer over the loop directory. Then we’ll copy the contents of the DVD to the directory we built above.

mount -o loop -t iso9660 /{full path where you have the iso stored}/linuxmint-18.1-cinnamon-64bit.iso /mnt/loop

cp -R /mnt/loop/* /images/os/mint/18.1
umount /mnt/loop

3. Finally we’ll copy the pxe boot kernel and intfs to the tftpboot directory.

cp /images/os/mint/18.1/casper/vmlinuz /tftpboot/mint/18.1
cp /images/os/mint/18.1/casper/initrd.lz /tftpboot/mint/18.1

4. The last bit of magic we need to do is setup a new FOG iPXE boot menu entry for this OS. 5. In the fog WebGUI go to FOG Configuration->iPXE New Menu Entry Set the following fields

Menu Item: os.Mint18.1

Description: Linux Mint 18.1

Parameters:

kernel tftp://${fog-ip}/mint/18.1/vmlinuz
initrd tftp://${fog-ip}/mint/18.1/initrd.lz
imgargs vmlinuz root=/dev/nfs boot=casper netboot=nfs nfsroot=${fog-ip}:/images/os/mint/18.1/ locale=en_US.UTF-8 keyboard-configuration/layoutcode=us quiet splash
boot || goto MENU

Menu Show with: All Hosts

6. That’s it, just pxe boot your target system and pick Linux Mint 18.1 from the FOG iPXE boot menu.

Hirens Boot CD 15.2

1. Copiar o arquivo .ISO do Hiren Boot CD 15.2 para a pasta /images/os/hirens/

2. Adicionar uma nova entrada no menu PXE em: FOG Configuration->iPXE New Menu Entry

Menu Item: Hirens_boot_CD

Description: Hirens Boot CD

Parameters:

initrd nfs://${fog-ip}:/images/os/hirens/hirens.iso
chain memdisk iso raw
boot || goto MENU