Differences between revisions 1 and 89 (spanning 88 versions)
Revision 1 as of 2004-10-05 02:52:52
Size: 2034
Editor: anonymous
Comment:
Revision 89 as of 2009-10-07 14:30:18
Size: 4180
Editor: ?DavidGreaves
Comment: add note re debconf-devel docs
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
## Auto-converted by kwiki2moinmoin v2005-10-07 ## page was renamed from DebianInstallerPreseed
~-Translation(s):
[[DebianInstaller/Preseed|English]], [[fr/DebianInstaller/Preseed|Français]] -~
----
Line 3: Line 6:
Most of the questions asked by d-i can be preseeded by setting the answers in the debconf database. This can be used to do automatic installs. This page gathers our collective knowledge on the topic, so please add any tips you have. Preseeding provides a way to set answers to questions asked during the installation process, without having to manually enter the answers while the installation is running. This makes it possible to fully automate most types of installation and even offers some features not available during normal installations.
Line 5: Line 8:
There are currently two main mechanisms to preseed debconf values.
Values can be set on the installer's boot line, for example:
{{{
  linux debconf/priority=critical
}}}
Most of the questions asked by DebianInstaller can be preseeded by setting the answers in the [[debconf]] database. The Installation Guide includes an [[http://d-i.alioth.debian.org/manual/en.i386/apb.html|extensive appendix]] dedicated to preseeding and includes a complete example. Feel free to add any information that is not covered in the manual to the notes below.
Line 11: Line 10:
The preseed udebs can be used to load a file containing values to preseed, either from the network or local media. The installation manual explains how to set this up: http://d-i.alioth.debian.org/manual/en.i386/ch04s07.html#id2511063 = Examples =
Post here any links you have to example preseed files. Note that using any of these files directly is not wise, as a malicious person could probably come up with values for a preseed file that makes d-i misbehave. Also, the files are downloaded over http, so are vulnerable to man-in-the-middle spoof attacks. The best way to use any preseed file is to copy it to your own local web server or media, and look it over before using it.
Line 13: Line 13:
Note that most preseeding support has been added after rc1 of the installer.  * Christian Perrier's page documenting automated d-i installs in vmware, using netboot. http://people.debian.org/~bubulle/d-i/vmware-fai.html
## Broken link : * Simon Kirkby's fully automatic basic install. !Warning! will format machine without asking. http://interthingy.com/digby
 * Holger Levsen's d-i examples showing a way to preserve partitions and ssh-host-keys: http://layer-acht.org/d-i/
 * Enrico Zini's conditional partitioning hints: http://www.enricozini.org/2008/tips/d-i-conditional-partitioning.html
 * Using network-console and preseeding is described on two pages, DebianInstaller/NetworkConsole and [[DebianInstaller/Remote]]
 * Phil Hands' d-i setup, that allows minimal (i.e. no exim) installs, works from CD, PXE & USB (read the HOWTO's), and allows custom configs to be specified at the boot: prompt http://hands.com/d-i/
 * DebianInstaller/AsSshClient for using d-i as a ssh terminal
 * Instalinux lets you answer a few questions on the web and generate an ISO image that can be used to install Debian noninteractively, or a preseed file that you can use with other install methods. http://www.instalinux.com/
 * Christian Perrier documented a D-I demo setup in DebianInstaller/BabelBox
 * Debian Administration has an article on using preseeding: http://www.debian-administration.org/articles/394
 * Filip Van Raemdonck documented modifying an iso to include the preseed file in [[DebianInstaller/Preseed/EditIso]]
 * Gürkan Sengün with a very simple preseed.cfg for fully automatic installation of workstations using dphys-config: http://debian.ethz.ch/d-i/p (Used for i386, amd64 installs on a wide variety of hardware configurations, with a wide variety of use of the computers. Including large repositories of special software)
 * Matt Taggart's notes and configuration, including using serial console and postfix. http://lackof.org/taggart/hacking/d-i_preseed/
Line 15: Line 27:
= Preseeding language and country =
Since these questions come before the preseed udebs do their work, language and country can only be preseeded when the installer is booted, perhaps via a modified syslinux.cfg file.
Here's an example:
{{{
  languagechooser/language-name=French
  countrychooser/country-name-shortlist=France
  countrychooser/country-name=France
}}}

Apparently two values in countrychooser must be seeded (why?).

= Preseeding mirror =
If you're doing a netboot install or the like, it's nice to be able to preseed a mirror to use. Here's an example in preseed file format, that makes it use a manually entered mirror:
{{{
  d-i mirror/country string enter information manually
  d-i mirror/http/hostname string your-mirror-name-here
  d-i mirror/http/directory string /debian
  d-i mirror/suite string unstable
  #d-i mirror/http/proxy string http://10.11.12.1:3128/
}}}

= Preseeding partman =
Realistically, only the automatic partitioning choices of partman can be preseeded. To get any more control, you really want to provide a partman-auto recipe (how?). Here's one value that should work as of a few days ago:
{{{
  d-i partman/confirm boolean true
}}}
= Notes =
 * Do not work off a {{{debconf-get-selections}}} ({{{--installer}}}) generated {{{preseed.cfg}}} but get the values from it and modify the example preseed file with them.
 * Be aware there is only one space in preseed files between subkey and value on "{{{owner key/subkey value}}}" lines.
 * Do not reboot in the {{{base-config/late_command}}} command, the installation process will start again at the start of the 2nd stage.
 * Preseeding has changed significantly in etch, preseed files for sarge will need to be updated or re-done. The largest change is the removal of base-config, which means that {{{base-config/late_command}}} and {{{base-config/early_command}}} are no longer available.
 * To install additional packages in etch, you can {{{preseed preseed/early_command}}} to run "apt-install package".
 * Look in debconf-devel(7) in the debconf-doc package for more docs about d-i and debian-installer preseed questions.

Translation(s): English, Français


Preseeding d-i

Preseeding provides a way to set answers to questions asked during the installation process, without having to manually enter the answers while the installation is running. This makes it possible to fully automate most types of installation and even offers some features not available during normal installations.

Most of the questions asked by DebianInstaller can be preseeded by setting the answers in the debconf database. The Installation Guide includes an extensive appendix dedicated to preseeding and includes a complete example. Feel free to add any information that is not covered in the manual to the notes below.

Examples

Post here any links you have to example preseed files. Note that using any of these files directly is not wise, as a malicious person could probably come up with values for a preseed file that makes d-i misbehave. Also, the files are downloaded over http, so are vulnerable to man-in-the-middle spoof attacks. The best way to use any preseed file is to copy it to your own local web server or media, and look it over before using it.

Notes

  • Do not work off a debconf-get-selections (--installer) generated preseed.cfg but get the values from it and modify the example preseed file with them.

  • Be aware there is only one space in preseed files between subkey and value on "owner key/subkey value" lines.

  • Do not reboot in the base-config/late_command command, the installation process will start again at the start of the 2nd stage.

  • Preseeding has changed significantly in etch, preseed files for sarge will need to be updated or re-done. The largest change is the removal of base-config, which means that base-config/late_command and base-config/early_command are no longer available.

  • To install additional packages in etch, you can preseed preseed/early_command to run "apt-install package".

  • Look in debconf-devel(7) in the debconf-doc package for more docs about d-i and debian-installer preseed questions.