Mar 28, 2013

Basic Internet Sharing with Bandwidth Limiting -- Mikrotik

This tutorial explains how to configure a router to share a single Internet connection (WAN) among multiple local computers (LAN) using NAT.

First we will configure interface that is connected to WAN.

/ ip address add address=192.168.1.20/24 network=192.168.1.0 broadcast=192.168.1.255 interface=ether2

Now one interface is configured and connected to WAN (with ip 192.168.1.20/24). Now we will configure second interface for our Local Network.
/ ip address add address=192.168.0.1/24 network=192.168.0.0 broadcast=192.168.0.255 interface=ether1

Now we will configure DHCP using WinBOX, download Winbox from http://www.mikrotik.com and login to you MT Router. Then goto IP > DHCP-Server, now press Setup Button, then you will see a similar window as shown below. Just select the interface that you have configured for your Local Network (as in our example it is ether1), now just press Next till the end of setup.

Dhcp-1.JPG

Now we will configure DNS for our local network. Goto IP > DNS, press Settings button then add you Primary and Secondary DNS Server IP as provided by your Internet Service Provider. Also make sure that you select "Allow Remote Requests", so that you can give your MT Router's IP as a DNS Server to your Clients. Then Apply and OK.

Dns.JPG

Now we will configure NATing for our Local Network. Goto IP > Firewall, goto NAT table press the plus sign which will allow you to add new firewall rules. Select chain=srcnat, then set Src. Address=192.168.0.0/24 (ip range of your local network), then select Out.Interface=ether2 (interface connected WAN), as shown below.

Firewall-1.JPG

Now goto Action Tab in the same window, then select Action=Masquerade, then Apply and OK.

Firewall-2.JPG

Now we will setup Bandwidth restriction (10kbps per IP in 192.168.0.0/24 range). Goto Queues, then goto Queue Types, then press the plus sign to add a custom Queue Type. In the name field enter your desired name, select kind=pcq. As shown below.

Bandwidth-1.JPG
Now goto Settings Tab in the same window, and enter the Rate to 10000 (i.e equal to 10kbps), also select Dst. Address, as shown below.

Bandwidth-2.JPG

Now for Upload limit repeat the same procedure to create another Queue Type name it something different and in the Settings Tab instead of selecting Dst. Address this time select Src. Address. Apply and OK

Now in the Queues window goto Simple Queues Tab, and add a new simple queue by pressing plus sign. Enter your desired name, then add a Target Address=192.168.0.0/24 the IP Range of your local network.

Simple-queue-1.JPG
Now goto Advanced Tab in the same window and in Queue Type in the Target Upload select the Queue Type that we created before for upload restriction purpose, do the same for Target Download. As shown below. Press Apply and OK.

Simple-queue-2.JPG

As per the steps shown and performed, you should now have an up and running MT Router, that will serve Internet Service to local network with IP Range 192.168.0.0/24 that will be given by the DHCP Server.

22 comments:

mahasiswa kurang teladan said...

This helps me alot. Thank you very much.

mahasiswa kurang kurang teladan said...

This article is very usefull . Thanks

Jual Rukp said...

How to limit by website ? thanks.

Unknown said...
This comment has been removed by the author.
Unknown said...

How to limit speed specific ip address and range ip address?Plz help if free?

Engineer said...

Mikrotik Rb 750 ko 5210 kay sath kasy configuration krty hi any body help me

abidsaeedjutt@gmail.com
Skype abid. Saeed4

dsds said...

This blog site is pretty good! How was it made . I view something genuinely interesting about your site so I saved to my bookmarks . You can visit my site.
home network setup

buguta-penpals said...

Nice stuff - This one too works for me : Bandwidth Limiting in Mikrotik

sonaputar01 said...

Healrun is a health news blog we provide the latest news about health, Drugs and latest Diseases and conditions. We update our users with health tips and health products reviews. If you want to know any information about health or health product (Side Effects & Benefits) Feel Free To ask HealRun Support Team.

Unknown said...

Supplements For Fitness often caused by weight gain, which will allow you to increase physical activity. Increasing exercise is one of the best things you can do to lose weight and keep it healthy. All this is offered through 100% natural

asfasfsa said...

Pilpedia is supplying 100 percent original and accurate information at each moment of time around our site and merchandise, and the intent is to improve the usage of good and pure health supplement. For More Info please visit Pilpedia online store.

Dexter Johnson said...

Abundance Manifestor Guide is an online program aimed at those who want to change their lives. It is one of the latest guides that revolves around the law of attraction

Anonymous said...

FON PERDE MODELLERİ
Mobil onay
mobil ödeme bozdurma
nft nasıl alınır
Ankara evden eve nakliyat
trafik sigortası
dedektör
web sitesi kurma
ask kitaplari

sportsbet said...

Good content. You write beautiful things.
hacklink
mrbahis
korsan taksi
sportsbet
taksi
hacklink
mrbahis
vbet
vbet

batu said...

kağıthane
muğla
tuzla
etiler
maltepe

SLNP61

Simge said...

düzce
sakarya
tunceli
van
bayburt
KXK

SolarDreamerXY123456 said...

ankara parça eşya taşıma
takipçi satın al
antalya rent a car
antalya rent a car
ankara parça eşya taşıma
FF7H

89CE0DonaldF50AA said...

F0F52
Burdur Şehirler Arası Nakliyat
Burdur Lojistik
Çankırı Şehirler Arası Nakliyat
Çerkezköy Parke Ustası
Osmaniye Evden Eve Nakliyat
Batman Evden Eve Nakliyat
Rize Evden Eve Nakliyat
Çankaya Parke Ustası
Tekirdağ Çatı Ustası

53E16AndrewA2EBB said...

1EA9A
Bartın Lojistik
Kocaeli Evden Eve Nakliyat
Osmaniye Parça Eşya Taşıma
Rize Şehirler Arası Nakliyat
Elazığ Evden Eve Nakliyat
Osmaniye Lojistik
Mexc Güvenilir mi
Iğdır Şehirler Arası Nakliyat
Çorum Evden Eve Nakliyat

F781BStanley897E1 said...

E5F1A
bartın ücretsiz sohbet uygulamaları
samsun rastgele görüntülü sohbet ücretsiz
karabük sesli sohbet sitesi
kırıkkale ücretsiz görüntülü sohbet uygulamaları
rastgele görüntülü sohbet uygulamaları
kırıkkale mobil sohbet bedava
erzurum yabancı canlı sohbet
ısparta Random Görüntülü Sohbet
maraş canlı sohbet siteleri

0FFB7Ariella3F533 said...

B270E
Coin Çıkarma
Bitcoin Kazanma
Bitcoin Madenciliği Siteleri
Coin Kazanma Siteleri
Görüntülü Sohbet
Shibanomi Coin Hangi Borsada
Twitter Retweet Satın Al
Youtube Abone Satın Al
Baby Doge Coin Hangi Borsada

77ED7Gregory7DCBA said...

7A331
Kripto Para Madenciliği Nedir
Referans Kimliği Nedir
Periscope Beğeni Satın Al
Twitter Retweet Hilesi
Binance Referans Kodu
Parasız Görüntülü Sohbet
Kwai Beğeni Satın Al
Facebook Beğeni Hilesi
Parasız Görüntülü Sohbet

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Design by Computer Tricks and Tips