wiki:PaedmlAnpassungen
close Warning: Can't synchronize with repository "keplertools" (/srv/svn/keplertools does not appear to be a Subversion repository.). Look in the Trac log for more information.

Version 4 (modified by Rüdiger Kupper, 15 years ago) ( diff )

Link zur dhcpd.conf.kepler hinzugefügt

Hier werden die Anpassungen an der Standard-Paedml festgehalten. Bei Updates kann es vorkommen, dass die Änderungen überschrieben werden, diese müssen dann von Hand nachgebessert werden oder aber sie liegen im svn und können automatisch eingefügt werden.

Firewall-Einstellungen in /etc/init.d/linuxmuster-base

in der Funktion start_firewall nach :

      # accept ipcop
      iptables -A IN-$IFACE -s $ipcopip/32 -j ACCEPT

einfügen:

      # accept proxy
      iptables -A IN-$IFACE -s 10.32.1.251/32 -j ACCEPT

      # accept LTSP-SERVER
      #  Klassenraumserver:
      iptables -A IN-$IFACE -s 10.32.1.247/32 -j ACCEPT
      iptables -A IN-$IFACE -s 10.32.1.248/32 -j ACCEPT
      iptables -A IN-$IFACE -s 10.32.1.249/32 -j ACCEPT
      iptables -A IN-$IFACE -s 10.32.1.250/32 -j ACCEPT
      #  Server fuer Computerraum 128:
      iptables -A IN-$IFACE -s 10.32.1.246/32 -j ACCEPT
      iptables -A IN-$IFACE -s 10.32.1.245/32 -j ACCEPT
      iptables -A IN-$IFACE -s 10.32.1.244/32 -j ACCEPT

Workstationimport in /usr/share/linuxmuster/scripts/wimport.sh

Die Workstations werden beim ersten Booten mit PXE vom paedml in die Datei /etc/linuxmuster/workstations aufgenommen:

Raum;Rechner;Gruppe;MAC;IP;MASK;?;?;?;?;Imaging
r128;r128-43;schueler;00:30:05:44:2a:da;10.32.128.43;255.240.0.0;1;1;1;1;0
snilaptop;snilaptopc03;snilaptop;00:0b:5d:93:b0:35;10.32.150.23;255.240.0.0;1;1;1;1;22
r109;semkurs03;schueler;00:30:05:44:76:c9;10.32.104.12;255.240.0.0;1;1;1;1;R

Bei Imaging bedeutet:

  • 0: Workstationaccount anlegen aber nicht per Linbo berücksichtigen (Eintrag in /etc/dhcp3/dhcpd.conf.linuxmuster ohne Option pxelinux.configfile)
  • 22: Workstationaccount anlegen und per Linbo berücksichtigen (Eintrag in /etc/dhcp3/dhcpd.conf.linuxmuster mit Option pxelinux.configfile)
  • R: (Rembo) Workstationaccount anlegen und per Rembo verarbeiten (Eintrag in /etc/dhcp3/rembohosts.conf)
  • IP im Bereich 10.16.209.*: Rechner ist im Lehrernetz (Eintrag in die /etc/dhcp3/lehrerhosts.conf)

Optionen 0 und 22 sind Standard-paedml, Option R ist eingefügt und muss in /usr/share/linuxmuster/scripts/wimport.sh beim Workstationimport verarbeitet werden, nach

# check dhcp stuff
#[ -z "$DHCPDCONF" ] && exitmsg "Variable DHCPDCONF is not set!"
#if [ -e "$DHCPDCONF" ]; then
#       backup_file $DHCPDCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to backup $DHCPDCONF!"
#       rm -rf $DHCPDCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to delete $DHCPDCONF!"
#fi
#touch $DHCPDCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to create $DHCPDCONF!"

einfügen:

# Adaption fuer Rembointegration
REMBO_DHCPCONF="/etc/dhcp3/rembohosts.conf"
LEHRER_DHCPCONF="/etc/dhcp3/lehrerhosts.conf"

# Adaption DHCP-CONF f�r Rembo
[ -z "$REMBO_DHCPCONF" ] && exitmsg "Variable REMBO_DHCPCONF is not set!"
if [ -e "$REMBO_DHCPCONF" ]; then
        backup_file $REMBO_DHCPCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to backup $REMBO_DHCPCONF!"
        rm -rf $REMBO_DHCPCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to delete $REMBO_DHCPCONF!"
fi
touch $REMBO_DHCPCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to create $REMBO_DHCPCONF!"

# Adaption DHCP-CONF fuer Lehrernetz
[ -z "$LEHRER_DHCPCONF" ] && exitmsg "Variable LEHRER_DHCPCONF is not set!"
if [ -e "$LEHRER_DHCPCONF" ]; then
        backup_file $LEHRER_DHCPCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to backup $LEHRER_DHCPCONF!"
        rm -rf $LEHRER_DHCPCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to delete $LEHRER_DHCPCONF!"
fi
touch $LEHRER_DHCPCONF 2>> $TMPLOG 1>> $TMPLOG || exitmsg "Unable to create $LEHRER_DHCPCONF!"

anstelle des folgenden Textes :

		# write dhcpd.conf entry
		echo -n "  * DHCP: Writing entry for $hostname ... "
    		    echo "host $hostname {" >> $DHCPDCONF
		    echo "  hardware ethernet $mac;" >> $DHCPDCONF
		    echo "  fixed-address $ip;" >> $DHCPDCONF
		    echo "  option host-name \"$hostname\";" >> $DHCPDCONF
		    if [[ "$pxe" != "0" && "$imaging" = "linbo" ]]; then
			# assign group specific pxelinux config
			echo "  option pxelinux.configfile \"pxelinux.cfg/$hostgroup\";" >> $DHCPDCONF
		    fi
		    echo "}" >> $DHCPDCONF
		fi
		echo "Ok!"
		echo


diesen einfügen

                # Adaption für Rembo-Integration (Baumgärtner)
		# write dhcpd.conf entry
		echo -n "  * DHCP: Writing entry for $hostname ... "
		if [[ "$pxe" == "R" ]]; then
		    echo -n "(Rembo-Adaption) ... "
    		    echo "host $hostname {" >> $REMBO_DHCPCONF
		    echo "  hardware ethernet $mac;" >> $REMBO_DHCPCONF
		    echo "  fixed-address $ip;" >> $REMBO_DHCPCONF
		    echo "  option host-name \"$hostname\";" >> $REMBO_DHCPCONF
		    echo "}" >> $REMBO_DHCPCONF
		elif [[ "$ip" =~ "10.16.209.*" ]]; then
		    echo -n "(Lehrernetz) ... "
    		    echo "host $hostname {" >> $LEHRER_DHCPCONF
		    echo "  hardware ethernet $mac;" >> $LEHRER_DHCPCONF
		    echo "  fixed-address $ip;" >> $LEHRER_DHCPCONF
		    echo "  option host-name \"$hostname\";" >> $LEHRER_DHCPCONF
		    echo "}" >> $LEHRER_DHCPCONF
		else
    		    echo "host $hostname {" >> $DHCPDCONF
		    echo "  hardware ethernet $mac;" >> $DHCPDCONF
		    echo "  fixed-address $ip;" >> $DHCPDCONF
		    echo "  option host-name \"$hostname\";" >> $DHCPDCONF
		    if [[ "$pxe" != "0" && "$imaging" = "linbo" ]]; then
			# assign group specific pxelinux config
			echo "  option pxelinux.configfile \"pxelinux.cfg/$hostgroup\";" >> $DHCPDCONF
		    fi
		    echo "}" >> $DHCPDCONF
		fi
		echo "Ok!"
		echo

DHCPD-Einstellungen in /etc/dhcp3/dhcpd.conf

Nach einem Update wird eventuell die Datei /etc/dhcp3/dhcpd.conf überschrieben, folgendes ist zu ändern:

#
# 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.)
server-identifier paedml;
ddns-update-style interim;
ddns-domainname "kg-fds.de";
ddns-updates on;
ddns-ttl 7200;
deny client-updates;
ddns-rev-domainname "in-addr.arpa.";
update-static-leases true;

# option definitions common to all supported networks...
server-name "paedml.kg-fds.de";
option domain-name "kg-fds.de";
option domain-name-servers 10.32.1.1;
option netbios-name-servers 10.32.1.1;
option ntp-servers 10.32.1.1;
option routers 10.32.1.254;
option font-servers 10.32.1.1;
option subnet-mask 255.240.0.0;
option broadcast-address 10.47.255.255;
use-host-decl-names on; #rembo

default-lease-time 86400;
max-lease-time 86400;

include "/etc/bind/rndc.key";

zone kg-fds.de {
	primary 10.32.1.1;
	key rndc-key;
}

zone 10.in-addr.arpa {
	primary 10.32.1.1;
	key rndc-key;
}

# 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;

allow booting;
allow bootp;

# pxelinux options for LINBO
#option vendor-encapsulated-options 09:0f:80:00:0c:4e:65:74:77:6f:72:6b:20:62:6f:6f:74:0a:07:00:50:72:6f:6d:70:74:06:01:02:08:03:80:00:00:47:04:80:00:00:00:ff;
#option space pxelinux;
#option pxelinux.magic      code 208 = string;
#option pxelinux.configfile code 209 = string;  
#option pxelinux.pathprefix code 210 = text;  
#option pxelinux.reboottime code 211 = unsigned integer 32;			
#site-option-space "pxelinux";
#option pxelinux.magic f1:00:74:7e;
#if exists dhcp-parameter-request-list {
#    # Always send the PXELINUX options (specified in hexadecimal)
#    option dhcp-parameter-request-list = concat(option dhcp-parameter-request-list,d0,d1,d2,d3);
#}
#option configfile code 150 = string;
#filename "pxelinux.0";

#next-server 10.32.1.1;

# subnet for workstation import
#subnet 10.32.0.0 netmask 255.240.0.0 {
#	range 10.32.1.100 10.32.1.200;
#        option router 10.32.1.251;
#	option ;
#	max-lease-time 3600;
#	default-lease-time 3600;
#	option host-name "pxeclient";
#}

# dynamic part of dhcpd.conf is included
include "/etc/dhcp3/dhcpd.conf.linuxmuster";


# Kepler-specific part of dhcpd.conf is included
include "/etc/dhcp3/dhcpd.conf.kepler";

Der ganze obere LINBO-Bereich muss auskommentiert werden, eigentlich wird nur noch die Kepler-angepasste Config geladen. (source:keplertools/etc/trunk/dhcp3/dhcpd.conf.kepler)

Note: See TracWiki for help on using the wiki.