Installazione debian senza clic

Da sia.
Vai alla navigazione Vai alla ricerca

Boot da rete

Servizi necessari

  • dhcp3-server
  • tftpd-hpa (questa versione, non un'altra)
  • server web (?)

Il servizio tftp gira su porta UDP. Se si usano le iptables, bisogna aprire la porta corrispondente.

Dubbi

Differenze bootp/tftp?

Bisogna registrare l'host nel dhcpd? Potrebbe bastare modificare le options del maintain?

Esempi

File /etc/dhcp3/dhcp3.conf

#
# Sample configuration file for ISC dhcpd for Debian
#
# $Id: dhcpd.conf,v 1.1.1.1 2002/05/21 00:07:44 peloy Exp $
#

# The ddns-updates-style parameter controls whether or not the server will
# attempt to do a DNS update when a lease is confirmed. We default to the
# behavior of the version 2 packages ('none', since DHCP v2 didn't
# have support for DDNS.)
ddns-update-style none;

# option definitions common to all supported networks...
option domain-name "unimo.it";
option domain-name-servers 155.185.1.2;
allow bootp;
allow booting;

default-lease-time 600;
max-lease-time 7200;

# If this DHCP server is the official DHCP server for the local
# network, the authoritative directive should be uncommented.
#authoritative;

# Use this to send dhcp log messages to a different log file (you also
# have to hack syslog.conf to complete the redirection).
log-facility local7;

# No service will be given on this subnet, but declaring it helps the
# DHCP server to understand the network topology.

subnet 155.185.1.0 netmask 255.255.255.0 {
  next-server mirror.unimore.it;
  filename "/pxelinux.0";
  option routers 155.185.1.254;
}

host install2 {
  hardware ethernet 00:01:02:19:5b:e4;
  fixed-address 155.185.1.54;
}

host install1 {
  hardware ethernet 00:13:21:62:3c:f1;
  fixed-address 155.185.1.54;
}

host install {
  hardware ethernet 00:01:02:19:3A:F6;
  fixed-address 155.185.1.54;
}

Riferimenti

Avvio tftp da rete

preseed.cfg

Esempi

File /var/lib/tftpboot/pxelinux.cfg/default per passare alcuni parametri:

 DISPLAY debian-installer/i386/boot-screens/boot.txt

 F1 debian-installer/i386/boot-screens/f1.txt
 F2 debian-installer/i386/boot-screens/f2.txt
 F3 debian-installer/i386/boot-screens/f3.txt
 F4 debian-installer/i386/boot-screens/f4.txt
 F5 debian-installer/i386/boot-screens/f5.txt
 F6 debian-installer/i386/boot-screens/f6.txt
 F7 debian-installer/i386/boot-screens/f7.txt
 F8 debian-installer/i386/boot-screens/f8.txt
 F9 debian-installer/i386/boot-screens/f9.txt
 F0 debian-installer/i386/boot-screens/f10.txt

 DEFAULT install

 LABEL install
        kernel debian-installer/i386/linux
        append auto preseed/url=http://155.185.1.55/d-i/preseed.cfg debian-installer/locale=it_IT languagechooser/language-name=Italian countrychooser/shortlist=IT console-keymaps-at/keymap=it netcfg/get_hostname string unassigned-hostname netcfg/get_domain string unassigned-domain  time/zone=Europe/Rome  vga=normal initrd=debian-installer/i386/initrd.gz --
 LABEL linux
        kernel debian-installer/i386/linux
        append vga=normal initrd=debian-installer/i386/initrd.gz --

 LABEL expert
        kernel debian-installer/i386/linux
        append priority=low vga=normal initrd=debian-installer/i386/initrd.gz --

 LABEL rescue
        kernel debian-installer/i386/linux
        append vga=normal initrd=debian-installer/i386/initrd.gz rescue/enable=true --

 LABEL auto
        kernel debian-installer/i386/linux
        append auto=true priority=critical vga=normal initrd=debian-installer/i386/initrd.gz --

 PROMPT 1
 TIMEOUT 1

TIMEOUT fa sì che l'installer non aspetti conferma per iniziare l'installazione.

File preseed.cfg:

preseed.cfg

Referimenti

Compliazione dei file di preseed

capistrano

capistrano è un progetto in ruby per automatizzare il deployment di applicazioni rails, ma si presta molto bene ad eseguire degli script di configurazione post-installazione.

Capistrano