SETTING MIKROTIK UNTUK GAME ONLINE CAMPUR BROWSING


Pada tutor kali ini saya coba uraikan settingan mikrotik untuk game online dicampur dengan kepentingan browsing (ngenet) agar berjalan serasi dan seimbang.
Note:
  • Script di bawah hanya berjalan pada mikrotik versi 3.30 ke atas.
  • Bandwidth yang diimplementasikan 512Kbps up / 1Mbps down. (1:2)

Langsung ke TKP..!!!

Code:

/interface
set 0 name=speedy ----------->(public)
set 1 name=lan ----------------> (local)


/ip address
add address=192.168.0.200/24 interface=speedy
add address=192.168.1.1/24 interface=lan


/ip route
add gateway=192.168.0.1 -------->(alamat modem ADSL)


/ip dns
set primary-dns=222.124.204.34
set secondary-dns=202.134.0.155
set allow-remote-requests=yes


/ip fi nat
add chain=srcnat action=masquerade out-interface=speedy


/ip firewall mangle \
add action=mark-connection chain=prerouting \
comment="GAME ONLINE" dst-port=\
"1818,2001,3010,4300,5105,5121,5126,5171,5340-5352,6000-6001,6000-6152,7777" \
new-connection-mark="zar-goc" passthrough=yes protocol=tcp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
disabled=no dst-port="7341-7350,7451,8085,9600,9601-9602,9300,9400,9700,93\
76-9377,10001-10011,40000" \
new-connection-mark="zar-goc" passthrough=yes protocol=tcp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
dst-port="10009,13008,16666,28012,11011-11041,10402,11031,12011,12110,13413,15000-15002,15001,15002" \
new-connection-mark="zar-goc" \
passthrough=yes protocol=tcp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
disabled=no dst-port="16402-16502,18901-18909,19000,19101,22100,27780,29000,29200,39100,39110,39220,39190,49100" \
new-connection-mark="zar-goc" passthrough=yes protocol=tcp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
dst-port=14009-14010 new-connection-mark="zar-goc" \
passthrough=yes protocol=tcp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
dst-port="1293,1479,6100-6152,7777-7977,9401,9600-9602,12020-12080,30000,40000-40010" \
new-connection-mark="zar-goc" passthrough=yes protocol=udp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
dst-port=42051-42052,11100-11125,11440-11460 \
new-connection-mark="zar-goc" passthrough=yes protocol=udp

/ip firewall mangle \
add action=mark-connection chain=prerouting \
dst-port=14009-14010 new-connection-mark="zar-goc" \
passthrough=yes protocol=udp

/ip firewall mangle \
add action=mark-packet chain=forward \
connection-mark="zar-goc" dst-address=192.168.1.0/24 \
new-packet-mark="zar-gopd" passthrough=no

/ip firewall mangle \
add action=mark-packet chain=forward \
connection-mark="zar-goc" new-packet-mark="zar-gopu" \
passthrough=no src-address=192.168.1.0/24

/ip firewall mangle \
add action=mark-connection chain=prerouting \
comment="GAME FACEBOOK" dst-port=843,9339 \
new-connection-mark="zar-gfc" passthrough=yes \
protocol=tcp

/ip firewall mangle \
add action=mark-packet chain=forward \
connection-mark="zar-gfc" disabled=no \
dst-address=192.168.1.0/24 new-packet-mark="zar-gfpd" \
passthrough=no

/ip firewall mangle \
add action=mark-packet chain=forward \
connection-mark="zar-gfc" new-packet-mark="zar-gfpu"\
passthrough=no src-address=192.168.1.0/24


/ip firewall mangle \
add action=mark-connection chain=prerouting \
comment=HTTP  dst-port=80 \
new-connection-mark="zar-hc" passthrough=yes protocol=tcp

/ip firewall mangle \
add action=mark-packet chain=forward \
connection-mark="zar-hc" disabled=no \
dst-address=192.168.1.0/24 \
new-packet-mark="zar-hpd" passthrough=no

/ip firewall mangle \
add action=mark-packet chain=forward \
connection-mark="zar-hc" disabled=no \
new-packet-mark="zar-hpu" \
passthrough=no src-address=192.168.1.0/24


/queue type \
add kind=pcq name=DOWN \
pcq-classifier=dst-address,dst-port

/queue type \
add kind=pcq name=UP \
pcq-classifier=src-address,src-port


/queue tree \
add name="2.GAME DOWN" \
parent=global-out priority=2


/queue tree \
add max-limit=2000000 \
name="3.GAME UPLOAD" \
parent=speedy priority=2


/queue tree \
add limit-at=256000 max-limit=1000000 \
name="1.GAME ONLINE DOWN" \
packet-mark="zar-gopd" \
parent="2.GAME DOWN" priority=2 queue=DOWN


/queue tree \
add max-limit=512000 \
name="2.GAME FACEBOOK DOWN" \
packet-mark="zar-gfpd" \
parent="2.GAME DOWN" priority=3 queue=DOWN


/queue tree \
add limit-at=128000 max-limit=1000000 \
name="1.GAME ONLINE UPLOAD" \
packet-mark="zar-gopu" \
parent="3.GAME UPLOAD" priority=2 queue=UP


/queue tree \
add limit-at=0 max-limit=256000 \
name="2.GAME FACEBOOK UPLOAD" \
packet-mark="zar-gfpu" \
parent="3.GAME UPLOAD" priority=3 queue=UP


/queue tree \
add max-limit=750000 \
name="1.BROWSING DOWN" \
packet-mark="zar-hpd" \
parent="5.ALL HTTP DOWN" \
priority=3 queue=DOWN


Untuk sementara streaming belum dilimit. Proses streaming bisa saja menjadikan game jadi lag. Silahkan cari sendiri script cara limit streaming seperti youtube dan live TV.

Semoga berhasil.

0 komentar:

Poskan Komentar