Environment: two network segments, 192.168.1. * With 192.168.100. * The two vswitches cannot communicate with each other. 192.168.100. * There is a DNS on the network segment. One WEB server requires: 192.168.1. * access 192.168.100. * WEB server. implementation: Find a dual-nic Linux system. enable the routing function, # vietcsysctl. confnet. ipv4.ip_for
Environment: Two CIDR blocks, 192.168.1. * And 192.168.100. * cannot communicate with each other.
192.168.100. * There is a DNS server on the network segment.
Requirement: 192.168.1. * You can access the WEB server of 192.168.100.
Implementation:
Find a dual-nic Linux system. Enable the routing function,
- # Vi/etc/sysctl. conf
- Net. ipv4.ip _ forward = 1
- # Sysctl-p
- Eth0: 192.168.100.253
- Eth1: 192.168.1.253
Client 192.168.1. * Configuration:
Add a route entry:
- RouteDd-P 192.168.100.0 mask 255.255.255.0 192.168.1.253
Configure DNS to 192.168.100.
192.168.100. * WEB server configuration on the network segment:
- Route add-net 192.168.1.0 gw 192.168.100.253 netmask 255.255.255.0