OPNsense Forum

Archive => 22.1 Legacy Series => Topic started by: Friend4all on April 20, 2022, 07:20:41 AM

Title: route doesn't work properly
Post by: Friend4all on April 20, 2022, 07:20:41 AM
Hello, I'm having trouble with routing on my router. I created a new gateway and assigned a route to it. Also set up outgoing NAT for the 10.100.100.0/24 network. Everything is allowed in the firewall settings for LAN. On the 10.100.100.0/24 network, there is access to the router (to its web interface) and the Internet, but no access to other network devices (in my case, the web server on a Linux VM, I get a timeout error). The clients themselves from the network 192.168.1.0/24 connect without problems to devices from the network 10.100.100.0 (web server on the PC VM). Also there are no problems with ping from both sides. When I create a route to the 10.100.100.0 network on the Linux VM, the web page on the PC VM opens instantly.
Title: Re: route doesn't work properly
Post by: Friend4all on April 20, 2022, 07:25:08 AM
Couldn't include network in the first post
Title: Re: route doesn't work properly
Post by: steilfirn_8000 on April 20, 2022, 12:45:23 PM
How does the configuration of R3 looks?
Title: Re: route doesn't work properly
Post by: Friend4all on April 20, 2022, 01:20:05 PM
Only addresses on interfaces (192.168.1.101 - dhcp, 10.100.100.1 - static with dhcp server). There is no additional configuration done.
ip dhcp pool test
network 10.100.100.0 255.255.255.0
default-router 10.100.100.1
dns-server 8.8.8.8
!
interface Ethernet0/0
ip address dhcp
duplex auto
!
interface Ethernet0/1
ip address 10.100.100.1 255.255.255.0
duplex auto
Title: Re: route doesn't work properly
Post by: steilfirn_8000 on April 20, 2022, 02:48:57 PM
I think on R3 you would need to add a route as well
Title: Re: route doesn't work properly
Post by: Friend4all on April 20, 2022, 03:23:59 PM
Quote from: steilfirn_8000 on April 20, 2022, 02:48:57 PM
I think on R3 you would need to add a route as well
R3 use opnsense router as default gateway. and PC have access to internet
Here is sh ip ro output:
Gateway of last resort is 192.168.1.1 to network 0.0.0.0

S*    0.0.0.0/0 [254/0] via 192.168.1.1
      10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        10.100.100.0/24 is directly connected, Ethernet0/1
L        10.100.100.1/32 is directly connected, Ethernet0/1
      192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.1.0/24 is directly connected, Ethernet0/0
L        192.168.1.101/32 is directly connected, Ethernet0/0