1753596 Members
6567 Online
108796 Solutions
New Discussion юеВ

Re: Static IP

 
SOLVED
Go to solution
Allanm
Super Advisor

Static IP


How to configure a static IP on Linux.

Thanks.

2 REPLIES 2
Stuart Browne
Honored Contributor
Solution

Re: Static IP

If using a Redhat variant, it's easiest to modify '/etc/sysconfig/network-scripts/ifcfg-ethN'. These are the common lines you need:

DEVICE=bond0
BOOTPROTO=none
ONBOOT=yes
TYPE=Ethernet
NETMASK=255.255.255.0
IPADDR=192.168.1.250
GATEWAY=192.168.1.254
USERCTL=no

What says this is static? It's the BOOTPROTO line. This can be either 'none' or 'static'.

These values can be set using the 'system-config-network' tools (either gui or tui).

One long-haired git at your service...
Allanm
Super Advisor

Re: Static IP

Thanks !