Community discussions

MikroTik App
 
icemanZ
just joined
Topic Author
Posts: 18
Joined: Thu Sep 14, 2006 2:29 am
Location: montreal, Canada

Assigning fixed ip or one-to-one NAT

Tue Jan 16, 2007 9:07 pm

Hi,

I am trying to get a server to be accessed behind a Mikrotic 2.9.3. I have a /30 of public IPs available to assign directly or through one-to-one NAT. I have a hotspot configured on Ethernet 2 and Public on Ethernet 1.

Hotspot works great. When I try the examples for one-to-one NAT it does not work. If I try to assign directly the public /30 on router and assign fixed IP on the server in the public /30, it also does not work. Is it the hotspot that is causing the problem?

What is the best way to configure for what I need to do?

Regards,

IcemanZ
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6697
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Wed Jan 17, 2007 1:51 pm

Do you have network /30 on the public interface ?
/30 network is designed for point-to-point networks, in other words /30 provides only 2 usable addresses,
e.g. gateway-client.
One address is assigned to gateway, second address is assigned to client (HotSpot router in your case).
Specific ports might be forwarded using NAT from public network to local, however you cannot make Full Nat using /30 subnet.
 
icemanZ
just joined
Topic Author
Posts: 18
Joined: Thu Sep 14, 2006 2:29 am
Location: montreal, Canada

Sat Jan 20, 2007 11:18 pm

Hi,

Yes I realize that. What I am trying to do is to have a mail server on internal server able to be accessed by the outside. I have tried using one to one nat by assigning a public IP on the public side of the MT and mapping it on a private static IP I assigned to the mail server. I can access the server form the outside, but on the inside the server can not access anything public.

I used the configuration I found on wikki and help sites to config the nat rules:
ip firewall nat> add action=dst-nat chain=dstnat \
dst-address=10.0.0.216/32 to-addresses=192.168.0.4
ip firewall nat> add action=src-nat chain=srcnat \
src-address=192.168.0.4/32 to-addresses=10.0.0.216

I do have a hotspot configured, but I am using different class C internal IPs for the one-to-one NAT. They are both on the same ethernet card.

Also, is there a way to control bandwith by using one-to-one NAT?