User Tools

Site Tools


linux:debian:automatic-installation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
linux:debian:automatic-installation [2013/06/20 07:14] – [Example of preseed file] remove 'grub-installer/bootdev' as it's probably not needed or not in this particular case styblalinux:debian:automatic-installation [2013/06/25 02:43] – add some notes - early command, SSH netconsole stybla
Line 6: Line 6:
   * NOTE to myself - preseed file can be supplied by DHCP   * NOTE to myself - preseed file can be supplied by DHCP
   * NOTE to myself - preseed generated by CGI script   * NOTE to myself - preseed generated by CGI script
 +  * NOTE to myself - early command is executed before apt mirror is configure
 +  * NOTE to myself - SSH netconsole works and allows you to jump into a shell, although this led to segfault
 </note> </note>
  
Line 48: Line 50:
  
   * TFTP, DHCP, web server   * TFTP, DHCP, web server
 +  * [[linux:debian:apt-mirror|local Debian mirror]] can be handy, but isn't mandatory
   * time   * time
   * patience   * patience
  
 ==== Example of preseed file ==== ==== Example of preseed file ====
 +
 +I've removed pretty much all comments. What's below is my preseed file. 
 +Please, see example preseed files/documentation for explanation, hints 
 +and, actually, more.
  
 <code> <code>
-Preseeding only locale sets languagecountry and locale.+### l18ni18n, keyboard
 d-i debian-installer/locale string en_US d-i debian-installer/locale string en_US
-# The values can also be preseeded individually for greater flexibility. 
 d-i debian-installer/language string en d-i debian-installer/language string en
 d-i debian-installer/country string CZ d-i debian-installer/country string CZ
-# Keyboard selection. 
 # keymap is an alias for keyboard-configuration/xkb-keymap # keymap is an alias for keyboard-configuration/xkb-keymap
 d-i keymap select us d-i keymap select us
  
 ### Network configuration ### Network configuration
-# netcfg will choose an interface that has link if possible. This makes it +# netcfg will choose an interface that has link if possible.
-# skip displaying a list if there is more than one interface.+
 d-i netcfg/choose_interface select auto d-i netcfg/choose_interface select auto
-If you have a slow dhcp server and the installer times out waiting for +In case of a slow dhcp server
-# it, this might be useful.+
 d-i netcfg/dhcp_timeout string 60 d-i netcfg/dhcp_timeout string 60
-Any hostname and domain names assigned from dhcp take precedence over +despite defined here, it must be preseeded via cmd line as well
-# values set here. Howeversetting the values still prevents the questions +
-# from being shown, even if values come from dhcp.+
 d-i netcfg/get_hostname string unassigned-hostname d-i netcfg/get_hostname string unassigned-hostname
 d-i netcfg/get_domain string unassigned-domain d-i netcfg/get_domain string unassigned-domain
-# Disable that annoying WEP key dialog.+
 d-i netcfg/wireless_wep string d-i netcfg/wireless_wep string
-If non-free firmware is needed for the network or other hardware, you can +load non-free firmware without asking
-# configure the installer to always try to load it, without prompting. Or +
-# change to false to disable asking.+
 d-i hw-detect/load_firmware boolean true d-i hw-detect/load_firmware boolean true
  
Line 86: Line 85:
 d-i mirror/protocol string http d-i mirror/protocol string http
 d-i mirror/country string cz d-i mirror/country string cz
-d-i mirror/http/hostname string debian.mirror.dkm.cz +d-i mirror/http/hostname string test-deb-01.vm.zeratul.czf
 d-i mirror/http/directory string /debian d-i mirror/http/directory string /debian
 d-i mirror/http/proxy string d-i mirror/http/proxy string
Line 98: Line 97:
  
 ### Clock and time zone setup ### Clock and time zone setup
-# Controls whether or not the hardware clock is set to UTC. 
 d-i clock-setup/utc boolean true d-i clock-setup/utc boolean true
-# You may set this to any valid setting for $TZ; see the contents of 
-# /usr/share/zoneinfo/ for valid values. 
 d-i time/zone string UTC d-i time/zone string UTC
-# Controls whether to use NTP to set the clock during the install 
 d-i clock-setup/ntp boolean true d-i clock-setup/ntp boolean true
-# NTP server to use. The default is almost always fine here. 
 d-i clock-setup/ntp-server ntp.vm.zeratul.czf d-i clock-setup/ntp-server ntp.vm.zeratul.czf
  
 ### Partitioning ### Partitioning
-## Partitioning example +this must be set in case you have more than one HDD present 
-# If the system has free space you can choose to only partition that space. +d-i partman-auto/disk string /dev/vda 
-# This is only honoured if partman-auto/method (below) is not set+possible values: regularlvmcrypto
-#d-i partman-auto/init_automatically_partition select biggest_free +
- +
-# Alternatively, you may specify a disk to partition. If the system has only +
-one disk the installer will default to using that, but otherwise the device +
-# name must be given in traditional, non-devfs format (so e.g. /dev/hda or +
-# /dev/sda, and not e.g. /dev/discs/disc0/disc). +
-# For example, to use the first SCSI/SATA hard disk: +
-#d-i partman-auto/disk string /dev/sda +
-In addition, you'll need to specify the method to use. +
-# The presently available methods are: +
-# - regular: use the usual partition types for your architecture +
-# - lvm:     use LVM to partition the disk +
-# - crypto:  use LVM within an encrypted partition+
 d-i partman-auto/method string lvm d-i partman-auto/method string lvm
-# If one of the disks that are going to be automatically partitioned +
-# contains an old LVM configuration, the user will normally receive a +
-# warning. This can be preseeded away...+
 d-i partman-lvm/device_remove_lvm boolean true d-i partman-lvm/device_remove_lvm boolean true
-# The same applies to pre-existing software RAID array: 
 d-i partman-md/device_remove_md boolean true d-i partman-md/device_remove_md boolean true
-# And the same goes for the confirmation to write the lvm partitions. 
 d-i partman-lvm/confirm boolean true d-i partman-lvm/confirm boolean true
 d-i partman-lvm/confirm_nooverwrite boolean true d-i partman-lvm/confirm_nooverwrite boolean true
-# You can choose one of the three predefined partitioning recipes: + 
-# - atomic: all files in one partition +possible values - atomichomemulti
-# - home:   separate /home partition +
-# - multi:  separate /home, /usr, /var, and /tmp partitions+
 d-i partman-auto/choose_recipe select atomic d-i partman-auto/choose_recipe select atomic
-# This makes partman automatically partition without confirmation, provided +
-# that you told it what to do using one of the methods above.+
 d-i partman-partitioning/confirm_write_new_label boolean true d-i partman-partitioning/confirm_write_new_label boolean true
 d-i partman/choose_partition select finish d-i partman/choose_partition select finish
 d-i partman/confirm boolean true d-i partman/confirm boolean true
 d-i partman/confirm_nooverwrite boolean true d-i partman/confirm_nooverwrite boolean true
-# This makes partman automatically partition without confirmation. 
 d-i partman-md/confirm boolean true d-i partman-md/confirm boolean true
 d-i partman-partitioning/confirm_write_new_label boolean true d-i partman-partitioning/confirm_write_new_label boolean true
Line 170: Line 143:
 # Avoid that last message about the install being complete. # Avoid that last message about the install being complete.
 d-i finish-install/reboot_in_progress note d-i finish-install/reboot_in_progress note
-This will prevent the installer from ejecting the CD during the reboot, +don't eject CD as there isn't any
-# which is useful in some situations.+
 d-i cdrom-detect/eject boolean false d-i cdrom-detect/eject boolean false
 # Setup SSH keys for root; the last command to be run before reboot # Setup SSH keys for root; the last command to be run before reboot
-d-i preseed/late_command string wget http://test-deb-01.vm.zeratul.czf/set-ssh-keys.sh; sh set-ssh-keys.sh;+d-i preseed/late_command string wget http://test-deb-01.vm.zeratul.czf/preseed/set-ssh-keys.sh; sh set-ssh-keys.sh;
 </code> </code>
  
Line 186: Line 158:
   APPEND initrd=img/debian64-7.1.0-wheezy-initrd.img \   APPEND initrd=img/debian64-7.1.0-wheezy-initrd.img \
     auto \     auto \
-    url=http://test-deb-01.vm.zeratul.czf/preseed.cfg \+    url=http://test-deb-01.vm.zeratul.czf/preseed/preseed.cfg \
     preseed-md5=299d7a67793464e7e1e013a79660b64e \     preseed-md5=299d7a67793464e7e1e013a79660b64e \
     fb=false \     fb=false \
Line 214: Line 186:
   * **netcfg/get_hostname**, **netcfg/get_domain** - despite set from DHCP, installer kept asking for confirmation unless defaults were passed as kernel param   * **netcfg/get_hostname**, **netcfg/get_domain** - despite set from DHCP, installer kept asking for confirmation unless defaults were passed as kernel param
  
 +Turning off Frame Buffer(''fb'') in installer is usefull when eg. ''curses'' is used instead of ''SDL'' to display VGA output. 
 +However, turning Frame Buffer off means graphics in installer will go wonky from time to time even when running in SDL window.
  
 ==== When things go wrong - unusual/additional questions asked ==== ==== When things go wrong - unusual/additional questions asked ====
linux/debian/automatic-installation.txt · Last modified: 2013/06/25 05:06 by stybla