As I said, I ping 195.201.201.32 and with first rule I see reply in raw table. But no reply received at client. With edited rule client receive replies… Why?!
OK, I rename route mark only in mangle and route. No success…
And I don’t remove first rule, but add second, with big distance… And it’s works! Only for 195.201.201.32 unfortunately
It’s no problem to blackhole traffic But I can’t receive ping reply belong first rule… I see ping outgoing and no incomit after the raw table… Misterious…
Thank you for your time, but I create new thread to exlude unusable details.
Yes, I create additional rule for NAT, it used by both of this rules. But, I would like to focus on that fact: when I create route with route mark, I can’t receive ping reply. Only I setup direct route all parts of this traffic works well.
Moreover, I setup route with greater value of distance… And smaller value of distance ignored?
I concatenated two rules, dst-address and route-mark in one route, and it’s ignore reply again I can’t uderstand this situation and hope anybody help me to diagnose it…
Having different distances means nothing in this case - these two rules are in the different routing tables.
The fact that direct route (in the main table) is used, means that needed packets are never really marked by your mangle rule.
That would explain also why it doesn’t work with only marked route present.
I added second rule to mangle, logging packet with route mark tovpn. It’s counter increased as counter of the main mangle rule and I see outgoing packets in log… When I stopped ping, counter stopped too.
I created rule
Ok.
I think I know what the problem is: you need to use address as a gateway, not interface.
It works for a /32 address, thinking that it’s just another end of ptp-link, but won’t work for destinations with wider mask.
First of all: you can’t use mark-routinng for only the first packet.
Second: same thing about fasttrack - you can’t use it for traffic, that has to be mangled and routed through other routing table than main.
I can’t test it… Unfortunately, it’s main router, so I can’t pass all traffic to vpn. But, as I wrote above, packets goes to vpn and I see reply on router (see attached sniff). So packets goes to vpn and returned. But somehow lost in space, if I using route mark? sniff.gz (255 Bytes)