Update to r44134:
- Clarify the procedure for setting up the PXE environment - Comment out some sections which probably no longer apply. Submitted by: Bjoern Heidotting Obtained from: The FreeBSD German Documentation Project
This commit is contained in:
parent
2e7186064b
commit
5d6c63cece
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=45396
1 changed files with 84 additions and 83 deletions
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
$FreeBSD$
|
$FreeBSD$
|
||||||
$FreeBSDde:$
|
$FreeBSDde:$
|
||||||
basiert auf: r44132
|
basiert auf: r44134
|
||||||
-->
|
-->
|
||||||
<chapter xmlns="http://docbook.org/ns/docbook"
|
<chapter xmlns="http://docbook.org/ns/docbook"
|
||||||
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0"
|
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0"
|
||||||
|
@ -4286,8 +4286,8 @@ DHCP"</programlisting>
|
||||||
|
|
||||||
<sect2 xml:id="network-pxe-nfs">
|
<sect2 xml:id="network-pxe-nfs">
|
||||||
<info>
|
<info>
|
||||||
<title>Einrichtung einer &man.chroot.8;-Umgebung für das
|
<title>Konfiguration der
|
||||||
<acronym>NFS</acronym>-Root-Dateisystem</title>
|
<acronym>PXE</acronym>-Umgebung</title>
|
||||||
|
|
||||||
<authorgroup>
|
<authorgroup>
|
||||||
<author>
|
<author>
|
||||||
|
@ -4303,64 +4303,84 @@ DHCP"</programlisting>
|
||||||
</authorgroup>
|
</authorgroup>
|
||||||
</info>
|
</info>
|
||||||
|
|
||||||
|
<para>Die in diesem Abschnitt dargestellten Schritte
|
||||||
|
konfigurieren die in &os; enthaltenen <acronym>NFS</acronym>-
|
||||||
|
und <acronym>TFTP</acronym>-Server. Der folgende Abschnitt
|
||||||
|
beschreibt die Installation und Konfiguration des
|
||||||
|
<acronym>DHCP</acronym>-Servers. In diesem Beispiel verwenden
|
||||||
|
wir <filename>/b/tftpboot/FreeBSD/install</filename>, welches
|
||||||
|
die Dateien für <acronym>PXE</acronym>-Benutzer enthält. Es
|
||||||
|
ist wichtig, dass dieses Verzeichnis existiert und das der
|
||||||
|
gleiche Verzeichnisname ebenfalls in
|
||||||
|
<filename>/etc/inetd.conf</filename> und
|
||||||
|
<filename>/usr/local/etc/dhcpd.conf</filename> gesetzt
|
||||||
|
wird.</para>
|
||||||
|
|
||||||
<procedure>
|
<procedure>
|
||||||
<step>
|
<step>
|
||||||
<para>Wählen Sie ein Verzeichnis welches eine
|
<para>Erstellen Sie das Root-Verzeichnis, welches eine
|
||||||
&os;-Installation enthält und über NFS eingehangen
|
&os;-Installation enthält und über NFS eingehangen
|
||||||
werden kann. Als Beispiel kann das Verzeichnis
|
werden kann.</para>
|
||||||
<filename>/b/tftpboot/FreeBSD/install</filename>
|
|
||||||
verwendet werden.</para>
|
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>export NFSROOTDIR=/b/tftpboot/FreeBSD/install</userinput>
|
<screen>&prompt.root; <userinput>export NFSROOTDIR=/b/tftpboot/FreeBSD/install</userinput>
|
||||||
&prompt.root; <userinput>mkdir -p ${NFSROOTDIR}</userinput></screen>
|
&prompt.root; <userinput>mkdir -p ${NFSROOTDIR}</userinput></screen>
|
||||||
|
|
||||||
<para>Sie können <filename>tftpboot</filename> an einer
|
|
||||||
beliebigen Stelle auf dem Server plazieren. Stellen Sie
|
|
||||||
aber sicher, dass Sie diesen Ort sowohl in
|
|
||||||
<filename>/etc/inetd.conf</filename> als auch in
|
|
||||||
<filename>/usr/local/etc/dhcpd.conf</filename> eingetragen
|
|
||||||
haben.</para>
|
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Aktivieren Sie den NFS-Server. Diese Prozedur wird
|
<para>Aktivieren Sie den NFS-Server, indem Sie folgende
|
||||||
im Kapitel <xref linkend="network-configuring-nfs"/>
|
Zeile in <filename>/etc/rc.conf</filename>
|
||||||
beschrieben.</para>
|
hinzufügen:</para>
|
||||||
|
|
||||||
<para>Exportieren Sie das eben erstellte Verzeichnis über
|
<programlisting>nfs_server_enable="YES"</programlisting>
|
||||||
NFS, indem Sie folgende Zeile in
|
|
||||||
<filename>/etc/exports</filename> hinzufügen:</para>
|
<para>Exportieren Sie das Root-Verzeichnis über NFS, indem
|
||||||
|
Sie folgende Zeile in <filename>/etc/exports</filename>
|
||||||
|
hinzufügen:</para>
|
||||||
|
|
||||||
<programlisting>/b -ro -alldirs</programlisting>
|
<programlisting>/b -ro -alldirs</programlisting>
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Starten Sie den NFS-Server neu:</para>
|
<para>Starten Sie den <acronym>NFS</acronym>-Server:</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>/etc/rc.d/nfsd restart</userinput></screen>
|
<screen>&prompt.root; <userinput>service nfsd start</userinput></screen>
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Aktivieren Sie &man.inetd.8; wie im Kapitel <xref
|
<para>Aktivieren Sie &man.inetd.8;, indem Sie folgende Zeile
|
||||||
linkend="network-inetd-settings"/> beschrieben.</para>
|
in <filename>/etc/rc.conf</filename> hinzufügen:</para>
|
||||||
|
|
||||||
|
<programlisting>inetd_enable="YES"</programlisting>
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Fügen Sie folgende Zeilen in
|
<para>Kommentieren Sie die folgende Zeile in
|
||||||
<filename>/etc/inetd.conf</filename> hinzu:</para>
|
<filename>/etc/inetd.conf</filename> aus, indem Sie
|
||||||
|
sicherstellen, dass die Zeile nicht mit einem
|
||||||
|
<literal>#</literal>-Zeichen beginnt:</para>
|
||||||
|
|
||||||
<programlisting>tftp dgram udp wait root /usr/libexec/tftp tftp -l -s /b/tftpboot</programlisting>
|
<programlisting>tftp dgram udp wait root /usr/libexec/tftp tftp -l -s /b/tftpboot</programlisting>
|
||||||
|
|
||||||
|
<note>
|
||||||
|
<para>Einige <acronym>PXE</acronym>-Versionen benötigen
|
||||||
|
die <acronym>TCP</acronym>-Version von
|
||||||
|
<acronym>TFTP</acronym>. In diesem Fall können Sie
|
||||||
|
die zweite <literal>tftp</literal>-Zeile, welche
|
||||||
|
<literal>stream tcp</literal> enthält,
|
||||||
|
auskommentieren.</para>
|
||||||
|
</note>
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Starten Sie inetd neu:</para>
|
<para>Starten Sie &man.inetd.8;:</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>/etc/rc.d/inetd restart</userinput></screen>
|
<screen>&prompt.root; <userinput>service inetd start</userinput></screen>
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para><link linkend="makeworld">Erstellen Sie einen neues
|
<para>Erstellen Sie einen neues Basissystem und einen
|
||||||
Basissystem und einen &os;-Kernel</link>:</para>
|
&os;-Kernel (detaillierte Anweisungen hierzu finden Sie
|
||||||
|
unter <xref linkend="makeworld"/>):</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>cd /usr/src</userinput>
|
<screen>&prompt.root; <userinput>cd /usr/src</userinput>
|
||||||
&prompt.root; <userinput>make buildworld</userinput>
|
&prompt.root; <userinput>make buildworld</userinput>
|
||||||
|
@ -4399,7 +4419,7 @@ Received 264951 bytes in 0.1 seconds
|
||||||
|
|
||||||
<programlisting>
|
<programlisting>
|
||||||
# Device Mountpoint FSType Options Dump Pass
|
# Device Mountpoint FSType Options Dump Pass
|
||||||
myhost.example.com:/b/tftpboot/FreeBSD/install / nfs ro 0 0
|
<replaceable>myhost.example.com</replaceable>:/b/tftpboot/FreeBSD/install / nfs ro 0 0
|
||||||
</programlisting>
|
</programlisting>
|
||||||
|
|
||||||
<para>Ersetzen Sie
|
<para>Ersetzen Sie
|
||||||
|
@ -4413,44 +4433,54 @@ myhost.example.com:/b/tftpboot/FreeBSD/install / nfs ro
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Setzen Sie das root-Passwort in der
|
<para>Setzen Sie das root-Passwort in der
|
||||||
&man.chroot.8;-Umgebung:</para>
|
<acronym>PXE</acronym>-Umgebung für Client-Maschinen, die
|
||||||
|
über <acronym>PXE</acronym> starten:</para>
|
||||||
|
|
||||||
<screen>&prompt.root; <userinput>chroot ${NFSROOTDIR} </userinput>
|
<screen>&prompt.root; <userinput>chroot ${NFSROOTDIR} </userinput>
|
||||||
&prompt.root; <userinput>passwd</userinput></screen>
|
&prompt.root; <userinput>passwd</userinput></screen>
|
||||||
|
|
||||||
<para>Damit setzen Sie das root-Passwort für die
|
|
||||||
Client-Maschinen, welche über <acronym>PXE</acronym>
|
|
||||||
starten.</para>
|
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Aktivieren Sie &man.ssh.1; root-Logins für
|
<para>Falls erforderlich, aktivieren Sie &man.ssh.1;
|
||||||
Client-Maschinen, die über <acronym>PXE</acronym>
|
root-Logins für Client-Maschinen, die über
|
||||||
starten, indem Sie die Option
|
<acronym>PXE</acronym> starten, indem Sie die
|
||||||
<literal>PermitRootLogin</literal> in
|
Option <literal>PermitRootLogin</literal> in
|
||||||
<filename>${NFSROOTDIR}/etc/ssh/sshd_config</filename>
|
<filename>${NFSROOTDIR}/etc/ssh/sshd_config</filename>
|
||||||
aktivieren. Dies ist in &man.sshd.config.5;
|
aktivieren. Dies ist in &man.sshd.config.5;
|
||||||
dokumentiert.</para>
|
dokumentiert.</para>
|
||||||
</step>
|
</step>
|
||||||
|
|
||||||
<step>
|
<step>
|
||||||
<para>Führen Sie weitere Anpassungen der
|
<para>Führen Sie alle weiteren Anpassungen der
|
||||||
&man.chroot.8;-Umgebung in ${NFSROOTDIR} durch, wie zum
|
<acronym>PXE</acronym>-Umgebung in ${NFSROOTDIR} durch,
|
||||||
Beispiel die Installation weiterer Pakete mittels
|
wie zum Beispiel die Installation weiterer Pakete, oder
|
||||||
&man.pkg.add.1;, dass Bearbeiten der Passwortdatei mit
|
dass Bearbeiten der Passwortdatei mit &man.vipw.8;.</para>
|
||||||
&man.vipw.8;, oder &man.amd.conf.5; für den Automounter.
|
|
||||||
Ein Beispiel:</para>
|
|
||||||
|
|
||||||
<screen>
|
|
||||||
&prompt.root; <userinput>chroot ${NFSROOTDIR}</userinput>
|
|
||||||
&prompt.root; <userinput>pkg_add -r bash</userinput></screen>
|
|
||||||
</step>
|
</step>
|
||||||
</procedure>
|
</procedure>
|
||||||
|
|
||||||
|
<para>Booten Sie von einem <acronym>NFS</acronym>-Root-Volume,
|
||||||
|
so erkennt <filename>/etc/rc</filename> dies und startet
|
||||||
|
daraufhin das <filename>/etc/rc.initdiskless</filename>
|
||||||
|
Skript. Lesen Sie die Kommentare in diesem Skript um zu
|
||||||
|
verstehen, was dort vor sich geht. Weil das
|
||||||
|
<acronym>NFS</acronym>-Root-Verzeichnis schreibgeschützt ist,
|
||||||
|
wir aber Schreibzugriff für <filename>/etc</filename> und
|
||||||
|
<filename>/var</filename> benötigen, müssen wir diese
|
||||||
|
Verzeichnisse über Speicher-Dateisysteme (memory backed file
|
||||||
|
system) einbinden.</para>
|
||||||
|
|
||||||
|
<screen>
|
||||||
|
&prompt.root; <userinput>chroot ${NFSROOTDIR}</userinput>
|
||||||
|
&prompt.root; <userinput>mkdir -p conf/base</userinput>
|
||||||
|
&prompt.root; <userinput>tar -c -v -f conf/base/etc.cpio.gz --format cpio
|
||||||
|
--gzip etc</userinput>
|
||||||
|
&prompt.root; <userinput>tar -c -v -f conf/base/var.cpio.gz --format cpio
|
||||||
|
--gzip var</userinput></screen>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
|
||||||
<sect2 xml:id="network-pxe-setting-up-dhcp">
|
<sect2 xml:id="network-pxe-setting-up-dhcp">
|
||||||
<title>Konfiguration des
|
<title>Konfiguration des
|
||||||
<application>ISC DHCP</application>-Servers</title>
|
<acronym>DHCP</acronym>-Servers</title>
|
||||||
|
|
||||||
<indexterm>
|
<indexterm>
|
||||||
<primary>DHCP</primary>
|
<primary>DHCP</primary>
|
||||||
|
@ -4644,7 +4674,8 @@ margaux:ha=0123456789ab:tc=.def100</programlisting>
|
||||||
<replaceable>devicetype</replaceable> zu bestimmen.</para>
|
<replaceable>devicetype</replaceable> zu bestimmen.</para>
|
||||||
</sect2>
|
</sect2>
|
||||||
-->
|
-->
|
||||||
|
<!--
|
||||||
|
Are these sections still needed?
|
||||||
<sect2>
|
<sect2>
|
||||||
<title>Vorbereitung des Root-Dateisystems</title>
|
<title>Vorbereitung des Root-Dateisystems</title>
|
||||||
|
|
||||||
|
@ -4773,37 +4804,7 @@ cd /usr/src/etc; make distribution</programlisting>
|
||||||
auf einem &os;-Rechner einzuhängen und die
|
auf einem &os;-Rechner einzuhängen und die
|
||||||
Gerätedateien dort mit &man.devfs.5; zu erzeugen.</para>
|
Gerätedateien dort mit &man.devfs.5; zu erzeugen.</para>
|
||||||
</sect2>
|
</sect2>
|
||||||
|
-->
|
||||||
<sect2>
|
|
||||||
<title>Speicher-Dateisysteme für
|
|
||||||
<filename>/etc/rc.initdiskless</filename></title>
|
|
||||||
|
|
||||||
<para>Booten Sie von einem <acronym>NFS</acronym>-Root-Volume,
|
|
||||||
so erkennt <filename>/etc/rc</filename> dies und startet
|
|
||||||
daraufhin das <filename>/etc/rc.initdiskless</filename>
|
|
||||||
Skript. Lesen Sie die Kommentare in diesem Skript um zu
|
|
||||||
verstehen, was dort vor sich geht. Weil das
|
|
||||||
<acronym>NFS</acronym>-Root-Verzeichnis schreibgeschützt ist,
|
|
||||||
wir aber Schreibzugriff für <filename>/etc</filename> und
|
|
||||||
<filename>/var</filename> benötigen, müssen wir diese
|
|
||||||
Verzeichnisse über Speicher-Dateisysteme (memory backed file
|
|
||||||
system) einbinden.</para>
|
|
||||||
|
|
||||||
<screen>
|
|
||||||
&prompt.root; <userinput>chroot ${NFSROOTDIR}</userinput>
|
|
||||||
&prompt.root; <userinput>mkdir -p conf/base</userinput>
|
|
||||||
&prompt.root; <userinput>tar -c -v -f conf/base/etc.cpio.gz --format cpio
|
|
||||||
--gzip etc</userinput>
|
|
||||||
&prompt.root; <userinput>tar -c -v -f conf/base/var.cpio.gz --format cpio
|
|
||||||
--gzip var</userinput></screen>
|
|
||||||
|
|
||||||
<para>Bei Starten werden die Speicher-Dateisysteme für
|
|
||||||
<filename>/etc</filename> und <filename>/var</filename>
|
|
||||||
erstellt und eingehangen und der Inhalt der
|
|
||||||
<filename>cpio.gz</filename>-Dateien in diese hinein
|
|
||||||
kopiert.</para>
|
|
||||||
</sect2>
|
|
||||||
|
|
||||||
<sect2>
|
<sect2>
|
||||||
<title>Konfiguration des <acronym>PXE</acronym>-Clients und
|
<title>Konfiguration des <acronym>PXE</acronym>-Clients und
|
||||||
Fehlersuche bei Verbindungsproblemen</title>
|
Fehlersuche bei Verbindungsproblemen</title>
|
||||||
|
|
Loading…
Reference in a new issue