Langsung aja gan..
Asumsikan internetnya sudah jalan (settingan IP public, private dan NAT sudah)
saya kasih contekan biar agan bisa langsung copas ke teminal nya mikrotik kalo menggunakan IP yang nya sama..
Contohnya pake IP private 192.168.0.0/24 (ether2)
Gateway di mikrotik 192.168.0.254 (ether1)
ada 10 PC client dari IP 1 sampai 10
layanan 2Mbps
buat mangle nya dulu untuk marking koneksi dan packet dari tiap PC
client, contoh berikut IP PC client 192.168.0.1 sampai 192.168.0.10Asumsikan internetnya sudah jalan (settingan IP public, private dan NAT sudah)
saya kasih contekan biar agan bisa langsung copas ke teminal nya mikrotik kalo menggunakan IP yang nya sama..
Contohnya pake IP private 192.168.0.0/24 (ether2)
Gateway di mikrotik 192.168.0.254 (ether1)
ada 10 PC client dari IP 1 sampai 10
layanan 2Mbps
/ ip firewall mangle
add chain=forward protocol=!icmp src-address=192.168.0.1 action=mark-connection new-connection-mark=PC1-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC1-con action=mark-packet new-packet-mark=PC1 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.2 action=mark-connection new-connection-mark=PC2-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC2-con action=mark-packet new-packet-mark=PC2 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.3 action=mark-connection new-connection-mark=PC3-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC3-con action=mark-packet new-packet-mark=PC3 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.4 action=mark-connection new-connection-mark=PC4-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC4-con action=mark-packet new-packet-mark=PC4 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.5 action=mark-connection new-connection-mark=PC5-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC5-con action=mark-packet new-packet-mark=PC5 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.6 action=mark-connection new-connection-mark=PC6-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC6-con action=mark-packet new-packet-mark=PC6 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.7 action=mark-connection new-connection-mark=PC7-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC7-con action=mark-packet new-packet-mark=PC7 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.8 action=mark-connection new-connection-mark=PC8-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC8-con action=mark-packet new-packet-mark=PC8 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.9 action=mark-connection new-connection-mark=PC9-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC9-con action=mark-packet new-packet-mark=PC9 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.10 action=mark-connection new-connection-mark=PC10-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC10-con action=mark-packet new-packet-mark=PC10 passthrough=no disabled=no
/
add chain=forward protocol=!icmp src-address=192.168.0.1 action=mark-connection new-connection-mark=PC1-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC1-con action=mark-packet new-packet-mark=PC1 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.2 action=mark-connection new-connection-mark=PC2-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC2-con action=mark-packet new-packet-mark=PC2 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.3 action=mark-connection new-connection-mark=PC3-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC3-con action=mark-packet new-packet-mark=PC3 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.4 action=mark-connection new-connection-mark=PC4-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC4-con action=mark-packet new-packet-mark=PC4 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.5 action=mark-connection new-connection-mark=PC5-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC5-con action=mark-packet new-packet-mark=PC5 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.6 action=mark-connection new-connection-mark=PC6-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC6-con action=mark-packet new-packet-mark=PC6 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.7 action=mark-connection new-connection-mark=PC7-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC7-con action=mark-packet new-packet-mark=PC7 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.8 action=mark-connection new-connection-mark=PC8-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC8-con action=mark-packet new-packet-mark=PC8 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.9 action=mark-connection new-connection-mark=PC9-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC9-con action=mark-packet new-packet-mark=PC9 passthrough=no disabled=no
add chain=forward protocol=!icmp src-address=192.168.0.10 action=mark-connection new-connection-mark=PC10-con passthrough=yes disabled=no
add chain=forward protocol=!icmp connection-mark=PC10-con action=mark-packet new-packet-mark=PC10 passthrough=no disabled=no
/
Buat queue type yg PCQ nya dulu, penjelasan PCQ apa agan bisa googling 

queue type add name=Client-DL kind=pcq pcq-classifier=dst-address
queue type add name=Client-UL kind=pcq pcq-classifier=src-address
queue type add name=Client-UL kind=pcq pcq-classifier=src-address
Buat queue tree parent nya, contoh berikut adalah untuk layanan 2Mbps, di setting DL = 2Mbps dan UL = 512Kbps (untuk internet biasanya UL : DL = 1 : 4)
queue tree add name=Client-DL parent=ether2 max-limit=2048k
queue tree add name=Client-UL parent=ether1 max-limit=512k
queue tree add name=Client-UL parent=ether1 max-limit=512k
queue tree add name=PC1-DL packet-mark=PC1 parent=Client-DL
queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k
burst-time=10
queue tree add name=PC2-DL packet-mark=PC2 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC3-DL packet-mark=PC3 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC4-DL packet-mark=PC4 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC5-DL packet-mark=PC5 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC6-DL packet-mark=PC6 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC7-DL packet-mark=PC7 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC8-DL packet-mark=PC8 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC9-DL packet-mark=PC9 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC10-DL packet-mark=PC10 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC2-DL packet-mark=PC2 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC3-DL packet-mark=PC3 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC4-DL packet-mark=PC4 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC5-DL packet-mark=PC5 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC6-DL packet-mark=PC6 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC7-DL packet-mark=PC7 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC8-DL packet-mark=PC8 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC9-DL packet-mark=PC9 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
queue tree add name=PC10-DL packet-mark=PC10 parent=Client-DL queue=Client-DL limit-at=512k max-limit=1024k burst-limit=2048k burst-time=10
Buat queue tree untuk UpLink tiap PC, contoh disini dibuat dengan limit setiap PC 128Kbps dengan max limit 256Kbps dan bisa burst sampai 512Kbps jika BW kosong selama 10 detik.
queue tree add name=PC1-UL packet-mark=PC1 parent=Client-UL
queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k
burst-time=10
queue tree add name=PC2-UL packet-mark=PC2 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC3-UL packet-mark=PC3 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC4-UL packet-mark=PC4 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC5-UL packet-mark=PC5 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC6-UL packet-mark=PC6 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC7-UL packet-mark=PC7 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC8-UL packet-mark=PC8 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC9-UL packet-mark=PC9 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC10-UL packet-mark=PC10 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC2-UL packet-mark=PC2 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC3-UL packet-mark=PC3 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC4-UL packet-mark=PC4 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC5-UL packet-mark=PC5 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC6-UL packet-mark=PC6 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC7-UL packet-mark=PC7 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC8-UL packet-mark=PC8 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC9-UL packet-mark=PC9 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
queue tree add name=PC10-UL packet-mark=PC10 parent=Client-UL queue=Client-DL limit-at=128k max-limit=256k burst-limit=512k burst-time=10
Settingan angka-angka di atas baik itu IP ataupun limit BW bisa agan rubah sesuai kebutuhan..
Tidak ada komentar:
Posting Komentar