How to disable dhclient

 
Thread Tools Search this Thread
Operating Systems Linux Red Hat How to disable dhclient
# 1  
Old 05-24-2010
How to disable dhclient

Hi

Can anyone please tell me how to disable dhclient on redhat host.

I have set static IP to one of my redhat host but I don't know how it changes to some other IP after few hours.

here is the output from ifcfg-eth0 and rc.local
Code:
test-123 root # cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
ONBOOT=yes
BOOTPROTO=static
IPADDR=X.X.X.X
NETMASK=255.255.255.0
GATEWAY=X.X.X.X

test-123 root # cat /etc/rc.local
#!/bin/sh
#
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don't
# want to do the full Sys V style init stuff.

touch /var/lock/subsys/local
test-123 #

Thanks for help.
Tannu

---------- Post updated at 06:09 PM ---------- Previous update was at 12:43 PM ----------

Added/var/log/messages

May 24 16:05:37 server dhclient: DHCPDISCOVER on lo to 255.255.255.255 port 67 interval 13
May 24 16:05:50 server dhclient: DHCPDISCOVER on lo to 255.255.255.255 port 67 interval 3
May 24 16:05:53 server dhclient: No DHCPOFFERS received.
May 24 16:05:53 server dhclient: No working leases in persistent database - sleeping.

Last edited by Scott; 05-24-2010 at 02:49 PM.. Reason: Code tags, please...
# 2  
Old 05-25-2010
Try changing BOOTPROTO to:
Code:
BOOTPROTO=none

If that does not work revert to using BOOTPROTO=static and check if your version of RedHat comes with NetworkManager. If this is the case turn NetworkManager off and disable using service/chkcfg.
# 3  
Old 05-25-2010
Thanks for your reply.

I figured out that the dhclient process was running so I killed the process kill -9 <pid> and after that the IP has not changed.

Thanks
Tannu
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

How to disable ping?

Hello Guys, how do you disable ping in solaris 10? Thanks in advance. (1 Reply)
Discussion started by: cjashu
1 Replies

2. Red Hat

SSL/TLS renegotiation DoS -how to disable? Is it advisable to disable?

Hi all Expertise, I have following issue to solve, SSL / TLS Renegotiation DoS (low) 222.225.12.13 Ease of Exploitation Moderate Port 443/tcp Family Miscellaneous Following is the problem description:------------------ Description The remote service encrypts traffic using TLS / SSL and... (2 Replies)
Discussion started by: manalisharmabe
2 Replies

3. Shell Programming and Scripting

Slow down output from dhclient-script to screen

Hi I know the basic about script and sleep processes. However this is more tricky: I would like to run sh -x /sbin/dhclient-script and slow down the output of the script as a whole. How would you do it? I would like to delay output on the screen with 1 second for every line for the output... (3 Replies)
Discussion started by: medium_linux
3 Replies

4. Ubuntu

Ubuntu dhclient and wimax problem

I use Ubuntu 9.10 Netbook Remix and Intel wimax drivers to connect to wimax networks, but recently I faced with some problems with connection even when the signal is available and it is at some proper level... Here is system log, which may concerns problem occurred: dhclient: Can't allocate... (0 Replies)
Discussion started by: Sapfeer
0 Replies

5. Shell Programming and Scripting

How to disable Enable/Disable Tab Key

Hi All, I have bash script, so what is sintax script in bash for Enable and Disable Tab Key. Thanks for your help.:( Thanks, Rico (1 Reply)
Discussion started by: carnegiex
1 Replies

6. Shell Programming and Scripting

Firewall disable

hello i am running an application whicks /proc/net/ip_tables_name and then give firewall ruuning error hence i have to completely remove my firewall from fedora ... i have already removed iptables using yum remove iptables... also i have to know how a file gets stored in the proc/net... (1 Reply)
Discussion started by: sudeepiit
1 Replies

7. Solaris

How to disable SU right

Anyone know how to disable SU right for a particular user in Solaris 8 (4 Replies)
Discussion started by: civic2005
4 Replies

8. AIX

disable rsh

Dear Frndz, Could you please help me How to disable rsh login in aix. Also, I want to know how to open a port for particular application in the serevr side in Aix. (3 Replies)
Discussion started by: sriram.s
3 Replies

9. UNIX for Dummies Questions & Answers

disable su

i have this unix version "unix v/386" and i want to disable su kindly help me (2 Replies)
Discussion started by: sak900354
2 Replies

10. UNIX for Dummies Questions & Answers

Disable X

Im sure this is somthing easy to do but i just can not figure it out where and how would i take X out of the boot for hp ux 11 i looked in the man's and nothing so maybe sombody could throw me a bone... thanks BB (8 Replies)
Discussion started by: bbutler3295
8 Replies
Login or Register to Ask a Question