pf-tools/pf-tools: changing some specs

parmelan-guest at users.alioth.debian.org parmelan-guest at users.alioth.debian.org
Thu Jan 8 15:51:14 UTC 2015


details:   http://hg.debian.org/hg/pf-tools/pf-tools/rev/e0afe1b19839
changeset: 1431:e0afe1b19839
user:      shad
date:      Thu Jan 08 16:51:11 2015 +0100
description:
changing some specs

diffstat:

 doc/hostfile-links-sample    |   80 +++++++++++-----
 doc/hostfile-syntax          |   24 +++-
 doc/network-interface.sample |   46 +++++++++
 doc/networkfile-syntax       |   18 ++-
 doc/networkfile.sample       |  199 +++++++++++++++++++++++++++---------------
 5 files changed, 253 insertions(+), 114 deletions(-)

diffs (440 lines):

diff -r 9165397efbba -r e0afe1b19839 doc/hostfile-links-sample
--- a/doc/hostfile-links-sample	Thu Jan 08 16:14:40 2015 +0100
+++ b/doc/hostfile-links-sample	Thu Jan 08 16:51:11 2015 +0100
@@ -1,40 +1,68 @@
-[link::vlan-systeme]
-	type.default	= ether
-	dev.default	= eth0
-	mac.0		= 00:00:00:00:00:00
-	vlan.default	= vlan-systeme
-	ipv4.default	= 3.0
-	ipv4.1		= 3.12
+[link::net-system]
+	dev     = eth0
+	mac.0	= 00:00:00:00:00:00
+	ip		= 3.0
+	ip.1    = 3.12
 
-[link::vlan-admindsi]
-	type.default	= ether
-	dev.default	= eth0.TAG1
-	ipv4.default	= 12
+[link::net-admindsi]
+	dev	= eth0
+	ip	= 12
+	tag	= vlan-admindsi
 
-[link::vlan-pfds-ext]
-	type.default	= bond
-	dev.default	= bond0
-	slaves.default	= eth2,eth3
-	options.default	= mode=active-backup,miimon=100
-	options.1	= mode=802.3ad,xmit_hash_policy=layer3+4,miimon=100
-	ipv4.default	= 92
+[link::net-pfds-ext]
+	dev			= bond0
+	ip			= 92
 	@route		= 224.0.0.0/4
 	@route		= default via GATEWAY
+	@option		= slaves eth0 eth1
+	@option		= bond_mode active-backup
+	@option		= bond_miimon 100
+
+[link::net-pfds-ext::1]
+	dev			= bond0
+	comment		= another IP on the same VLAN
+	ip			= link::mirrors
 	
+[link::net-pfds-ext::2]
+	dev			= eth2:1
+	comment		= IP aliasing on the same VLAN
+	ip			= 98
+	
+[link::net-pfds-ext-v6]
+	dev			= bond0
+	ip			= 1077:af68:1c24:7806
+	@route		= default via GATEWAY
+
+[link::net-serpe]
+	dev			= lo
+	ip		 	= link::vip-serpe
+
+[link::net-dhcp]
+	dev		= br0
+	method	= dhcp
+	@option	= bridge_ports eth3 eth4
+
+[zelda::net-hyrule]
+	dev			= princess0
+	method		= captive
+
 [deployment]
-	mode.default	= debian
-	arch.default	= amd64
-	distrib.default	= lenny
+	mode	= debian
+	arch	= amd64
+	distrib	= wheezy
+	preseed = standard-wheezy-preseed.tpl
 
 [hostgroup]
 	number		= 2
 	order		= 1
 
 [boot]
-	pxefilename.default	= pxelinux.0
-	kernel.default		= vmlinuz-2.6.26.5-universal-grm2.1.12
-	console.default		= default
+	pxefilename = pxelinux.0
+	pxetemplate = standard-wheezy-installer
+	initrd  = initrd.img-3.2.0-4-amd64
+	kernel  = vmlinuz-3.2.0-4-amd64
+	console = default
 
 [dns]
-	resolver.default	= vip-spawn.private,nscache.private
-	shortname.default	= vlan-systeme
+	resolver	= vip-spawn.private,nscache.private
+	shortname	= vlan-systeme
diff -r 9165397efbba -r e0afe1b19839 doc/hostfile-syntax
--- a/doc/hostfile-syntax	Thu Jan 08 16:14:40 2015 +0100
+++ b/doc/hostfile-syntax	Thu Jan 08 16:51:11 2015 +0100
@@ -1,15 +1,19 @@
-[link::<NETWORK_NAME>]
-	! type[.%HOSTNUM%]		::= ether|bond|bridge|tun|tap
+[link::<VLAN_NAME>::<NETWORK_NAME>[::LINK_NUM]]
 	! dev[.%HOSTNUM%]		::= <IFACE_NAME> || NONE if link doesn't exist for the specified %HOSTNUM%
 	! mac.%HOSTNUM%			::= <MAC_ADDR> WARNING this directive MUST BE defined for interface which is used for deployment
-	? slaves[.%HOSTNUM%]		::= comma separated list of <IFACE>, WARNING this directive is mandatory if type[.%HOSTNUM%] is defined
-					    as a bonding interface will be ignored if type[.%HOSTNUM%] is not
-	? options[.%HOSTNUM%]		::= see interfaces docs for misc options
-	! ipv4[.%HOSTNUM%]		::= <IPV4_ADDR> or offset. If default is used then act as old ipstart directive
-	? ipv6[.%HOSTNUM%]		::= <IPV6_ADDR> or offset. If default is used then act as old ipstart directive
-	? iface_opt[%HOSTNUM%]		::= <IFACE_OPT> define here iface options (ip link syntax)
+	! ip[.%HOSTNUM%]		::= <IPV4_ADDR> or offset. If default is used then act as old ipstart directive
 	? @route[.default|%HOSTNUM%]	::= <SUBNET>/<NETMASK> [via <GATEWAY>] (ip route syntax)
-	? @route6[.default|%HOSTNUM%]	::= <SUBNET>/<NETMASK> [via <GATEWAY>] (ip route syntax)
+        ? method                        ::= <STR> like dhcp, static, manual ... (default static)
+        ? allow                         ::= <STR> like auto, hotplug ... (default auto)
+        ? @mapping_rules                ::= <STR> all mapping rules as desctibes for /etc/network/interfaces
+        ? version                       ::= <STR> inet, inet6, ipx (default inet or inet6)
+        ? @pre-up                       ::= <STR> command run before bringing the interface up
+        ? @up                           ::= <STR> command run when interface is up
+        ? @postup                       ::= <STR> command after bringing the interface up
+        ? @down                         ::= <STR> command run when interface is down
+        ? @pre-down                     ::= <STR> command before taking the interface down
+        ? @post-down                    ::= <STR> command after  taking  the  interface  down
+        ? @option                       ::= <STR> command or option adding in iface section
 
 [deployment]
 	? os_type				::= redhat|debian|centos ...
@@ -29,6 +33,8 @@
 	? order		::= <INT>
 	! hostname	::= <STR>[%%__]? if the string <STR> is ended by one or more % then each percent is a digit for indexing hosts _ indicates the nodes (clustering)
 	? hosttype	::= <STR> if defined this key is used for %HOSTTYPE% instead of the derived one from hostfile name
+        ? @source[.%HOSTNUM%]           ::= <FILE_NAME> include stanzas from other files for /etc/network/interfaces
+        ? @source-directory[.%HOSTNUM%] ::= <PATH_NAME> source multiple files at once for /etc/network/interfaces
 
 [boot]
 	? pxefilename[.%HOSTNUM%]	::= <FILENAME> pxelinux.0 is used by default (generic legacy PXE boot) need to change if UEFI is used
diff -r 9165397efbba -r e0afe1b19839 doc/network-interface.sample
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/doc/network-interface.sample	Thu Jan 08 16:51:11 2015 +0100
@@ -0,0 +1,46 @@
+auto lo
+iface lo inet loopback
+
+iface lo inet static
+    address 82.0.0.1
+    netmask 255.255.255.255
+
+iface eth3 inet dhcp
+
+auto eth0
+iface eth0 inet static
+    address 10.128.3.6
+    netmask 255.255.0.0
+    network 10.128.0.0
+    dns-nameservers 10.1.1.254 10.1.167.0 10.1.167.1
+    dns-search private
+
+auto bond0
+iface bond0 inet static
+    address 93.25.78.12
+    netmask 255.255.255.0
+    network 93.25.78.0
+    gateway 93.25.78.1
+    slaves  eth2 eth3
+    bond-mode active-backup
+    bond-miimon 100
+    bond-downdelay 200
+    bond-updelay 200
+
+auto bond0
+iface bond0 inet6 static
+    address 2a02:8400:4:cb:10e7:9a22:f666:9daf
+    netmask 64
+    gateway 2a02:8400:4:cb::1
+
+auto eth0.124
+iface eth0.124 inet static
+    address 10.111.12.14
+    netmask 255.255.255.0
+    network 10.111.12.0
+    up ip r a 10.111.37.0/24 via 10.111.12.1 dev eth0.124
+    down ip r a 10.111.37.0/24 via 10.111.12.1 dev eth0.124
+
+# Bridge setup
+iface br0 inet dhcp
+    bridge_ports eth0 eth1
diff -r 9165397efbba -r e0afe1b19839 doc/networkfile-syntax
--- a/doc/networkfile-syntax	Thu Jan 08 16:14:40 2015 +0100
+++ b/doc/networkfile-syntax	Thu Jan 08 16:51:11 2015 +0100
@@ -24,17 +24,19 @@
 	! dhcpvlan	::= <NETWORK_NAME>
 	! console	::= (default|ttyS0,115200n8)
 
+[<VLAN_NAME>]
+        ! type          ::= vlan
+        ! tag           ::= <INT> 802.1q tag 
+	? comment	::= <STR>
+        ? site          ::= <STR> FIXME
+
 [<NETWORK_NAME>]
 	! type		::= network
 	? comment	::= <STR>
-	! site		::= <STR>
-	? tag		::= <INT> 802.1q tag
-	! network	::= <NETWORK> define here the network in IPv4 format in CIDR format
-	? network6	::= <NETWORK> define here the prefix in IPv6 format in CIDR format
-	! scope		::= private|public, if private is defined this network will be ONLY added on zone private for site
-	? gateway	::= <IPV4_ADDR> or offset
-# TODO
-#	? gateway6	::= <IPV6_ADDR> or offset
+	! network	::= <NETWORK> define here the network format in CIDR format
+	! scope		::= global|local, if private is defined this network will be ONLY added on zone private for site
+	? gateway	::= <IP_ADDR> or offset
+        ? network_type  ::= anycast, multicast, unicast => allow to use one IP several times
 
 [<SERVER_NAME>]
 	! type							::= server
diff -r 9165397efbba -r e0afe1b19839 doc/networkfile.sample
--- a/doc/networkfile.sample	Thu Jan 08 16:14:40 2015 +0100
+++ b/doc/networkfile.sample	Thu Jan 08 16:51:11 2015 +0100
@@ -1,88 +1,145 @@
 [cbv4-pfds]
-	type		= site
-	coment		= Root site PFDS
-	location	= Courbevoie
-	room		= 010D (ex Tele 2)
-	state		= ROOT
-	dhcpvlan	= vlan-systeme
-	console		= default
-	zone		= private
+    type		= site
+    coment		= Root site PFDS
+    location	= Courbevoie
+    room		= 010D (ex Tele 2)
+    state		= ROOT
+    dhcpvlan	= vlan-systeme
+    console		= default
+    zone		= private
 
 [cbv4]
-	type		= site
-	coment		= POP Courbevoie (CBV4)
-	location	= Courbevoie
-	room		= 010D (ex Tele 2)
-	state		= EDGE
-	console		= default
-	zone		= private
-	dhcpvlan	= vlan-systeme
+    type		= site
+    coment		= POP Courbevoie (CBV4)
+    location	= Courbevoie
+    room		= 010D (ex Tele 2)
+    state		= EDGE
+    console		= default
+    zone		= private
+    dhcpvlan	= vlan-systeme
 
 [private]
-	type		= zone
-	comment 	= Zone de gestion interne plateforme
-	serial		= AUTO
-	soa			= Deploy00.private.
-	mail		= dnsmaster at private
-	refresh		= 6H      ; Refresh (6 hours)
-	retry		= 1H      ; Retry (1 hour)
-	expire		= 7D      ; Expire (7 days)
-	negttl		= 1H      ; Negative TTL (1 hours)
-	ttl			= 1D      ; TTL (1 day)
-	@ns			= deploy00.vlan-systeme.private.
-	@ns			= deploy01.vlan-systeme.private.
-	@mx			= 1       mf.private.
-	@mx			= 2       mf00.private.
-	@mx			= 2       mf01.private.
-	console		= ttyS0,115200n8
+    type		= zone
+    comment 	= Zone de gestion interne plateforme
+    serial		= AUTO
+    soa			= Deploy00.private.
+    mail		= dnsmaster at private
+    refresh		= 6H      ; Refresh (6 hours)
+    retry		= 1H      ; Retry (1 hour)
+    expire		= 7D      ; Expire (7 days)
+    negttl		= 1H      ; Negative TTL (1 hours)
+    ttl			= 1D      ; TTL (1 day)
+    @ns			= deploy00.vlan-systeme.private.
+    @ns			= deploy01.vlan-systeme.private.
+    @mx			= 1       mf.private.
+    @mx			= 2       mf00.private.
+    @mx			= 2       mf01.private.
+    console		= ttyS0,115200n8
 
 [vip-spawn]
-	type				= server
-	site				= cbv4-pfds
-	comment				= VIP for accessing to spawn functionnality
-	order				= 2
-	number				= 1
-	ipv4.vlan-systeme	= 167.254
-	ipv4.vlan-pfds-ext	= 99
-	shortname			= vlan-systeme
-	alias.mirrors		= vlan-systeme
-	alias.cvs			= vlan-systeme
-	alias.nsprivate		= vlan-systeme
-	alias.nscache		= vlan-systeme
-	alias.mf			= vlan-systeme
-	alias.vip-deploy	= vlan-systeme
+    type				= server
+    site				= cbv4-pfds
+    comment				= VIP for accessing to spawn functionnality
+    order				= 2
+    number				= 1
+    ip.net-systeme		= 167.254
+    ip.net-pfds-ext		= 99
+    shortname			= net-systeme
+    alias.mirrors		= net-systeme
+    alias.cvs			= net-systeme
+    alias.nsprivate		= net-systeme
+    alias.nscache		= net-systeme
+    alias.mf			= net-systeme
+    alias.vip-deploy	= net-systeme
+
+[vip-serpe]
+	type			= server
+	comment			= IP Anycast pour serpe
+	site			= ALL
+	order			= 2
+	number			= 1
+	shortname		= net-serpe
+	ip.net-serpe	= 217
 
 [network-common]
-	type	= include
+    type	= include
 
+[vlan-systeme]
+    type    = vlan
+    tag     = 13
+    site    = ALL
+    
 [vlan-pfds-ext]
-	type	= network
-	site	= cbv4-pfds
-	network	= 93.20.126.0/24
-	tag		= 40
-	netmask	= 255.255.255.0
-	scope	= public
-	gateway	= 254
+    type    = vlan
+    tag	    = 40
+    site    = cbv4-pfds
+
+[vlan-serpe]
+    type    = vlan
+    tag	    = 48
+    site    = ALL
 
 [vlan-admindsi]
-	type	= network
-	site	= cbv4-pfds
-	network	= 10.111.204.0/24
-	tag		= 302
-	scope	= private
-	gateway	= 254
+    type    = vlan
+    tag	    = 302
+    site    = cbv4-pfds
 
 [vlan-middledsi]
-	type	= network
-	site	= cbv4-pfds
-	network	= 10.111.220.0/24
-	tag		= 372
-#	netmask	= /24
-	scope	= private
-	gateway = 254
+    type    = vlan
+    tag	    = 372
+    site    = cbv4-pfds
+
+[net-pfds-ext]
+    type	= network
+	comment	= IP unique
+    network	= 93.20.126.0/24
+    scope	= global
+    gateway	= 254
+
+[net-pfds-ext-v6]
+    type	= network
+	comment	= IP unique
+    network	= 2a02:8400:4:cb/64
+    scope	= global
+    gateway	= 1
+
+[net-systeme]
+    type	= network
+	comment	= IP unique sur un site donné
+    network	= 10.128.0.0/16
+    scope	= local
+    gateway	= 1
+
+[net-serpe]
+    type	= network
+	comment	= réseau anycast
+    network	= 93.21.12.216/30
+    scope	= global
+    gateway	= 217
+	routing	= anycast
+
+[net-multicast]
+    type	= network
+	comment	= réseau multicast
+    network	= 224.0.0.0/4
+    scope	= global
+    routing	= multicast
+
+[net-admindsi]
+    type	= network
+    network	= 10.111.204.0/24
+    scope	= local
+    gateway	= 254
+
+[net-middledsi]
+    type	= network
+    network	= 10.111.220.0/24
+    tag		= 372
+    scope	= private
+    gateway = 254
 
 [admins]
-	type	= service
-	comment	= Administration hosts
-	site	= cbv4-pfds
-	@host	= hostfile-cbv4-spawn
+    type	= service
+    comment	= Administration hosts
+    site	= cbv4-pfds
+    @host	= hostfile-cbv4-spawn



More information about the pf-tools-commits mailing list