Skip to content

Instantly share code, notes, and snippets.

@waynedovey
Last active July 14, 2020 12:06
Show Gist options
  • Save waynedovey/1fb9e693a5e2633eac7c5e0f9d668f94 to your computer and use it in GitHub Desktop.
Save waynedovey/1fb9e693a5e2633eac7c5e0f9d668f94 to your computer and use it in GitHub Desktop.
RHEL Router Setup
https://www.lisenet.com/2016/firewalld-rich-and-direct-rules-setup-rhel-7-server-as-a-router/
nmcli d
systemctl mask iptables ip6tables ebtables
systemctl mask iptables
firewall-cmd --get-active-zones
firewall-cmd --get-default-zone
firewall-cmd --set-default-zone=public
firewall-cmd --remove-interface=ens224 --zone=public
firewall-cmd --permanent --add-interface=ens224 --zone=dmz
firewall-cmd --reload
firewall-cmd --get-active-zones
nmcli con mod ens192 connection.zone public
nmcli con mod ens224 connection.zone dmz
nmcli c reload
firewall-cmd --list-services --zone=dmz
firewall-cmd --list-services --zone=public
sysctl -w net.ipv4.ip_forward=1
firewall-cmd --permanent --zone=public --add-masquerade
firewall-cmd --reload
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment