Community discussions

MikroTik App
 
foffa
newbie
Topic Author
Posts: 32
Joined: Fri Aug 17, 2007 1:23 am

portforward their is must be a solution

Sun Nov 11, 2007 5:31 am

hello guyes

i have mikrotik running with load balancing ,hotspot,dhcp

mikrotik 10.0.0.2
1st router 192.168.16.1, mikrotik wan 192.168.16.2 configuerd as dmz in the adsl modem

2nd router 172.16.5.1 , mikrotik second wan 172.16.5.2

my ip 10.0.0.82 goes through (192.168.16.1 (1st adslmodem)open dmz for mikrotik)

now i want to forward all trafic coming from 192.168.16.1:6040-6045 to 10.0.0.82

>>also need to forward all trafic going from 10.0.0.82:6040-6045 to 192.168.16.1


there is must be a solution guyes i have tried allllllll thing wrote in here all time nat error in all programs
 
User avatar
Letni
Member
Member
Posts: 375
Joined: Tue Dec 05, 2006 5:16 am
Location: South Carolina

Re: portforward their is must be a solution

Sun Nov 11, 2007 5:32 pm

This rule will take care of packets coming in:
/ip firewall nat add action=dst-nat chain=dstnat comment="" disabled=no dst-address=192.168.16.2 dst-port=6040-6045 protocol=tcp to-addresses=10.0.0.82 to-ports=6040-6045
/ip firewall nat add action=dst-nat chain=dstnat comment="" disabled=no dst-address=192.168.16.2 dst-port=6040-6045 protocol=udp to-addresses=10.0.0.82 to-ports=6040-6045

Also make sure your these rule is high enough in the chain to catch the traffic.

Packets going out is a bit more unfamiliar to me because I have not setup any load balancing setups. The concept though is to setup routing marks to mark the traffic coming from 10.0.0.82:6040-6045 to use the gateway with 192.168.16.1
http://wiki.mikrotik.com/wiki/Load_Bala ... e_Gateways
 
foffa
newbie
Topic Author
Posts: 32
Joined: Fri Aug 17, 2007 1:23 am

Re: portforward their is must be a solution

Sun Nov 11, 2007 11:20 pm

thanks letni

look i have load balancing running fine

no i take care with coming packets it is ok
no what is the rule for outing packets

is it the same rule but with reversing ip adresses ???

and look loadbalancing dont make any problems with it it is running fine

and there is no problem with load balancing and port forwarding
 
User avatar
Letni
Member
Member
Posts: 375
Joined: Tue Dec 05, 2006 5:16 am
Location: South Carolina

Re: portforward their is must be a solution

Sun Nov 11, 2007 11:54 pm

The rule I gave you is the the way I do all my port forwarding.
The added complication in your scenario is that packets may go back out to the internet using the wrong DSL line and not make it to it's destination as expected. I believe you need to mark the packets coming from 10.0.0.82:6040-6045 with a routing mark to make sure they go out the correct DSL line.
 
foffa
newbie
Topic Author
Posts: 32
Joined: Fri Aug 17, 2007 1:23 am

Re: portforward their is must be a solution

Wed Nov 14, 2007 3:39 am

working fine
letni thanks alot it was my eroor
by the way hotspot needs to be edited to work fine with load balancing

you was right
packets return from the wrong dsl line :?
:D thanks

Who is online

Users browsing this forum: Bing [Bot], eworm, MichalPospichal, SinghMikrotik, verbovet and 84 guests