ISPは一つしかないから、
PPPoEクライアントのテストが出来ない!
いえRouterboardならいくらでも出来てしまいます!!
NAT周りや、Routeを別途作って、
もっと上位に接続するようにしても面白いと思いますw
さて、作ってみましょう。
PPPoEクライアントが接続してくる物理ポートのブリッジを設定
/interface bridge add name=PPPOE-server
「ether1」を
PPPoEクライアントが使うポートとして設定します。
「ether1-gateway」を使います。
/interface pppoe-client add add-default-route=yes disabled=no interface=ether1-gateway keepalive-timeout=disabled name=pppoe-out1 password=1234567890 user=pppoe
PPPoEクライアントとPPPoEサーバに配布するIPアドレス範囲、
DHCPプール「PPPOE-pool」の設定。
/ip pool add name=default-dhcp ranges=192.168.88.10-192.168.88.254 add name=PPPOE-pool ranges=10.10.10.2-10.10.10.100
これは、初期設定です。
「bridge-local」に接続してきたクライアントに配布するアドレス範囲。
/ip dhcp-server add address-pool=default-dhcp disabled=no interface=bridge-local name=default
PPPoEサーバの設定。
「local-address」と「remote-address」に
DHCPプール「PPPOE-pool」を指定しています。
/ppp profile add bridge=PPPOE-server dns-server=8.8.8.8,8.8.4.4 local-address=PPPOE-pool name=pppoe remote-address=PPPOE-pool
各物理ポートがどのブリッジに参加しているか。
ブリッジ名「PPPOE-server」に「ether6~ether10」が参加しています。
ether6~ether10へPPPoEクライアントが接続してくることになります。
/interface bridge port add bridge=bridge-local interface=ether2 add bridge=bridge-local interface=ether3 add bridge=bridge-local interface=ether4 add bridge=bridge-local interface=ether5 add bridge=PPPOE-server interface=ether6 add bridge=bridge-local interface=sfp1 add bridge=PPPOE-server interface=ether7 add bridge=PPPOE-server interface=ether8 add bridge=PPPOE-server interface=ether9 add bridge=PPPOE-server interface=ether10
PPPoEサーバが使う「プロファイル」の設定。
/ppp profile add bridge=PPPOE-bridge dns-server=8.8.8.8,8.8.4.4 local-address=PPPOE name=PPPOE-prof remote-address=PPPOE
PPPoEサーバで使用する「プロファイル」などを指定します。
/interface pppoe-server server add default-profile=PPPOE-prof disabled=no interface=PPPOE-bridge keepalive-timeout=30 max-mru=1480 max-mtu=1480 service-name=service1
初期設定です。
「bridge-local」へ与えられてるIPアドレスです。
通常は、「192.168.88.1/24」
/ip address add address=192.168.88.1/24 comment="default configuration" interface=bridge-local network=192.168.88.0
PPPoEクライアントのアカウントを作ります。
/ppp secret add name=pppoe-user password=1234567890 profile=pppoe service=pppoe
ユーザ名・・・pppoe-user
パスワード・・・1234567890
これで物理ポート「ether1」とブリッジ名「PPPOE-server」のポート「ether6~ether10」を繋げてみましょう。
シェルなどからみると。。。
[admin@MikroTik] > ppp active print Flags: R - radius # NAME SERVICE CALLER-ID ADDRESS UPTIME ENCODING 0 pppoe pppoe D4:CA:6D:A1:71:07 10.10.10.99 3m14s
繋がってみるのが見えると思います。