Networking Forums

Networking Forums > Computer Networking > Linux Networking > Cannot turn off DHCP in RedHat 9

Reply
Thread Tools Display Modes

Cannot turn off DHCP in RedHat 9

 
 
heybrakywacky@hotmail.com
Guest
Posts: n/a

 
      07-16-2005, 08:04 AM
I'm running a RedHat 9 system, and I'm trying to configure its primary
network interface (eth0) to have a static IP address. I run 'setup',
configure all of the proper settings under 'Network Configuration' (to
my knowledge), and verify the contents of
/etc/sysconfig/network-scripts/ifcfg-eth0:

DEVICE=eth0
ONBOOT=yes
BOOTPROTO=static
IPADDR=192.168.8.15
NETMASK=255.255.255.0
GATEWAY=192.168.8.1

But if I do a network restart (or even a reboot, for that matter),
whenever the eth0 interface comes back up, it keeps querying my DHCP
server for its settings, and configuring the interface as such.

Am I missing a configuration step? I've tried various things like
getting rid of the dhclient-eth0.leases file and dropping the lease
before resetting the network, but I can't find any combination that
will solve my problem. It seems like I must be missing some simple and
obvious way to turn the DHCP client off. But if it's down the
/etc/rc.d/init.d/network rabbit hole, I haven't found it yet.

Any help would be much appreciated. I'm looking forward to moving on
past this one.

Thanks,
Kevin

 
Reply With Quote
 
 
 
 
Jean-David Beyer
Guest
Posts: n/a

 
      07-16-2005, 10:27 AM
(E-Mail Removed) wrote:
> I'm running a RedHat 9 system, and I'm trying to configure its primary
> network interface (eth0) to have a static IP address. I run 'setup',
> configure all of the proper settings under 'Network Configuration' (to
> my knowledge), and verify the contents of
> /etc/sysconfig/network-scripts/ifcfg-eth0:
>
> DEVICE=eth0
> ONBOOT=yes
> BOOTPROTO=static
> IPADDR=192.168.8.15
> NETMASK=255.255.255.0
> GATEWAY=192.168.8.1
>
> But if I do a network restart (or even a reboot, for that matter),
> whenever the eth0 interface comes back up, it keeps querying my DHCP
> server for its settings, and configuring the interface as such.
>
> Am I missing a configuration step? I've tried various things like
> getting rid of the dhclient-eth0.leases file and dropping the lease
> before resetting the network, but I can't find any combination that
> will solve my problem. It seems like I must be missing some simple and
> obvious way to turn the DHCP client off. But if it's down the
> /etc/rc.d/init.d/network rabbit hole, I haven't found it yet.
>
> Any help would be much appreciated. I'm looking forward to moving on
> past this one.
>
> Thanks,
> Kevin
>

Here is mine from a RHL 9 system:

DEVICE=eth0
BOOTPROTO=none
BROADCAST=192.168.1.255
IPADDR=192.168.1.2
NETMASK=255.255.255.0
NETWORK=192.168.1.0
ONBOOT=yes
HWADDR=00:75:27:21:12:75
USERCTL=no
PEERDNS=no
GATEWAY=192.168.1.1
TYPE=Ethernet


--
.~. Jean-David Beyer Registered Linux User 85642.
/V\ PGP-Key: 9A2FC99A Registered Machine 241939.
/( )\ Shrewsbury, New Jersey http://counter.li.org
^^-^^ 06:25:00 up 31 days, 17 min, 4 users, load average: 5.21, 5.18, 4.95
 
Reply With Quote
 
Allen McIntosh
Guest
Posts: n/a

 
      07-16-2005, 04:16 PM
> DEVICE=eth0
> ONBOOT=yes
> BOOTPROTO=static
> IPADDR=192.168.8.15
> NETMASK=255.255.255.0
> GATEWAY=192.168.8.1

This all looks fine.
> Am I missing a configuration step? I've tried various things like
> getting rid of the dhclient-eth0.leases file and dropping the lease
> before resetting the network, but I can't find any combination that
> will solve my problem. It seems like I must be missing some simple and
> obvious way to turn the DHCP client off. But if it's down the
> /etc/rc.d/init.d/network rabbit hole, I haven't found it yet.


One possible problem is that the script exists in three places down said
rabbit hole:

$ pwd
/etc/sysconfig
$ find . -name ifcfg-eth0 -print | xargs ls -l
-rw-r--r-- 3 root root 145 Dec 22 2004
../network-scripts/ifcfg-eth0
-rw-r--r-- 3 root root 145 Dec 22 2004
../networking/devices/ifcfg-eth0
-rw-r--r-- 3 root root 145 Dec 22 2004
../networking/profiles/default/ifcfg-eth0

If the links are broken on your machine, you could have edited the wrong
script.
 
Reply With Quote
 
heybrakywacky@hotmail.com
Guest
Posts: n/a

 
      07-16-2005, 06:58 PM
Eureka! network-scripts/ifcfg-eth0 and
networking/profiles/default/ifcfg-eth0 were both right, but
networking/devices/ifcfg-eth0 was still pointing to DHCP. I changed it
to be the same as the other two, reset the network, and my changes took
effect.

Thanks for your help!

Kevin

Allen McIntosh wrote:
>
> > Am I missing a configuration step? I've tried various things like
> > getting rid of the dhclient-eth0.leases file and dropping the lease
> > before resetting the network, but I can't find any combination that
> > will solve my problem. It seems like I must be missing some simple and
> > obvious way to turn the DHCP client off. But if it's down the
> > /etc/rc.d/init.d/network rabbit hole, I haven't found it yet.

>
> One possible problem is that the script exists in three places down said
> rabbit hole:
>
> $ pwd
> /etc/sysconfig
> $ find . -name ifcfg-eth0 -print | xargs ls -l
> -rw-r--r-- 3 root root 145 Dec 22 2004
> ./network-scripts/ifcfg-eth0
> -rw-r--r-- 3 root root 145 Dec 22 2004
> ./networking/devices/ifcfg-eth0
> -rw-r--r-- 3 root root 145 Dec 22 2004
> ./networking/profiles/default/ifcfg-eth0
>
> If the links are broken on your machine, you could have edited the wrong
> script.


 
Reply With Quote
 
Allen McIntosh
Guest
Posts: n/a

 
      07-17-2005, 12:59 AM
> I changed it
> to be the same as the other two, reset the network, and my changes took
> effect.

It's not clear from this statement whether or not all three are now
links to the same file. If you use RedHat's GUI tools at all, you
should make sure they are, lest something get messed up again. Even if
you don't use the GUI tools, it's easier than having to remember to
change multiple files.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Turn off DHCP on D-Link WBR-1310 Justin Network Routers 2 03-12-2009 01:59 PM
Can't get PCI Network Card to Work - Knoppix 4.0.2/Redhat 7.2/Redhat 8.0 deja@chronofish.com Linux Networking 0 11-20-2005 05:02 PM
RedHat Linux Enterprise WS network lan dhcp script problem. CaptWiggum@gmail.com Linux Networking 0 04-21-2005 03:17 PM
Redhat 9.0 dhcp client & windows 2003 dhcp server: dynamic dns update Mads Ravn Linux Networking 0 06-29-2004 05:27 PM
redhat-config-network does not bring /etc/resolv via dhcp Minghui Yang Linux Networking 0 12-06-2003 05:01 PM



1 2 3 4 5 6 7 8 9 10 11