How to set the IP and which configuration files?
I want to configure manually my NICs.
I know I need to edit the "ifcfg-eth[X]" file(s).
However, there are three location which they are present:
- "/etc/sysconfig/networking/devices"
- "/etc/sysconfig/network-scripts"
- "etc/sysconfig/networking/profiles/default"
I think the file I shoud edit are the ones in the "/etc/sysconfig/network-scripts" directory
but want to be absolutely sure.
Secondly, I wish to set my computer's IP.
I followed the instructions in "htt p://linuxguide.automatedshops.com/LinuxGuide/linux-ethernet.html"
but it didn't help.
The following is the contents of each file:
---> /etc/sysconfig/network-scripts/ifcfg-eth0 <---
DEVICE=eth0
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
TYPE=Ethernet
IPADDR=10.1.1.137
NETMASK=255.255.255.0
---> /etc/sysconfig/network <---
NETWORKING=yes
HOSTNAME=nlayers.il.nlayers.com
GATEWAYDEV=eth0
GATEWAY=10.1.1.254
---> /etc/hosts <---
127.0.0.1 nlayers.il.nlayers.com nlayers localhost.localdomain localhost
10.1.1.137 nlayers.il.nlayers.com nlayers
After doing "service network restart" or even rebooting, the computer stays with its previously 10.1.1.88 assigned address from DHCP.
I suspect it may still get its IP from there although I haven't found or don't know where to look for files which will confirm this.
P.S.
I'm using Redhat linux 9 with 4 NICs.
|