Auteur Sujet: Configuration Mikrotik dual stack  (Lu 1071 fois)

0 Membres et 1 Invité sur ce sujet

Kedare

  • Expert Scaleway
  • Expert
  • *
  • Messages: 70
  • Nantes (44)
Configuration Mikrotik dual stack
« le: 20 août 2019 à 12:42:38 »
Hello.

Si ca peut aider, voila un bout de ma configuration Mikrotik pour OVH Telecom en dual stack (Je tourne sur un HEX S sur du 300Mbps mais ca peut aller beaucoup plus haut je pense: https://mikrotik.com/product/hex_s )

Ici on branchera l'ONT sur ether1, et le reste sera en bridge (LAN), le LAN sera en 192.168.1.0/24, et le prefix IPv6 récuperé depuis DHCPv6-PD

/interface pppoe-client
add add-default-route=yes disabled=no interface=ether1 name=pppoe-ovh password=YOURPASSWORDHERE use-peer-dns=yes user=YOURUSERHERE@ovh.kosc

/ip pool
add name=dhcp-lan-pool ranges=192.168.1.10-192.168.1.99
/ip dhcp-server
add address-pool=dhcp-lan-pool disabled=no interface=bridge name=dhcp-lan

/ipv6 dhcp-server
add address-pool=ovh-pd interface=bridge name=bridge-dhcpv6

/interface bridge port
add bridge=bridge comment=defconf interface=ether2
add bridge=bridge comment=defconf interface=ether3
add bridge=bridge comment=defconf interface=ether4
add bridge=bridge comment=defconf interface=ether5

/ip neighbor discovery-settings
set discover-interface-list=LAN

/interface detect-internet
set detect-interface-list=WAN internet-interface-list=WAN lan-interface-list=LAN wan-interface-list=WAN

/ip address
add address=192.168.1.1/24 comment="LAN IP" interface=bridge network=192.168.1.0

/ip dhcp-server network
add address=192.168.1.0/24 dns-server=192.168.1.1 domain=home gateway=192.168.1.1 ntp-server=80.67.184.129
/ip dns
set allow-remote-requests=yes

/ip firewall filter
add action=accept chain=input comment=\
    "defconf: accept established,related,untracked" connection-state=\
    established,related,untracked
add action=drop chain=input comment="defconf: drop invalid" connection-state=invalid
add action=drop chain=input comment="Block incoming UDP from WAN" in-interface=\
    pppoe-ovh protocol=udp
add action=accept chain=input comment="Accept ICMP" protocol=icmp
add action=drop chain=input comment="Drop from WAN" in-interface-list=WAN
add action=fasttrack-connection chain=forward comment="defconf: fasttrack" \
    connection-state=established,related
add action=accept chain=forward comment=\
    "defconf: accept established,related, untracked" connection-state=\
    established,related,untracked
add action=drop chain=forward comment="defconf: drop invalid" connection-state=\
    invalid
add action=drop chain=forward comment="defconf:  drop all from WAN not DSTNATed" \
    connection-nat-state=!dstnat connection-state=new in-interface-list=WAN
/ip firewall nat
add action=masquerade chain=srcnat out-interface-list=WAN

/ip upnp
set enabled=yes
/ip upnp interfaces
add interface=pppoe-ovh type=external
add interface=bridge type=internal

/ipv6 address
add eui-64=yes from-pool=ovh-pd interface=bridge

/ipv6 dhcp-client
add add-default-route=yes interface=pppoe-ovh pool-name=ovh-pd request=prefix

/ipv6 firewall filter
add action=accept chain=input comment="Allow established connections" \
    connection-state=established
add action=accept chain=input comment="Allow related connections" connection-state=\
    related
add action=accept chain=input comment="Allow ICMP" protocol=icmpv6
add action=reject chain=input comment="Reject invalid packets" connection-state=\
    invalid
add action=accept chain=forward comment="Allow established connections" \
    connection-state=established
add action=accept chain=forward comment="Allow related connections" \
    connection-state=related
add action=accept chain=forward comment="Allow ICMP" protocol=icmpv6
add action=reject chain=forward comment="Reject invalid packets" connection-state=\
    invalid
add action=accept chain=forward comment="Allow any to internet" out-interface=\
    pppoe-ovh
add action=reject chain=forward comment="Reject TCP connections by default" \
    protocol=tcp reject-with=tcp-reset
add action=reject chain=forward comment="Reject other protocols by default" log=yes \
    reject-with=icmp-admin-prohibited

/ipv6 nd
set [ find default=yes ] disabled=yes
add advertise-dns=yes hop-limit=64 interface=bridge managed-address-configuration=\
    yes other-configuration=yes

/system leds
set 0 interface=pppoe-ovh type=interface-status

/system ntp client
set enabled=yes primary-ntp=80.67.184.129 secondary-ntp=193.54.76.41

Voila normalement il y a tout :)
« Modifié: 23 mars 2020 à 11:02:19 par Kedare »

kaktuss77

  • Client Orange Fibre
  • *
  • Messages: 563
  • Free 8G/700M + Orange 2G/600M <3
    • @kaktuss77
Configuration Mikrotik dual stack
« Réponse #1 le: 21 août 2019 à 15:20:21 »
Hello,

Merci pour ton partage,

Avec mon CRS309 (oui j'sais c'est un switch  ::) ) je fais 400Mbps en NAT et 1Gbps en routage pur (gestion PPPoE par le CRS309 dans les 2 cas)