Community discussions

MikroTik App
 
michalkos
newbie
Topic Author
Posts: 49
Joined: Sun Jun 11, 2006 11:33 pm

Shaping with more connections

Sun Jun 11, 2006 11:55 pm

I have DSL line. Via this line I use this connection:
- 2x IP tunel
- L2TP connection
- PPTP connection
:o)

I need use shaping for this services (for example):
- RDP
- Http
- Smtp

I don't know, how I mark packets for this services. I need set services as independe on connection, because, all connection using DSL line.

... I need shape RDP (3389) as high priority service for L2TP, PPTP users and for IP Tunels users.

How I must set QTrees? I read more items in this forum, but I still don't set it.

Thanks
 
User avatar
Mitak
newbie
Posts: 42
Joined: Wed Jun 07, 2006 10:12 am
Location: Bulgaria
Contact:

shapers

Mon Jun 12, 2006 10:36 am

Mark HTTP packets:

/ip firewall mangle
add chain=prerouting protocol=tcp dst-port=80 action=mark-connection new-connection-mark=http passthrough=yes
add chain=prerouting connection-mark=http action=mark-packet new-packet-mark=http_p passthrough=yes

Mark SMTP packets:

add chain=prerouting protocol=tcp dst-port=25 action=mark-connection new-connection-mark=smtp passthrough=yes
add chain=prerouting connection-mark=smtp action=mark-packet new-packet-mark=smtp_p passthrough=yes

Mark RDP packets:

add chain=prerouting protocol=rdp dst-port=3389 action=mark-connection new-connection-mark=rdp passthrough=yes
add chain=prerouting connection-mark=rdp action=mark-packet new-packet-mark=rdp_p passthrough=yes


Add the queue types:

/queue type

http queue, limited to 512k:
add name="http" kind=pcq pcq-rate=512000 pcq-limit=100 pcq-classifier=dst-port pcq-total-limit=2000

smtp queue,limuted to 256k:
add name="smtp" kind=pcq pcq-rate=256000 pcq-limit=100 pcq-classifier=dst-port pcq-total-limit=2000

rdp queue, limited to 1Mbit:
add name="rdp" kind=pcq pcq-rate=1024000 pcq-limit=100 pcq-classifier=dst-port pcq-total-limit=2000

set the queue tree:

/queue tree
add name=shaper parent=DSL
add name=q_rdp parent=shaper packet-mark=rdp_p queue=rdp priority=7
add name=q_http parent=shaper packet-mark=http_p queue=http priority=8
add name q_smtp parent=shaper packet-mark=smtp_p queue smtp priority=8

where DSL is the name of your DSL out interface.
Last edited by Mitak on Mon Jun 12, 2006 10:54 am, edited 1 time in total.
 
cmit
Forum Guru
Forum Guru
Posts: 1547
Joined: Fri May 28, 2004 12:49 pm
Location: Germany

Mon Jun 12, 2006 10:41 am

The queue types names are all "http" here (copy and paste ;) ) - beware to adjust them to rdp/smtp/http respectively...

Best regards,
Christian Meis
 
User avatar
Mitak
newbie
Posts: 42
Joined: Wed Jun 07, 2006 10:12 am
Location: Bulgaria
Contact:

huh

Mon Jun 12, 2006 10:55 am

10x, it`s fixed :)
 
michalkos
newbie
Topic Author
Posts: 49
Joined: Sun Jun 11, 2006 11:33 pm

:o)

Wed Jun 14, 2006 11:00 pm

:o)

OK It's work, but I have second problem with this solution :shock:

I use (shaping) FTP ->
1. client from LAN to WAN a need limit 1500Kbs
2. client from WAN to LAN a need limit 512Kbs

=> DLS line type

Thanks for help.
 
User avatar
samsoft08
Long time Member
Long time Member
Posts: 613
Joined: Sat Nov 26, 2005 10:52 pm

Wed Jun 14, 2006 11:32 pm

in the manual and for the same task they said FORWARD , here its PREROUTING , wich one is the correct choice and why ?????? i asked this question for 1000 times here and ......... i found its the hardest question ever asked ..
 
User avatar
Mitak
newbie
Posts: 42
Joined: Wed Jun 07, 2006 10:12 am
Location: Bulgaria
Contact:

Re: :o)

Thu Jun 15, 2006 12:09 am

:o)

OK It's work, but I have second problem with this solution :shock:

I use (shaping) FTP ->
1. client from LAN to WAN a need limit 1500Kbs
2. client from WAN to LAN a need limit 512Kbs

=> DLS line type

Thanks for help.
I will answer you tomorow... tonight (it`s 00:08 now) i`m drunk, it`s possibly to do nonsenses... some hours of sleeping will be a good relax for me.
 
michalkos
newbie
Topic Author
Posts: 49
Joined: Sun Jun 11, 2006 11:33 pm

Thu Jun 15, 2006 12:28 am

I should drink ! It miss me :cry:
 
User avatar
Mitak
newbie
Posts: 42
Joined: Wed Jun 07, 2006 10:12 am
Location: Bulgaria
Contact:

--

Thu Jun 15, 2006 9:54 am

You want to shape only FTP connections ftom WAN to LAN & LAN to WAN, or all connections?
 
michalkos
newbie
Topic Author
Posts: 49
Joined: Sun Jun 11, 2006 11:33 pm

Thu Jun 15, 2006 9:59 am

I need shape all connection by protocol:

download (on local) to 1500k
upload (on side wan from my LAN ) to 512K

When I connect (for example FTP) from WAN and "download" from my LAN server a use limit DSL 512,

but when i connect from LAN PC to some public FTP i need limitation 1500K - DSL limitation.

QTree using UP limit and get resouces (bandwidth) from this limit.
I don't know how I must set it.

Thanks !!!
 
User avatar
Mitak
newbie
Posts: 42
Joined: Wed Jun 07, 2006 10:12 am
Location: Bulgaria
Contact:

wiki.mikrotik.com

Thu Jun 15, 2006 10:04 am

See this wiki for an example:


http://wiki.mikrotik.com/wiki/PCQ_Examples


I think this will help you. If not, just post here again :)