<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>2840</bug_id>
          
          <creation_ts>2012-07-27 05:21:48 +0000</creation_ts>
          <short_desc>busybox: udhcpc misbehavior when &quot;ip=dhcp&quot;</short_desc>
          <delta_ts>2012-09-04 03:29:12 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>core</component>
          <version>1.3</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.3 M3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Jesse Zhang">sen.zhang</reporter>
          <assigned_to name="Jesse Zhang">sen.zhang</assigned_to>
          <cc>jessica.zhang</cc>
    
    <cc>liang.li2</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>richard.purdie</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>23551</commentid>
    <comment_count>0</comment_count>
    <who name="Jesse Zhang">sen.zhang</who>
    <bug_when>2012-07-27 05:21:48 +0000</bug_when>
    <thetext>I recently found that if &quot;ip=dhcp&quot; is specified in the kernel cmdline,
there would be some strange behaviour of udhcpc.

1. udhcpc is started two times during bootup.

    Starting Bootlog daemon: bootlogd.
    Configuring network interfaces... udhcpc (v1.19.4) started
    Sending discover...
    Sending select for 128.224.162.132...
    Lease of 128.224.162.132 obtained, lease time 172800
    /etc/udhcpc.d/50default: Adding DNS 128.224.160.11
    /etc/udhcpc.d/50default: Adding DNS 147.11.100.30
    /etc/udhcpc.d/50default: Adding DNS 147.11.1.11
    done.
    Starting portmap daemon...
    [...]
    Starting domain name service: named.
    udhcpc (v1.19.4) started
    Sending discover...
    Sending select for 128.224.162.132...
    Lease of 128.224.162.132 obtained, lease time 172800
    RTNETLINK answers: File exists
    /etc/udhcpc.d/50default: Adding DNS 128.224.160.11
    /etc/udhcpc.d/50default: Adding DNS 147.11.100.30
    /etc/udhcpc.d/50default: Adding DNS 147.11.1.11
    creating NFS state directory: done

2. udhcpc is *started* when system is being shutdown.

    Stopping domain name service: namedrndc: neither /etc/bind/rndc.conf nor /etc/bind/rndc.key wd
    .
    udhcpc (v1.19.4) started
    Sending discover...
    Sending select for 128.224.162.132...
    Lease of 128.224.162.132 obtained, lease time 172800
    RTNETLINK answers: File exists
    /etc/udhcpc.d/50default: Adding DNS 128.224.160.11
    /etc/udhcpc.d/50default: Adding DNS 147.11.100.30
    /etc/udhcpc.d/50default: Adding DNS 147.11.1.11
    Stopping system message bus: dbus.
    stopping statd: done

The reason is busybox installs a busybox-udhcpc init script, which would
start udhcpc when &quot;ip=dhcp&quot; is specified, but udhcpc is also invoked by
the networking service (as specified through /etc/network/interfaces).
That&apos;s why udhcpc is started twice.

And since the init script doesn&apos;t actually support &quot;stop&quot; actions, it
will start udhcpc again during system shutdown.

The obvious fix is to remove the busybox-udhcpc init script; all configs
should go through /etc/network/interfaces.

P.S. it only happens for non-qemu targets since they have different
configs. I used an intel emenlow.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>23743</commentid>
    <comment_count>1</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2012-08-02 14:32:31 +0000</bug_when>
    <thetext>Fixed in master: http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=a4b1e348484b74d055b8906413892789d3452f4a</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>24775</commentid>
    <comment_count>2</comment_count>
    <who name="liang li">liang.li2</who>
    <bug_when>2012-09-04 03:29:12 +0000</bug_when>
    <thetext>verified on mpc8315e-rdb board with nightly build 20120822-1 ,when change command line to &quot;ip=dhcp&quot;,no such error.
git info:bb0aab79e488a99cb1b43f72f0e8ddbe39d97519
git branch :poky/master</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>