Community discussions

MikroTik App
 
ekkas
Long time Member
Long time Member
Topic Author
Posts: 567
Joined: Mon Sep 26, 2005 1:01 pm
Location: South Africa

PCC question

Thu Dec 10, 2009 2:16 am

In the http://wiki.mikrotik.com/wiki/PCC it shows the following 2 sections:

add chain=prerouting dst-address=10.111.0.0/24 action=accept in-interface=Local
add chain=prerouting dst-address=10.112.0.0/24 action=accept in-interface=Local

and

add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses:2/0 \
action=mark-connection new-connection-mark=wlan1_conn passthrough=yes
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses:2/1 \
action=mark-connection new-connection-mark=wlan2_conn passthrough=yes


Why can I not also use dst-address-type on the first section to generalize it, like below, as I use a combination of static IP and pppoe DSL clients as my WANs?

add chain=prerouting dst-address-type=local action=accept in-interface=Local

Ekkas
 
jirristols
newbie
Posts: 33
Joined: Fri May 15, 2009 4:36 pm
Location: Pretoria, South Africa
Contact:

Re: PCC question

Thu Dec 10, 2009 9:24 am

Wow Hey, something I can help with. I've been playing around with this PCC and found the same issue. For the static that is fine but for dynamic IP with PPPoE you have to specify the range of IP's you will be using. Seeing as you are from SA too here is where my IP range is but I think this is only for PTA or so.

41.240.0.0/13 is where my PPPoE IP's come from, but if you want to find out what yours is use this address
http://www.radb.net/ and query the IP address one of your PPPoE interfaces was assigned and you wil receive results with all the who is info of that IP and range.

/ip firewall mangle
add action=accept chain=prerouting comment="" disabled=no dst-address=192.168.2.0/24 in-interface=LocalLAN
add action=accept chain=prerouting comment="" disabled=no dst-address=41.240.0.0/13 in-interface=LocalLAN

but if that doesn't work for you, there are a few different PCC configs that you can try out, one of them:
http://www.mikrotik-routeros.com/?p=12

Just for an added extra.

Stols
 
ekkas
Long time Member
Long time Member
Topic Author
Posts: 567
Joined: Mon Sep 26, 2005 1:01 pm
Location: South Africa

Re: PCC question

Thu Dec 10, 2009 12:01 pm

Thanks for your reply.
In the example you gave, there is a whole bunch of extra mangle rules (seperate for new, established, related) and a whole bunch of extra routes (distance 1,2,3 for each WAN).
Do you maybe know why this is?
I think my problems started when I upgraded from 3.30 to 4 but I'm not entirely sure.
What do you set your MTU/MSS to on your ether and pppoe interfaces and do you have change-MSS rules in your mangle?

Thanks
Ekkas
 
jirristols
newbie
Posts: 33
Joined: Fri May 15, 2009 4:36 pm
Location: Pretoria, South Africa
Contact:

Re: PCC question

Thu Dec 10, 2009 12:39 pm

Those extra Mangle rules are probably for ensuring the connection remains on the same ADSL line (IP address) but I'm not sure, the change mss magle rules are added by default and are dynamic. I left my MTU setting on default 1480 when I created the PPPoE clients. The distance changes are either to ensure the outgoing WAN selection is random or for failover.

I also heard that the mangle rules in 4.x doesn't function the same as in 3.x
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8716
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: PCC question

Thu Dec 10, 2009 5:29 pm

add chain=prerouting dst-address=10.111.0.0/24 action=accept in-interface=Local
add chain=prerouting dst-address=10.112.0.0/24 action=accept in-interface=Local

Why can I not also use dst-address-type on the first section to generalize it, like below, as I use a combination of static IP and pppoe DSL clients as my WANs?

add chain=prerouting dst-address-type=local action=accept in-interface=Local
because 'dst-address-type=local' is only '10.111.0.2 and 10.112.0.2' in that example - the addresses on router's interfaces

above rules simply do not route local traffic to the internet
 
ekkas
Long time Member
Long time Member
Topic Author
Posts: 567
Joined: Mon Sep 26, 2005 1:01 pm
Location: South Africa

Re: PCC question

Thu Dec 10, 2009 11:09 pm

Ok, now I get it. Thanks.