setup-static-ip-address-in-red-hat-enterprise-linux-8.webp

Setup static IP address in Red Hat Enterprise Linux 8

Setting up a static IP address in your RHEL or CentOS is simple. Prerequisite This how-to guide requires that you have administrative access to the Linux operating system. Steps Inside the RHEL Operating system, open the terminal and head to /etc/sysconfig/network-scripts. Using ls command, you can see the available network devices in the directory. cd /etc/sysconfig/network-scripts ls Use a text editor to edit the specific network device configuration vi ifcfg-ens192 A network configuration should look like similar to this In this sample configuration, we will need to specifically change or add the following: BOOTPROTO=none ONBOOT=yes IPADDR=x....

October 20, 2020 · John Pili
a-simple-firewall-cmd-cheatsheet.webp

A simple firewall-cmd cheatsheet

I tested this using CentOS 7 with firewalld service running. Get Default Zone To know the default zone, use this command firewall-cmd --get-default-zone Get Active Zones firewall-cmd --get-active-zones List Zone Services To check services, ports and settings on a specific zone, use this command firewall-cmd --zone=public --list-all Add a permanent port into a zone Adding a permanent TCP/UDP port in a specific zone. Example: opening MongoDB port firewall-cmd --permanent --zone=public --add-port=27017/tcp firewall-cmd --permanent --zone=public --add-port=27017/udp Remove a permanent port from a zone firewall-cmd --permanent --zone=public --remove-port=27017/tcp firewall-cmd --permanent --zone=public --remove-port=27017/udp Firewall-cmd reload To reflect your firewall changes....

May 27, 2018 · John Pili