Static IP NAGIOS Using Nmtui
Static IP NAGIOS Using Nmtui
There's an easy way to perform these changes using nmtui (a text based GUI).
nmtui
Option 1)
Install the package using yum (which assumes your server has internet access via it's DHCP
address):
Once installed execute the command again and proceed with the next step.
Option 2)
Manually configure address in config file. Please follow the steps in the "Manual IP Configuration"
section that explains how to do this.
When you execute nmtui you will be prompted with a text based GUI:
Press Enter on Edit a connection
Press Tab on your keyboard until you are on <Automatic> selector next
to IPv4 CONFIGURATION
Press Enter, select Manual from the list and press Enter
Press Tab until you are on <Show> (for IPv4) and press Enter
Type a valid address with using CIDR notation, for example 10.25.40.70/16
Repeat these steps for the Gateway IP and DNS Servers fields
If you want to define a static IPv6 address, follow the same steps above for
the IPv6 CONFIGURATION section.
Now you will need to take the interface "down" and then back "up" again using the following
commands:
ifdown eno16777728
ifup eno16777728
Execute these commands to check your changes have been applied and that they are working:
ip addr
ping -c 4 www.nagios.com