Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 42 additions & 0 deletions _includes/example-preseed-excerpt.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
### Apt setup
# Choose, if you want to scan additional installation media
# (default: false).
d-i apt-setup/cdrom/set-first boolean false
# You can choose to install non-free firmware.
#d-i apt-setup/non-free-firmware boolean true
# You can choose to install non-free and contrib software.
#d-i apt-setup/non-free boolean true
#d-i apt-setup/contrib boolean true
# Uncomment the following line, if you don't want to have the sources.list
# entry for a DVD/BD installation image active in the installed system
# (entries for netinst or CD images will be disabled anyway, regardless of
# this setting).
#d-i apt-setup/disable-cdrom-entries boolean true
# Uncomment this if you don't want to use a network mirror.
#d-i apt-setup/use_mirror boolean false
# Select which update services to use; define the mirrors to be used.
# Values shown below are the normal defaults.
#d-i apt-setup/services-select multiselect security, updates
#d-i apt-setup/security_host string security.debian.org

# Additional repositories, local[0-9] available
#d-i apt-setup/local0/repository string \
# http://local.server/debian stable main
#d-i apt-setup/local0/comment string local server
# Enable deb-src lines
#d-i apt-setup/local0/source boolean true
# URL to the public key of the local repository; you must provide a key or
# apt will complain about the unauthenticated repository and so the
# sources.list line will be left commented out.
#d-i apt-setup/local0/key string http://local.server/key
# or one can provide it in-line by base64 encoding the contents of the
# key file (with `base64 -w0`) and specifying it thus:
#d-i apt-setup/local0/key string base64://LS0tLS1CRUdJTiBQR1AgUFVCTElDIEtFWSBCTE9DSy0tLS0tCi4uLgo=
# The content of the key file is checked to see if it appears to be ASCII-armoured.
# If so it will be saved with an ".asc" extension, otherwise it gets a '.gpg' extension.
# "keybox database" format is currently not supported. (see generators/60local in apt-setup's source)

# By default the installer requires that repositories be authenticated
# using a known gpg key. This setting can be used to disable that
# authentication. Warning: Insecure, not recommended.
#d-i debian-installer/allow_unauthenticated boolean true
16 changes: 9 additions & 7 deletions _posts/2024/2024-11-12-Cobbler-v3.3.6-Beginners-Guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,12 @@ sed -i "s/pxe_just_once: true/pxe_just_once: false/" /etc/cobbler/settings.yaml
sed -i "s/enable_ipxe: false/enable_ipxe: true/" /etc/cobbler/settings.yaml
```

> Even if you do not enable iPXE above, it won't hurt to symlink the correct file that cobbler points to in the `/etc/cobbler/dhcp.template` file.
>
> ```shell
> ln -s /usr/share/ipxe/undionly.kpxe /var/lib/cobbler/loaders/undionly.kpxe
> ```

Edit the subnet decaration in **/etc/cobbler/dhcp.tempate** to match the **enp0s8** interface:

```shell
Expand Down Expand Up @@ -270,12 +276,12 @@ Now, create the **PXE Client** VM according to the specs described in the **Envi
Finally, create a new Cobbler System, replacing `aa:bb:cc:dd:ee:ff` with the MAC Address of the **PXE Client** VM created above, and sync up Cobbler *(More information on Cobbler autoinstall templates and kickstart files in the* ***Tips & Troubleshooting*** *section below)*:

```shell
cobbler system add --name Fedora34 --profile Fedora34-x86_64 --netboot-enabled true --hostname fedora34 --interface enp0s3 --static true --mac-address "aa:bb:cc:dd:ee:ff" --ip-address 10.0.0.11 --gateway 10.0.0.1 --netmask 255.255.255.0 --name-servers "10.0.0.1"
cobbler system add --name Fedora34 --profile Fedora34-x86_64 --mac-adress "aa:bb:cc:dd:ee:ff" --netboot-enabled true --hostname fedora34 --interface enp0s3 --static true --ip-address 10.0.0.11 --gateway 10.0.0.1 --netmask 255.255.255.0 --name-servers "10.0.0.1"
systemctl restart cobblerd && sleep 10
cobbler sync
```

*leave out the `--static true` option in the above command to configure the PXE client to use DHCP for its IP configuration post-install; if using DHCP, you may omit all the command parameters following `--hostname fedora34`.*
*leave out the `--static true` option in the above command to configure the PXE client to use DHCP for its IP configuration post-install; if using DHCP, you may omit all the command parameters following `--netboot-enabled true`.*

> *The* ***PXE Client*** *VM can now be powered on, and should automatically boot to PXE and install Fedora 34 to the VM HDD using the "Fedora34.ks" kickstart template created above.*
>
Expand All @@ -291,7 +297,7 @@ cobbler import --name=Fedora37 --arch=x86_64 --path=/mnt/Fedora
cobbler distro edit --name Fedora37-x86_64 --kernel-options ""
cat /var/lib/cobbler/templates/sample.ks | grep -v "\--useshadow" | grep -v ^install | sed 's,selinux --disabled,selinux --permissive,' | sed 's,rootpw --iscrypted \$default_password_crypted,rootpw --iscrypted \$default_password_crypted\nuser --groups=wheel --name=fedora --password=\$default_password_crypted --iscrypted --gecos="fedora",' | tee /var/lib/cobbler/templates/Fedora37.ks
cobbler profile edit --name Fedora37-x86_64 --autoinstall Fedora37.ks
cobbler system add --name Fedora37 --profile Fedora37-x86_64 --netboot-enabled true --hostname fedora37 --interface enp0s3 --static true --mac-address "aa:bb:cc:dd:ee:ff" --ip-address 10.0.0.12 --gateway 10.0.0.1 --netmask 255.255.255.0 --name-servers "10.0.0.1"
cobbler system add --name Fedora37 --profile Fedora37-x86_64 --mac-address "aa:bb:cc:dd:ee:ff" --netboot-enabled true --hostname fedora37 --interface enp0s3 --static true --ip-address 10.0.0.12 --gateway 10.0.0.1 --netmask 255.255.255.0 --name-servers "10.0.0.1"
systemctl restart cobblerd && sleep 10
cobbler sync
```
Expand Down Expand Up @@ -472,10 +478,6 @@ systemctl restart tftp httpd
echo $SHELL
```

1. The PXE client software that comes with VirtualBox VM firmware **DOES NOT** support HTTP as a download protocol, so it may be best to leave iPXE disabled in `/etc/cobbler/settings.yaml`

- HTTP can always be utilized if you boot the PXE client from CD using the latest [ipxe.iso](https://boot.ipxe.org/ipxe.iso)

1. By default, Cobbler's DHCP server attempts to detect the PXE client's boot firmware type in order to provide a BIOS or UEFI compatible bootloader *(BIOS: "grub.0" - UEFI: "grubx64.efi")*. If using **BIOS firmware** for the PXE client VM, the Cobbler server's DHCP service may not provide the right bootloader.

1. manually set the bootloader for a Cobbler Profile or System with the following command (the `filename` value corresponds to the `filename` variable for the Cobbler System in the generated `dhcpd.conf` file, and is a local system path to the desired bootloader file relative to Cobbler's tftp root directory: `/var/lib/tftpboot`):
Expand Down
Loading
Loading