[MultiOS][Yocto] The networking service always fail

Bug #1901820 reported by Jackie Huang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Committed
Low
Jackie Huang

Bug Description

Brief Description
-----------------
The networking service always fail

Severity
--------
<Major: System/Feature is usable but degraded>

Steps to Reproduce
------------------
1. build the image according to https://opendev.org/starlingx/meta-starlingx/src/branch/master/README.md
2. Install AIO simplex with the built out image
3. check the networking service

Expected Behavior
------------------
The networking service should be started successfully

Actual Behavior
----------------
controller-0:~# systemctl status networking
â networking.service - LSB: Raise network interfaces.
   Loaded: loaded (/etc/init.d/networking; generated)
   Active: failed (Result: exit-code) since Wed 2020-10-28 07:43:23 UTC; 19min ago
     Docs: man:systemd-sysv-generator(8)
  Process: 10290 ExecStart=/etc/init.d/networking start (code=exited, status=1/FAILURE)
      CPU: 22ms

Reproducibility
---------------
Reproducible

System Configuration
--------------------

Branch/Pull Time/Commit
-----------------------
Branch: master
Time: Sep 25 2020
Commit: 595181564502bc04028132b3af68ff551b6cbe47

Last Pass
---------

Timestamp/Logs
--------------

Test Activity
-------------

Workaround
----------

Changed in starlingx:
assignee: nobody → Jackie Huang (jackie-huang)
status: New → Confirmed
Revision history for this message
Ghada Khalil (gkhalil) wrote :

multi-os prep work; not gating for stx.5.0

Changed in starlingx:
importance: Undecided → Low
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to meta-starlingx (master)

Fix proposed to branch: master
Review: https://review.opendev.org/761047

Changed in starlingx:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: master
Review: https://review.opendev.org/761048

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to meta-starlingx (master)

Reviewed: https://review.opendev.org/761047
Committed: https://git.openstack.org/cgit/starlingx/meta-starlingx/commit/?id=c74ebee4bc74889ff57006d7d709e3650368f145
Submitter: Zuul
Branch: master

commit c74ebee4bc74889ff57006d7d709e3650368f145
Author: Jackie Huang <email address hidden>
Date: Fri Oct 30 17:29:51 2020 +0800

    init-ifupdown: add RDEPENDS on ifupdown

    The 'ifup' command provided by 'busybox' and 'ifupdown' behave differently
    when an interface has been configured:

    - The one from busybox
    $ sudo ifup lo; echo $?
    RTNETLINK answers: File exists
    1

    - The one from ifupdown
    $ sudo ifup lo; echo $?
    ifup: interface lo already configured
    0

    The exit code 1 from the busybox one would cause the networking service
    failed, so add RDEPENDS on ifupdown to avoid using the one from busybox.

    Partial-Bug: 1901820

    Change-Id: I6400a343bb2eebbf95a971a97f98a50ce588b6b2
    Signed-off-by: Jackie Huang <email address hidden>

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.opendev.org/761048
Committed: https://git.openstack.org/cgit/starlingx/meta-starlingx/commit/?id=587e1dbcf2633770a9d6717fe5f84ab6b08de2bd
Submitter: Zuul
Branch: master

commit 587e1dbcf2633770a9d6717fe5f84ab6b08de2bd
Author: Jackie Huang <email address hidden>
Date: Mon Nov 2 22:49:32 2020 +0800

    systemd-compat-units: fix the post install script

    The pkg_postinst_ontarget adds the following into the post
    install script:
    """
    if [ -n "$D" ]; then
        $INTERCEPT_DIR/postinst_intercept delay_to_first_boot %s mlprefix=%s
        exit 0
    fi
    """
    Which doesn't work when installing packages with anaconda and failed with:
    line 24: /postinst_intercept: No such file or directory

    So change to pkg_postinst and do the following to ensure the post install
    script run successfully both in do_rootfs and with anaconda:

    * "networking" is a sysv init script, no systemd service file, systemd
      command actually calls update-rc.d to enable the service, so change to
      use update-rc.d command directly.

    * Use different OPT according to the content of $D.

    Partial-Bug: 1901820

    Change-Id: I76a74228ed01e78f11876e2ef8901624ab9c6f0c
    Signed-off-by: Jackie Huang <email address hidden>

Changed in starlingx:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.