Select Your Language

Infrastructure and Management

Cloud Computing

Storage

Runtimes

Integration and Automation

  • Comments
  • RHEL8: IP packets forwarding doesn't work

    Posted on

    Hi

    I can't configure rhel8 server to work as local gateway.

    net.ipv4.ip_forward = 1 is enabled, but clients of this gw can't acess external network

    I also applied commands which works well on rhel7:
    server have 2 nic
    int1 : 192.168.1.2 and ext : 10.0.1.2, and i try configure forwarding with firewalld:

    firewall-cmd --direct --permanent --add-rule ipv4 nat POSTROUTING 0 -o ext1 -j MASQUERADE; 
    firewall-cmd --direct --permanent --add-rule ipv4 filter FORWARD 0 -i int1 -o ext1 -j ACCEPT; 
    firewall-cmd --direct --permanent --add-rule ipv4 filter FORWARD 0 -i ext1 -o int1 -m state --state RELATED,ESTABLISHED -j ACCEPT;
    

    on client servers:

    ip route add default via 192.168.1.2 
    

    But, like I said, it's work fine only with rhel7 gateway server. With rhel8 i get this

    [root@client1 ~]# traceroute -T -p 443 access.redhat.com
    traceroute to 23.60.24.159 (23.60.24.159), 30 hops max, 60 byte packets
     1  _gateway (192.168.1.2)  1.435 ms  0.946 ms  6.314 ms
     2  _gateway (192.168.1.2)  6.292 ms !X  6.264 ms !X  6.235 ms !X
    

    also i tried to disable NetworkManager and install legacy network-scripts but without success.

    please explain to me where i am wrong.

    by

    points

    Responses

    Red Hat LinkedIn YouTube Facebook X, formerly Twitter

    Quick Links

    Help

    Site Info

    Related Sites

    © 2025 Red Hat