Linux Mint 21.1 Preseed asks for installation Method

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Mantarochen01
Level 1
Level 1
Posts: 3
Joined: Wed Jan 25, 2023 3:50 am

Linux Mint 21.1 Preseed asks for installation Method

Post by Mantarochen01 »

Greetings,

I've successfully written a preseed, grub and isolinux cfg file for a fully automated Mint install.

Everything is working as expected with one exception.

The installer still asks me what installation method I want to use. "Normal installation, or Minimal installation".
After confirming what install type I want, the rest of the installation is automatic as it should be.

Am I missing something?

Here are my seed and cfg. files:
Seefile:

Code: Select all

# Enable extras.ubuntu.com.
d-i     apt-setup/extras        boolean true
# Install the Kubuntu desktop.
#tasksel tasksel/first   multiselect kubuntu-desktop
# Install KDE translation packages.
#d-i     pkgsel/language-pack-patterns   string language-pack-kde-$LL kde-i18n-$LL
# Install the KDE oem-config frontend (if in OEM mode).
#d-i     oem-config-udeb/frontend        string kde
# On live DVDs, don't spend huge amounts of time removing substantial
# application packages pulled in by language packs. Given that we clearly
# have the space to include them on the DVD, they're useful and we might as
# well keep them installed.

# -------- Localization --------

d-i debian-installer/locale string en_US.UTF-8

# -------- Keyboard --------

d-i console-setup/ask_detect boolean false

d-i console-setup/layoutcode string us

d-i keyboard-configuration/xkb-keymap select us

# -------- Network --------

d-i netcfg/choose_interface select auto

d-i netcfg/link_wait_timeout string 10

d-i netcfg/dhcp_timeout string 10

d-i netcfg/dhcpv6_timeout string 1


# Set default names to prevent prompts, overwritten by DHCP names.

d-i netcfg/get_hostname string unassigned-hostname

d-i netcfg/get_domain string unassigned-domain


# Disable that annoying WEP key dialog.

d-i netcfg/wireless_wep string

# -------- Hardware Firmware --------

d-i hw-detect/load_firmware boolean true

# -------- Accounts --------

# disable root user

d-i passwd/root-login boolean false


# base user for system

d-i passwd/user-fullname string

d-i passwd/username string test

d-i passwd/user-password-crypted password $6$X6aACJJM$_________________CENSORED /2aCKTbfCtYkemKygCIoh/

d-i passwd/user-uid string 1000

d-i passwd/user-default-groups string cdrom video sudo ssh plugdev

d-i user-setup/encrypt-home boolean false

# -------- Clock and Timezone --------

d-i clock-setup/utc boolean false

d-i time/zone string America/Los_Angeles

d-i clock-setup/ntp boolean true

# Partitioning
d-i partman-auto/disk string /dev/sda
d-i partman-auto/method string lvm
d-i partman-auto/purge_lvm_from_device boolean true
d-i partman-lvm/confirm boolean true
d-i partman-lvm/device_remove_lvm boolean true
d-i partman-lvm/device_remove_lvm_span boolean true
d-i partman-auto/expert_recipe string   \
    boot-root ::                        \
        100 5000 -1 ext4                \
            $defaultignore{ }           \
            $primary{ }                 \
            method{ lvm }               \
            device{ /dev/sda }          \
            vg_name{ openstack }        \
        .                               \
        512 1000 1000 ext4              \
            $primary{ }                 \
            $bootable{ }                \
            method{ format }            \
            format{ }                   \
            use_filesystem{ }           \
            filesystem{ ext4 }          \
            mountpoint{ /boot }         \
        .                               \
        128000 50 128000 linux-swap     \
            method{ swap }              \
            format{ }                   \
        .                               \
        20000 60 50000 ext4             \
            $lvmok{ }                   \
            lv_name{ root }             \
            method{ format }            \
            format{ }                   \
            use_filesystem{ }           \
            filesystem{ ext4 }          \
            in_vg{ openstack }          \
            mountpoint{ / }             \
        .               \
        1000000 70 -1 ext4              \
            $lvmok{ }                   \
            lv_name{ var }              \
            method{ format }            \
            format{ }                   \
            use_filesystem{ }           \
            filesystem{ ext4 }          \
            in_vg{ openstack }          \
            mountpoint{ /var }          \
        .

d-i partman-auto/choose_recipe select boot-root
d-i partman/confirm_write_new_label boolean true
d-i partman/choose_partition select finish
d-i partman/confirm boolean true
d-i partman-auto/init_automatically_partition select biggest_free
d-i partman/confirm_nooverwrite boolean true
d-i partman-lvm/confirm_nooverwrite boolean true
d-i partman-auto-lvm/guided_size string max

# Set to true if you want to encrypt the first user's home directory.
d-i user-setup/encrypt-home boolean false

# -------- Package Selection --------

# Main tasksel server packages

tasksel tasksel/first multiselect server, openssh-server


# Additional packages to install

d-i pkgsel/include string openssh-server python-software-properties inotify-tools curl unattended-upgrades sysstat nmon tmux ssh vim haveged


# Upgrade packages after bootstrap

d-i pkgsel/upgrade select full-upgrade


# Install security updates automatically

d-i pkgsel/update-policy select unattended-upgrades

# -------- Console Setup --------

# Verbose startup output, drop to console (text) login by default.

d-i debian-installer/quiet  boolean false

d-i debian-installer/splash boolean false

# -------- Boot Loader Installation --------

# Assume one OS, install to default device, add other OS's if found.

d-i grub-installer/only_debian boolean true

d-i grub-installer/with_other_os boolean true

d-i grub-installer/bootdev  string default

d-i grub-installer/timeout  string 2

# -------- Finish Installation --------

d-i cdrom-detect/eject boolean true

d-i finish-install/reboot_in_progress note



# -------- Post Installation --------

# After system is setup (before reboot), run post-install script.

#

# This command is run just before the install finishes, but when there is

# still a usable /target directory. You can chroot to /target and use it

# directly, or use the apt-install and in-target commands to easily install 


grub and isolinux cfg:

Code: Select all

 loadfont unicode

set menu_color_normal=white/black
set menu_color_highlight=black/light-gray

menuentry "Autoinstall Test" --class linuxmint {
	set gfxpayload=keep
	linux	/casper/vmlinuz  file=/cdrom/preseed/linuxmint.seed auto=true priority=critical debian-installer/locale=en_US keyboard-configuration/layoutcode=us ubiquity/reboot=true languagechooser/language-name=English countrychooser/shortlist=US localechooser/supported-locales=en_US.UTF-8 boot=casper automatic-ubiquity initrd=/casper/initrd.lz quiet splash noprompt noshell --- quiet splash --
	initrd	/casper/initrd.gz
}
menuentry "Start Linux Mint 21.1 Cinnamon 64-bit (compatibility mode)" {
	linux	/casper/vmlinuz  file=/cdrom/preseed/linuxmint.seed boot=casper iso-scan/filename=${iso_path} noapic noacpi nosplash irqpoll nomodeset --
	initrd	/casper/initrd.gz
}
menuentry "OEM install (for manufacturers)" {
	set gfxpayload=keep
	linux	/casper/vmlinuz  file=/cdrom/preseed/linuxmint.seed oem-config/enable=true only-ubiquity boot=casper iso-scan/filename=${iso_path} quiet splash --
	initrd	/casper/initrd.gz
}
grub_platform
if [ "$grub_platform" = "efi" ]; then
menuentry 'Boot from next volume' {
	exit 1
}
menuentry 'UEFI Firmware Settings' {
	fwsetup
}
else
menuentry 'Test memory' {
	linux16 /boot/memtest86+.bin
}
fi 

Code: Select all

 default vesamenu.c32
timeout 100

menu background splash.png
menu title Abschlussprojekt2023

menu color screen	37;40      #80ffffff #00000000 std
MENU COLOR border       30;44   #40ffffff #a0000000 std
MENU COLOR title        1;36;44 #ffffffff #a0000000 std
MENU COLOR sel          7;37;40 #e0ffffff #20ffffff all
MENU COLOR unsel        37;44   #50ffffff #a0000000 std
MENU COLOR help         37;40   #c0ffffff #a0000000 std
MENU COLOR timeout_msg  37;40   #80ffffff #00000000 std
MENU COLOR timeout      1;37;40 #c0ffffff #00000000 std
MENU COLOR msg07        37;40   #90ffffff #a0000000 std
MENU COLOR tabmsg       31;40   #ffDEDEDE #00000000 std
MENU WIDTH 78
MENU MARGIN 15
MENU ROWS 6
MENU VSHIFT 10
MENU TABMSGROW 11
MENU CMDLINEROW 11
MENU HELPMSGROW 15
MENU HELPMSGENDROW 28

label live
  menu label Autoinstall Test
  kernel /casper/vmlinuz
 append  file=/cdrom/preseed/linuxmint.seed auto=true priority=critical debian-installer/locale=en_US keyboard-configuration/layoutcode=us ubiquity/reboot=true languagechooser/language-name=English countrychooser/shortlist=US localechooser/supported-locales=en_US.UTF-8 boot=casper automatic-ubiquity initrd=/casper/initrd.lz quiet splash noprompt noshell --- quiet splash --
menu default
label xforcevesa
  menu label Start in compatibility mode
  kernel /casper/vmlinuz
  append  file=/cdrom/preseed/linuxmint.seed boot=casper initrd=/casper/initrd.gz noapic noacpi nosplash irqpoll nomodeset --
label oem
  menu label OEM install (for manufacturers)
  kernel /casper/vmlinuz
  append  file=/cdrom/preseed/linuxmint.seed oem-config/enable=true only-ubiquity boot=casper initrd=/casper/initrd.gz quiet splash --
label hdt
  menu label Hardware Detection
  kernel hdt.c32
label local
  menu label Boot from local drive
  COM32 chain.c32
  APPEND hd0
label memtest
  menu label Memory test
  kernel /casper/memtest
  
 
Thanks in advance

Max
Last edited by LockBot on Tue Jul 25, 2023 10:00 pm, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
aloksinha2001
Level 1
Level 1
Posts: 5
Joined: Fri Feb 24, 2023 11:27 am

Re: Linux Mint 21.1 Preseed asks for installation Method

Post by aloksinha2001 »

Well, I suspect, you are missing the following

ubiquity ubiquity/use_nonfree boolean false
(without the di-s)

Referred to from here
viewtopic.php?f=46&t=391307

However, was trying your preseed file (using cubic) on 22.1 Mate, the installer crashes towards the end, once almost all sections are completed.

Will you be kind enough to share a WORKING pre-seed file, when you get a chance
Mantarochen01
Level 1
Level 1
Posts: 3
Joined: Wed Jan 25, 2023 3:50 am

Re: Linux Mint 21.1 Preseed asks for installation Method

Post by Mantarochen01 »

aloksinha2001 wrote: Fri Feb 24, 2023 12:44 pm Well, I suspect, you are missing the following

ubiquity ubiquity/use_nonfree boolean false
(without the di-s)

Referred to from here
viewtopic.php?f=46&t=391307

However, was trying your preseed file (using cubic) on 22.1 Mate, the installer crashes towards the end, once almost all sections are completed.

Will you be kind enough to share a WORKING pre-seed file, when you get a chance
Thanks for the reply ;).

I just tested the configs above with 22.1 Mate without a problem, (at least without it crashing).
Is your installer crashing before or after formatting the disks?
Depending on what type of device you use the handle for the drive is different.
(sda1, nvme01, vd01 etc.)

The formatting option in the config file has to be changed accordingly.

Greetings.

PS: The integrated "iso preview" of cubic is pretty buggy at times, if you used that to test the configs.
aloksinha2001
Level 1
Level 1
Posts: 5
Joined: Fri Feb 24, 2023 11:27 am

Re: Linux Mint 21.1 Preseed asks for installation Method

Post by aloksinha2001 »

The pivotal word here is the partition...

The problem is - in test lab (vitualized - proxmox), the default device is /dev/sdx, while on most of my modern laptops, its /dev/nvme.

When I used the testing iso to boot nvme based laptop, it tired to format the booting /dev/sda (usb disk itself) lol.

FOr now, I do not know, how to make a ISO that will FIRST select /dev/nvme, if not found THEN select /dev/sdx... so had to make TWO boot prompts in the grub...

As far as working preseed file, as I have said elsewhere in this forum, I used chatgpt, to get the outputs, and it worked, straight out of the box.
deepakdeshp
Level 20
Level 20
Posts: 12341
Joined: Sun Aug 09, 2015 10:00 am

Re: Linux Mint 21.1 Preseed asks for installation Method

Post by deepakdeshp »

. As far as working preseed file, as I have said elsewhere in this forum, I used chatgpt, to get the outputs, and it worked, straight out of the box.
Can you elaborate,I am curious to know.
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Mantarochen01
Level 1
Level 1
Posts: 3
Joined: Wed Jan 25, 2023 3:50 am

Re: Linux Mint 21.1 Preseed asks for installation Method

Post by Mantarochen01 »

deepakdeshp wrote: Fri Mar 03, 2023 5:24 pm
. As far as working preseed file, as I have said elsewhere in this forum, I used chatgpt, to get the outputs, and it worked, straight out of the box.
Can you elaborate,I am curious to know.
Tinkered around with ChatGPT myself a few weeks ago.
But my configuration files were already about 95% done when I first tested ChatGPT and it wasn't able to finish the last 5% without throwing errors.

I'd say ChatGPT is viable for more general configurations that are more broadly reported on online. For anything more advanced ChatGPT just starts guessing code and that doesn't end too well most of the time.
aloksinha2001
Level 1
Level 1
Posts: 5
Joined: Fri Feb 24, 2023 11:27 am

Re: Linux Mint 21.1 Preseed asks for installation Method

Post by aloksinha2001 »

deepakdeshp wrote: Fri Mar 03, 2023 5:24 pm
. As far as working preseed file, as I have said elsewhere in this forum, I used chatgpt, to get the outputs, and it worked, straight out of the box.
Can you elaborate,I am curious to know.
By default the order of installation - ssd comes ahead of nvme

Therefore in a hardware that has ONLY nvme - the ssd (/dev/sdx) is actually the bootable usb, so it was installing to the bootable usb (64GB) rather than the internal NVME.

Hence all installations on the nvme devices failed.

I had to make two seed files - selected via the grub menu at the time of install.
Locked

Return to “Installation & Boot”