- Show all Docs ( 5 ) Collapse Docs
- Show all Docs ( 309 ) Collapse Docs
- Show all Docs ( 1 ) Collapse Docs
- Show all Docs ( 31 ) Collapse Docs
How to Set Manual or static IP Address on Fedora
In this article we will discuss How to Set Manual or static IP Address on Fedora,
There will come a moment in your career as a Linux system administrator when you will be tasked with the responsibility of configuring networking on your machine. On desktop computers, you are able to utilise dynamic IP addresses; but, in order to set up a server architecture, you will need to configure a static IP address (at least in most cases).
The following information on Internet Protocol version 4 (IPv4) will be used so that we may accomplish the objectives of this tutorial.
IP address: 192.168.10.10 Netmask: 255.255.255.0 Hostname: microhost.example.com Domain name: example.com Gateway: 192.168.10.1 DNS Server 1: 188.8.131.52 DNS Server 2: 184.108.40.206
To configure static IP address, open the /etc/sysconfig/network-scripts/ifcfg-eth0
Note: The filename ifcfg-eth may varies from CentOS to Redhat linux. In CentOS it is available named as ifcfg-eth0, whereas it will be available only as eth0.
Also, the file name will be depend on your device name available on your Linux machines such as ens0 or so on.
# vim /etc/sysconfig/network-scripts/ifcfg-eth0
Now make changes like shown below, please do not forget to make changes according to your need
Please note that, You only need to change the following points.
The rest of the entries should be left unchanged.
resolve.conf to change or update the DNS nameserver
# vi /etc/resolv.conf
Once you have made your changes restart the networking manager service with:
# systemctl restart NetworkManager
or you can just down and up the network interface using the below command
# ifdown eth0
# ifup eth0
Now to check the configured ip on your machine, run the below command