Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 29 Aug 2015 22:57:30 -0400
From:      Michael Powell <nightrecon@hotmail.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: disabling dhclient
Message-ID:  <mrtrev$t8p$1@ger.gmane.org>
References:  <55e25852.0Xpg4zY1btmbpx9Z%perryh@pluto.rain.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Perry Hutchison wrote:

> My FreeBsd 8 system has recently developed an annoying habit of
> running dhclient during reboot.  There is only one Ethernet card
> (xl0), and it is not supposed to be using DHCP -- it has a static
> IP address assigned in rc.conf.  During the last couple of reboots
> dhclient has assigned a second IP address, and things have gone
> downhill from there.
> 
> Is there a configuration knob somewhere that will say "never run
> dhclient" or "never run dhclient on xl0", or do I need to take
> a sledgehammer approach (like hacking on /etc/rc.d/dhclient, or
> replacing /sbin/dhclient with a link to /bin/true)?
> 

I don't remember for sure if these were showing up in 10.0 or if they 
started after upgrading to 10.1:

Aug 24 21:11:54 testbed devd: Executing '/etc/rc.d/dhclient quietstart em0'
Aug 26 00:33:13 testbed devd: Executing '/etc/rc.d/dhclient quietstart em0'

Never investigated it but was wondering at the time why devd was running it, 
even though I have static ifconfig(s).

>From devd.conf:
# Try to start dhclient on Ethernet-like interfaces when the link comes
# up.  Only devices that are configured to support DHCP will actually
# run it.  No link down rule exists because dhclient automatically exits
# when the link goes down.

The above entries are incorrect; it runs no matter what.

For me it doesn't cause any problems so I ignored it. Figured if it wasn't a 
problem for anyone else either that I more than likely had just screwed up 
somewhere in mergemaster going from 10.0 to 10.1 (I do the source upgrade 
and do not use the binary update).

According to the line in devd.conf it's not supposed to start on interfaces 
that are not configured for DHCP in rc.conf, and all mine are static.

-Mike



> These are the settings in /etc/rc.conf:
> 
> ifconfig_xl0="192.168.0.81 netmask 255.255.0.0"
> defaultrouter="192.168.0.1"
> nfs_server_enable="YES"
> check_quotas="NO"
> rpcbind_enable="YES"
> nfs_client_enable="YES"
> sshd_enable="YES"
> inetd_enable="YES"
> kern_securelevel_enable="NO"
> linux_enable="YES"
> moused_enable="NO"
> moused_type="NO"
> sendmail_submit_enable="NO"
> sendmail_outbound_enable="NO"
> sendmail_msp_queue_enable="NO"
> lpd_enable="YES"
> 
> and this is what "ifconfig -a" reports (after I've used
> "ifconfig xl0 -alias 192.168.0.3" to remove the extra IP address):
> 
> xl0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
> options=80009<RXCSUM,VLAN_MTU,LINKSTATE>
> ether 00:b0:d0:22:5a:14
> inet 192.168.0.81 netmask 0xffff0000 broadcast 192.168.255.255
> media: Ethernet autoselect (100baseTX <full-duplex>)
> status: active
> plip0: flags=8810<POINTOPOINT,SIMPLEX,MULTICAST> metric 0 mtu 1500
> lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
> options=3<RXCSUM,TXCSUM>
> inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3
> inet6 ::1 prefixlen 128
> inet 127.0.0.1 netmask 0xff000000
> nd6 options=3<PERFORMNUD,ACCEPT_RTADV>
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@freebsd.org"





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?mrtrev$t8p$1>