Hi All, just for All and for @_Antoine
I managed to get working PXE unattended install Zorin OS 18.1
Shortly said:
You need NFS 4 and PXE on your server.
Then extract initrd from Zorin-OS-18.1-Core-64-bit.iso
mkdir -p /tmp/initrd_patch/extracted
cd /tmp/initrd_patch
unmkinitramfs /srv/tftp/zorin/initrd extracted/
You need to replace 2 functions in casper:
nano extracted/main/scripts/casper
do_nfsmount() {
rc=1
modprobe "${MP_QUIET}" nfs
modprobe "${MP_QUIET}" nfsv4[ "$quiet" != "y" ] && log_begin_msg "Trying mount -t nfs4 -o ro,nolock ${NFSROOT} ${mountpoint}" i=0 while [ "$i" -lt 30 ]; do if mount -t nfs4 -o ro,nolock "${NFSROOT}" "${mountpoint}"; then if is_casper_path $mountpoint; then rc=0 [ "$quiet" != "y" ] && log_end_msg 0 break else umount $mountpoint fi fi sleep 1 i="$(($i + 1))" done return ${rc}}
AND
nfsroot=)
NFSROOT="${x#nfsroot=}"
if [ "${NFSROOT#,}" != "${NFSROOT}" ]; then
NFSOPTS="${NFSROOT#,}"
NFSROOT="${NFSROOT%%,}"
fi
export NFSROOT
export NFSOPTS
;;
recreate new initrd:
cd /tmp/initrd_patch/extracted
(
find early -mindepth 1 -printf "%P\n" | cpio -D early -o -H newc
find early2 -mindepth 1 -printf "%P\n" 2>/dev/null | cpio -D early2 -o -H newc 2>/dev/null
find main -mindepth 1 -printf "%P\n" | cpio -D main -o -H newc | zstd -19 -T0
) | sudo tee /srv/tftp/zorin/initrd > /dev/null
3. privilegies TFTP
sudo chmod 644 /srv/tftp/zorin/initrd
And group.cfg looks like:
menuentry "Zorin OS 18.1 - Automaticka instalace" {
set gfxpayload=keeplinux /zorin/vmlinuz \ ip=dhcp \ boot=casper \ netboot=nfs \ nfsroot=10.0.0.51:/zorin \ url=http://10.0.0.51/zorin/zorin.seed \ fsck.mode=skip \ automatic-ubiquity \ noprompt \ quiet \ --- initrd /zorin/initrd}
It was very quick. but by the time I'll try to make detailed guide.