I use the debian-installer-9-netboot-amd64 package, version 20170615+deb9u1, to automaticly install lot of computers. I use the following preseed:

# Langue et mappage clavier
d-i         debian-installer/locale         select fr_FR.UTF-8
d-i         debian-installer/language       string fr
d-i         debian-installer/country        string FR
d-i         console-keymaps-at/keymap       select fr-latin9
d-i         keyboard-configuration/xkb-keymap   select fr-latin9
# Réseau
## Ces lignes sont ignorées car le preseed arrive après l'initialisation du réseau
## Je les laisse à titre d'information
d-i         netcfg/choose_interface         select auto
d-i         netcfg/get_hostname         string debian
d-i         netcfg/get_domain string        ati33.lan
d-i         hw-detect/load_firmware         boolean false
# Dépôt
d-i         mirror/country              string manual
d-i         mirror/http/hostname            string ftp.fr.debian.org
d-i         mirror/http/directory           string /debian
d-i         mirror/http/proxy           string http://repos.ati33.lan:3142/
d-i         mirror/suite                string stretch
d-i         mirror/udeb/suite           string stretch
d-i         apt-setup/non-free          boolean false
d-i         apt-setup/contrib           boolean false
d-i         apt-setup/services-select       multiselect security, updates
d-i         apt-setup/security_host         string security.debian.org
d-i         apt-setup/source            boolean false
# Utilisateurs et mots de passe
d-i         passwd/root-login           boolean true
d-i         passwd/make-user            boolean false
d-i         passwd/root-password-crypted        password\
# Horloge
d-i         clock-setup/utc             boolean true
d-i         time/zone               string Europe/Paris
d-i         clock-setup/ntp             boolean true
d-i         clock-setup/ntp-server          string ntp.ati33.lan
# Partitionnement
d-i         partman-auto/method         string regular
## Une seule partition ext4 pour / sur tout le disque
d-i         partman-auto/expert_recipe      string      \
                root ::                     \
                    4096 4096 -1 ext4           \
                        $primary{ }         \
                        method{ format }        \
                        format{ }           \
                        use_filesystem{ }       \
                        filesystem{ ext4 }      \
                        mountpoint{ / }         \
                        label{ nomachanger }        \
                        options/discard{ discard }  \
                        options/noatime{ noatime }  \
                        options/nodiratime{ nodiratime }\
d-i         partman-auto/choose_recipe      select root
d-i         partman-basicfilesystems/no_swap    boolean false
d-i         partman-partitioning/confirm_write_new_label\
                                boolean true
d-i         partman/choose_partition        select finish
d-i         partman/confirm             boolean true
d-i         partman/confirm_nooverwrite     boolean true
d-i         partman-basicmethods/method_only    boolean false
# Système de base
d-i         base-installer/kernel/image     string linux-image-adm64
# Installation des paquets
tasksel         tasksel/first               multiselect standard
## Ajout de paquets en plus
d-i         pkgsel/include              string python3-dialog tftp console-setup
## Configuration du mappage clavier de la console
console-setup       console-setup/fontsize          string  8x16
console-setup       console-setup/charmap47 select      UTF-8
console-setup       console-setup/fontsize-text47       select  8x16
console-setup       console-setup/fontface47        select  Fixed
console-setup       console-setup/store_defaults_in_debconf_db\
                                boolean true
console-setup       console-setup/fontsize-fb47     select  8x16
console-setup       console-setup/codesetcode       string  Lat15
console-setup       console-setup/codeset47 select      # Latin1 and Latin5 - western Europe and Turkic languages
keyboard-configuration  keyboard-configuration/layoutcode   string  fr
keyboard-configuration  keyboard-configuration/variant      select  Français - Français (variante)
keyboard-configuration  keyboard-configuration/unsupported_options\
                                boolean true
keyboard-configuration  keyboard-configuration/compose      select  No compose key
keyboard-configuration  keyboard-configuration/switch       select  No temporary switch
keyboard-configuration  keyboard-configuration/store_defaults_in_debconf_db\
                                boolean true
keyboard-configuration  keyboard-configuration/layout       select  
keyboard-configuration  keyboard-configuration/unsupported_config_options\
                                boolean true
keyboard-configuration  keyboard-configuration/model        select  PC générique 105 touches (intl)
keyboard-configuration  keyboard-configuration/toggle       select  No toggling
keyboard-configuration  keyboard-configuration/modelcode    string  pc105
keyboard-configuration  keyboard-configuration/unsupported_layout\
                                boolean true
keyboard-configuration  keyboard-configuration/ctrl_alt_bksp    boolean false
keyboard-configuration  keyboard-configuration/xkb-keymap   select  fr(latin9)
keyboard-configuration  keyboard-configuration/variantcode  string  oss
keyboard-configuration  keyboard-configuration/altgr        select  The default for the keyboard layout
keyboard-configuration  keyboard-configuration/optionscode  string  
keyboard-configuration  keyboard-configuration/unsupported_config_layout\
                                boolean true
## Pas de mise à jour car la dernière version est déjà téléchargée des dépôts
d-i         pkgsel/upgrade              select none
## Afin de permettre à Debian de savoir quels paquets sont populaires
popularity-contest  popularity-contest/participate      boolean true
d-i         grub-installer/only_debian      boolean true
d-i         grub-installer/with_other_os        boolean true
d-i         grub-installer/bootdev          string default
# Post-installation
d-i         finish-install/reboot_in_progress   note
## On télécharge l'installateur de la surcouche dans le home de root
d-i         preseed/late_command            string\
                in-target sh -c "echo get systems/debian-installer/9/preseeds/ati33/install.py /root/install.py | tftp"

I load it by putting these options at boot vga=788 auto priority=critical url="<lien tftp vers le preseed>" hw-detect/load_firmware=false debian-installer/locale=fr_FR.UTF-8 debian-installer/language=fr debian-installer/country=FR keyboard-configuration/xkb-keymap=fr-latin9.

On most computers, it works well, but I have some of them that does not work at all. They stop on a message telling me there's not root partition defined.

When I go on second console, I see that there's no /dev/sda file (and no disk at all). Searching on it, I tryed to load the ahci kernel module (modprobe -iv ahci that loads libata and libahci with it).

When I don't use preseed (with only vga=788 option) the ahci module is loaded.

Anyone knows how to force this kernel module?



d-i preseed/early_command string sed -i '/depmod -a > .dev.null 2>&1 || true/a modprobe ahci || true' /bin/hw-detect

to your preseed file.

This is only a hack that works for me without modifying the kernel, initrd or the installer-udeb-repository and it may not work with other versions of the installer.

see Debian Bug #872410

  • Yes, I know since I'm Gilles MOREL. Thanks for the answer. But I'm using “d-i preseed/early_command string sed -i '/^update-dev >.dev.null$/i udevadm control --reload' /bin/hw-detect” instead, like I told thee in my answer on the bug. – user245887 May 4 '18 at 10:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy