There's no need to fiddle with the port number, just set up proper routing on system "X" (enable forwarding via /proc/sys/net/ipv4/ip_forward
if it's Linux, etc.), and, if system "X" isn't the gateway, also set routes in the 192.168.0.xxx subnet hosts.
Then you can reach 10.0.0.100 from the 192.168.0.xxx subnet.
Edit
I'll assume your 10.0.0.0 subnet is a /24-er subnet (netmask 255.255.255.0
; if not, modifying the following according to the netmask you used. You didn't give enough information about your networking setup, so let's say X has 192.168.0.123/24
on eno1
. Make sure this address is static and doesn't change; if your router does DHCP, use the webinterface of the router to assign X a static IP e.g. using the MAC address of eno1
.
First try setting the routes manually:
On any Linux (including CentOS): ip route add 10.0.0.0/24 via 192.168.0.123 dev eth0
, where eth0
is the 192.168.0.xxx
network interface on the machine where you set the route.
On Windows: Open terminal, type route add 10.0.0.0 mask 255.255.255.0 192.168.0.123
.
Then test with ping
etc. if the routing works. Use tcpdump -ni eno1
etc. on system X to debug if anything goes wrong.
If everything works, make the routes static. That depends on your CentOS setup; on Windows, see e.g. here. Similar tutorials are easy to find, google. Also consider googling for networking tutorials in general, so you have some background about why what you just did works.