User Tools

Site Tools


documentation:examples:fair_traffic_shaping_per_ip_with_ipfw-dummynet

Differences

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

Link to this comparison view

Next revision
Previous revision
documentation:examples:fair_traffic_shaping_per_ip_with_ipfw-dummynet [2016/12/09 09:12]
127.0.0.1 external edit
documentation:examples:fair_traffic_shaping_per_ip_with_ipfw-dummynet [2020/05/14 23:32]
olivier [Traffic shaper configuration]
Line 71: Line 71:
  
 <code> <code>
-sysrc hostname=R1 +sysrc hostname=R1 \ 
-sysrc gateway_enable=no +  gateway_enable=no \ 
-sysrc ipv6_gateway_enable=no +  ipv6_gateway_enable=no \ 
-sysrc ifconfig_vtnet4="DHCP" +  ifconfig_vtnet4="DHCP" \ 
-sysrc ifconfig_vtnet4_ipv6="inet6 accept_rtadv" +  ifconfig_vtnet4_ipv6="inet6 accept_rtadv" \ 
-sysrc rtsold_enable="YES"+  rtsold_enable="YES" 
 +service hostname restart
 service netif restart service netif restart
 service routing restart service routing restart
Line 86: Line 87:
  
 <code> <code>
-sysrc hostname=R2 +sysrc hostname=R2 \ 
-sysrc gateway_enable=no +   gateway_enable=no \ 
-sysrc ipv6_gateway_enable=no +   ipv6_gateway_enable=no \ 
-sysrc ifconfig_vtnet4="DHCP" +   ifconfig_vtnet4="DHCP" \ 
-sysrc ifconfig_vtnet4_ipv6="inet6 accept_rtadv" +   ifconfig_vtnet4_ipv6="inet6 accept_rtadv" \ 
-sysrc rtsold_enable="YES"+   rtsold_enable="YES" 
 +service hostname restart
 service netif restart service netif restart
 service routing restart service routing restart
Line 101: Line 103:
  
 <code> <code>
-sysrc hostname=R3 +sysrc hostname=R3 \ 
-sysrc gateway_enable=no +  gateway_enable=no \ 
-sysrc ipv6_gateway_enable=no +  ipv6_gateway_enable=no \ 
-sysrc ifconfig_vtnet4="DHCP" +  ifconfig_vtnet4="DHCP" \ 
-sysrc ifconfig_vtnet4_ipv6="inet6 accept_rtadv" +  ifconfig_vtnet4_ipv6="inet6 accept_rtadv" \ 
-sysrc rtsold_enable="YES"+  rtsold_enable="YES" 
 +service hostname restart
 service netif restart service netif restart
 service routing restart service routing restart
Line 115: Line 118:
 ==== Internet server configuration ==== ==== Internet server configuration ====
  
-It's a simple static host+It's a simple static addressed host
  
 <code> <code>
-sysrc hostname=R5 +sysrc hostname=R5 \ 
-sysrc gateway_enable=no +  gateway_enable=no \ 
-sysrc ipv6_gateway_enable=no +  ipv6_gateway_enable=no \ 
-sysrc ifconfig_vtnet3="10.0.5.5/24" +  ifconfig_vtnet3="10.0.5.5/24" \ 
-sysrc ifconfig_vtnet3_ipv6="inet6 2001:db8:5::5/64" +  ifconfig_vtnet3_ipv6="inet6 2001:db8:5::5/64" \ 
-sysrc defaultrouter="10.0.5.4" +  defaultrouter="10.0.5.4" \ 
-sysrc ipv6_defaultrouter="2001:db8:5::4"+  ipv6_defaultrouter="2001:db8:5::4" 
 +service hostname restart
 service netif restart service netif restart
 service routing restart service routing restart
Line 134: Line 138:
  
 <code> <code>
-sysrc hostname=R4 +sysrc hostname=R4 \ 
-sysrc ifconfig_vtnet4="10.0.0.4/24" +  ifconfig_vtnet4="10.0.0.4/24" \ 
-sysrc ifconfig_vtnet4_ipv6="inet6 2001:db8::4/64" +  ifconfig_vtnet4_ipv6="inet6 2001:db8::4/64" \ 
-sysrc ifconfig_vtnet3="10.0.5.4/24" +  ifconfig_vtnet3="10.0.5.4/24" \ 
-sysrc ifconfig_vtnet3_ipv6="inet6 2001:db8:5::4/64" +  ifconfig_vtnet3_ipv6="inet6 2001:db8:5::4/64" \ 
-sysrc rtadvd_enable=yes +  rtadvd_enable=yes \ 
-sysrc rtadvd_interfaces=vtnet4 +  rtadvd_interfaces=vtnet4 \ 
-sysrc dhcpd_enable=YES +  dhcpd_enable=YES \ 
-sysrc dhcpd_flags="-q" +  dhcpd_flags="-q" \ 
-sysrc dhcpd_conf="/usr/local/etc/dhcpd.conf" +  dhcpd_conf="/usr/local/etc/dhcpd.conf" \ 
-sysrc dhcpd_ifaces="vtnet4" +  dhcpd_ifaces="vtnet4" \ 
-sysrc firewall_enable=YES +  firewall_enable=YES \ 
-sysrc firewall_script="/etc/ipfw.rules"+  firewall_script="/etc/ipfw.rules"
  
 cat > /usr/local/etc/dhcpd.conf <<EOF cat > /usr/local/etc/dhcpd.conf <<EOF
Line 183: Line 187:
 # We don't want to block traffic, only shape some # We don't want to block traffic, only shape some
 ${fwcmd} add 3000 allow ip from any to any ${fwcmd} add 3000 allow ip from any to any
-EOF+'EOF'
  
 +service hostname restart
 service netif restart service netif restart
 service routing restart service routing restart
documentation/examples/fair_traffic_shaping_per_ip_with_ipfw-dummynet.txt · Last modified: 2020/05/14 23:32 by olivier