modified on 24 June 2008 at 15:57 ••• 20,076 views

OSPF and PPPoE Setup

From MikroTik Wiki

Jump to: navigation, search

This is from http://forum.mikrotik.com/viewtopic.php?f=2&t=24797

Once we have the IP Addresses, Gateway, and Routing information from our service provider, we can begin by creating and configuring the OSPF area, followed by setting up the PPPoE server. In this example 10.0.108.18/28 is the routing network given to us by the provider, with the gateway 10.0.108.17. The public IP Address block we have been given is 10.0.110.0/24. Once these steps have been completed, the PPPoE username and passwords that are set up will be on the internet with an IP Address out of the 10.0.110.2-10.0.110.254 range. Our public facing network card is ether1.

IP Address Configuration

This gets your MikroTik Router out on the internet with an accessible public IP address.

/ip address add address=10.0.108.18/28 interface=ether1

OSPF Setup

This enables OSPF for the 10.0.110.0/24 network.

/routing ospf area add area-id=0.0.0.110 name=public_110
/routing ospf network add area=public_110 network=10.0.110.0/24
/routing ospf area range add area=public_110 range 10.0.110.0/24 cost=default advertise=yes

PPPoE Setup

First, create the public IP Address pool.

/ip pool add name=public_pool ranges=10.0.110.2-10.0.110.254 next-pool=none

Next we create a PPP profile, add a user, and then start the server on interface "ether2".

/ppp profile add name="public_profile" local-address=10.0.110.1 remote-address=public_pool
/ppp secret add name=user password=changeme service=pppoe profile=public_profile
/interface pppoe-server server add service-name=public_internet interface=ether2 default-profile=public_profile \
\... one-session-per-host=yes authentication=pap max-mtu=1480 max-mru=1480

Now, this MikroTik Router should be routing all PPPoE clients on your network out on to the internet with their own public IP addresses.