Select Your Language

Infrastructure and Management

Cloud Computing

Storage

Runtimes

Integration and Automation

  • Comments
  • RHEL as a router

    Posted on

    Good Evening,
    I am trying to configure RHEL 8 as a router. I have one interface facing the Internet with static IP address assigned (eth_ext) and one inteface (also static IP) facing LAN (eth_int). I set net.ipv4.ip_forward = 1 and made the following:

    firewall-cmd --direct --add-rule ipv4 nat POSTROUTING 0 -o eth_ext -j MASQUERADE
    firewall-cmd --direct --add-rule ipv4 filter FORWARD 0 -i eth_int -o eth_ext -j ACCEPT
    firewall-cmd --direct --add-rule ipv4 filter FORWARD 0 -i eth_ext -o eth_int -m state --state RELATED,ESTABLISHED -j ACCEPT

    I still can't access the internet from the second machine (that has only one nic connected to the same lan)

    by

    points

    Responses

    Red Hat LinkedIn YouTube Facebook X, formerly Twitter

    Quick Links

    Help

    Site Info

    Related Sites

    © 2026 Red Hat