How to Connect your Home Network to xDSL Line

From MikroTik Wiki
Revision as of 18:21, 18 December 2005 by Rieks (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

You have your Home DSL modem installed, and want to have a secure connection to the Internet for your home network. For that, you have to install MikroTik router between the DSL modem and your home network:

Follow the steps below to connect your home network to xDSL line:

  • Make your MikroTik router with two Ethernet NICs, one for the Home DSL modem, one for your home network. See instructions in the Basic Setup Guide!
  • When installing, make sure you install the dhcp software package, if your xDSL service provider uses DHCP to hand out IP configuration.
  • Make sure both interfaces are enabled, for example:
/interface enable ether1,ether2
  • Add DHCP client on the external (xDSL) interface to receive IP configuration form your service provider:
/ip dhcp-client add interface=ether1 disabled=no
  • Check, if you have received IP configuration using print detail, for example:
[admin@MikroTik] ip dhcp-client> print detail     
Flags: X - disabled, I - invalid 
 0   interface=eth1-adsl add-default-route=yes use-peer-dns=yes 
     use-peer-ntp=yes status=bound address=81.198.55.240/22 
     gateway=81.198.52.1 dhcp-server=81.198.232.1 primary-dns=80.232.169.11 
     secondary-dns=195.122.1.59 expires-after=5h5m46s 
  • Add your private network address to ether2 interface, for example:
/ip address add address=192.168.0.1/24 interface=ether2
  • Configure masquerading for your local network:
/ip firewall nat add chain=srcnat src-address=192.168.0.0/24 action=masquerade
  • Configure firewall to protect your router:
/
  • (Optional) Run DHCP Setup to configure DHCP server to hand out IP configuration on your home network:
/ip dhcp-server setup