I feel dumb for asking this since it would seem simple enough. I have a small LAN that I was brought into that is an existing /24 network with ip addresses used up all over this space that I cannot change at this time to make subnetting easier. We are joining a new small dept to this LAN as a subnet by adding another router into the mix. Routes R1 and R2 are both mikrotik RB532’s running ROS 3.10.
The R1 router is configured to use NAT (src-nat / masquerade).
R1 has ether1 going to the internet, ether2 going to a switch which goes to R2
The R2 router: I am trying to avoid double-natting. It has no firewall rules and no nat rules.
R2 has ether1 going to ether2 on R1 via the switch, and ether2 going to the new LAN subnet
A small pdf drawing is attached of the setup if it helps visualize. subnet.pdf (59.2 KB)
I have static routes for R1 to the LAN on R2 and vice versa.
I can ping internally across subnets, but I cannot ping anything public from R2
I am lacking something here, can this be done or am I an idiot? I appreciate any help anyone can give on getting this type of scenario to work. Thanks for your time,
On R1, changed the outgoing interface to be ether1 for the masquerade nat rule.
Logged into R2 and tried to ping 64.233.167.104 (google) and still got a no route to host.
From R2 I can ping 192.168.1.1
From a pc behind R2 on the 10.10.10.0 LAN, I can ping 192.168.1.1 also, but nothing public (which I assumed)
So R2 traffic can get to the LAN default gateway on R1, but cannot get out past there. This doesn’t make any sense to me at all as to why. To me, the R2 traffic should look like it’s coming from 192.168.1.3 since it is directly connected and on the same subnet, so what is the problem. Apparently my lack of knowledge is one part of the equation…
Thanks for the help thus far, please keep the ideas coming.
Haven’t talked IP addreses yet.
R1 ether2 interface should be assigned 192.168.1.1/24
R2 ether1 interface should be assigned 192.168.1.3/24
R2 ether2 interface should be assigned 10.10.10.1/24
And the part about looking like 192.168.1.3, no. Unless you srcnat or masquerade R2, then all maintain their original IP address to R1 ether2. Between R1 ether2 and R1 ether 1, they will be masqueraded. To the world, they will appear as the IP of R1 ether1. You are ok there. There is a gateway route in R1 for the 10.10.10.0/24 net. That would be the only set it would not know how to find.
I don’t know about yours, but I think I spotted the challenge jlxl has.
It appears the default gateway route on R1 is not correct. That first line should be
0 A S 0.0.0.0/0 r x.x.x.x 1 ether1
The “0” after the gateway IP should be a “1”. That “0” indicates a local interface. The default gateway should show a “1” under distance.
The gateway IP should be the one your ISP gave you with your IP/netmask and dns servers. Insure you did not assign the gateway IP to ether1 too.