linux 4.13.0-42.47 ADT test failure with linux 4.13.0-42.47 (nbd-smoke-test)

Bug #1772024 reported by Kleber Sacilotto de Souza
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
nbd (Ubuntu)
Fix Released
High
Thadeu Lima de Souza Cascardo
Artful
Won't Fix
Medium
Thadeu Lima de Souza Cascardo
Bionic
Fix Released
Medium
Thadeu Lima de Souza Cascardo
Cosmic
Fix Released
High
Thadeu Lima de Souza Cascardo

Bug Description

[Impact]
nbd-server will crash when a client connects to it, if it was started without a server name. It may also leak fds if fork fails.

[Test Case]
Running the server with an empty config file and an image on the command line, and then starting a local client will crash the server. After the fix, it doesn't crash anymore, and a filesystem may be created and used after that.

[Regression Potential]
The fix also implies a small package change, to use quilt. It has built just fine and many tests have been run on top of those packages and no failure seemed to be the result of those userspace changes, but known failures in the kernel driver.

Testing failed on:
    amd64: https://objectstorage.prodstack4-5.canonical.com/v1/AUTH_77e2ada1e7a84929a74ba3b87153c0ac/autopkgtest-artful/artful/amd64/l/linux/20180518_040741_b3b54@/log.gz
    i386: https://objectstorage.prodstack4-5.canonical.com/v1/AUTH_77e2ada1e7a84929a74ba3b87153c0ac/autopkgtest-artful/artful/i386/l/linux/20180518_050911_b3b54@/log.gz
    ppc64el: https://objectstorage.prodstack4-5.canonical.com/v1/AUTH_77e2ada1e7a84929a74ba3b87153c0ac/autopkgtest-artful/artful/ppc64el/l/linux/20180518_040734_b3b54@/log.gz
    s390x: https://objectstorage.prodstack4-5.canonical.com/v1/AUTH_77e2ada1e7a84929a74ba3b87153c0ac/autopkgtest-artful/artful/s390x/l/linux/20180518_035527_b3b54@/log.gz

Revision history for this message
Kleber Sacilotto de Souza (kleber-souza) wrote :
Download full text (5.7 KiB)

ubuntu_nbd_smoke_test.nbd-smoke-test is causing the failure:

04:01:24 DEBUG| [stdout] Preparing to unpack .../nbd-client_1%3a3.15.2-3_amd64.deb ...
04:01:24 DEBUG| [stdout] Unpacking nbd-client (1:3.15.2-3) ...
04:01:24 DEBUG| [stdout] Selecting previously unselected package nbd-server.
04:01:24 DEBUG| [stdout] Preparing to unpack .../nbd-server_1%3a3.15.2-3_amd64.deb ...
04:01:24 DEBUG| [stdout] Unpacking nbd-server (1:3.15.2-3) ...
04:01:24 DEBUG| [stdout] Setting up nbd-server (1:3.15.2-3) ...
04:01:25 DEBUG| [stdout]
04:01:25 DEBUG| [stdout] Creating config file /etc/nbd-server/config with new version
04:01:25 DEBUG| [stdout] Adding system user `nbd' (UID 113) ...
04:01:25 DEBUG| [stdout] Adding new group `nbd' (GID 117) ...
04:01:25 DEBUG| [stdout] Adding new user `nbd' (UID 113) with group `nbd' ...
04:01:25 DEBUG| [stdout] Not creating home directory `/etc/nbd-server'.
04:01:25 DEBUG| [stdout] Processing triggers for systemd (234-2ubuntu12.4) ...
04:01:26 DEBUG| [stdout] Processing triggers for man-db (2.7.6.1-2) ...
04:01:26 DEBUG| [stdout] Setting up nbd-client (1:3.15.2-3) ...
04:01:26 DEBUG| [stdout] update-initramfs: deferring update (trigger activated)
04:01:26 DEBUG| [stdout] update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
04:01:26 DEBUG| [stdout] Processing triggers for systemd (234-2ubuntu12.4) ...
04:01:26 DEBUG| [stdout] Processing triggers for initramfs-tools (0.125ubuntu12.1) ...
04:01:26 DEBUG| [stdout] update-initramfs: Generating /boot/initrd.img-4.13.0-42-generic
04:01:51 ERROR| [stderr] W: --force-yes is deprecated, use one of the options starting with --allow instead.
04:01:51 DEBUG| Running 'rm -f /etc/*/S99autotest || true'
04:01:51 DEBUG| Running '/tmp/autopkgtest.UhL3tr/build.gne/src/autotest/client/tests/ubuntu_nbd_smoke_test/ubuntu_nbd_smoke_test.sh'
04:01:51 DEBUG| [stdout]
04:01:51 DEBUG| [stdout] --------------------------------------------------------------------------------
04:01:51 DEBUG| [stdout] Image path: /tmp/nbd_image.img
04:01:51 DEBUG| [stdout] Mount point: /mnt/nbd-test-2954
04:01:51 DEBUG| [stdout] Date: Fri May 18 04:01:51 UTC 2018
04:01:51 DEBUG| [stdout] Host: autopkgtest
04:01:51 DEBUG| [stdout] Kernel: 4.13.0-42-generic #47-Ubuntu SMP Wed May 9 08:48:35 UTC 2018
04:01:51 DEBUG| [stdout] Machine: autopkgtest x86_64 x86_64
04:01:51 DEBUG| [stdout] CPUs online: 4
04:01:51 DEBUG| [stdout] CPUs total: 4
04:01:51 DEBUG| [stdout] Page size: 4096
04:01:52 DEBUG| [stdout] Pages avail: 1743769
04:01:52 DEBUG| [stdout] Pages total: 2042037
04:01:52 DEBUG| [stdout] --------------------------------------------------------------------------------
04:01:52 DEBUG| [stdout]
04:01:52 ERROR| [stderr]
04:01:52 ERROR| [stderr] ** (process:3018): WARNING **: Specifying an export on the command line no longer uses the oldstyle protocol.
04:01:52 DEBUG| [stdout] Warning: the oldstyle protocol is no longer supported.
04:01:52 DEBUG| [stdout] This method now uses the newstyle protocol with a default export
04:01:54 ERROR| [stderr] Error: Read failed: End of file
04:01:54 ERROR| [stderr] Exiting.
04:01:54 DEBUG| [st...

Read more...

tags: added: kernel-adt-failure
summary: - linux 4.13.0-42.47 ADT test failure with linux 4.13.0-42.47
+ linux 4.13.0-42.47 ADT test failure with linux 4.13.0-42.47 (nbd-smoke-
+ test)
Changed in linux (Ubuntu):
importance: Undecided → High
assignee: nobody → Colin Ian King (colin-king)
status: New → In Progress
Changed in nbd (Ubuntu Cosmic):
assignee: nobody → Thadeu Lima de Souza Cascardo (cascardo)
importance: Undecided → Medium
milestone: none → ubuntu-18.06
status: New → In Progress
tags: added: patch
Revision history for this message
Thadeu Lima de Souza Cascardo (cascardo) wrote :

Package did not apply patches from debian/patches/, added --with quilt to dh call on debian/rules, fixing this.

Revision history for this message
Thadeu Lima de Souza Cascardo (cascardo) wrote :
Revision history for this message
Thadeu Lima de Souza Cascardo (cascardo) wrote :

Setting to high, as this affects linux testing, which blocks gcc.

Changed in nbd (Ubuntu Cosmic):
importance: Medium → High
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package nbd - 1:3.17-2ubuntu1

---------------
nbd (1:3.17-2ubuntu1) cosmic; urgency=medium

  * Fix segfault when exporting only from a file on the command line. (LP: #1772024)

 -- Thadeu Lima de Souza Cascardo <email address hidden> Wed, 23 May 2018 17:01:03 -0300

Changed in nbd (Ubuntu Cosmic):
status: In Progress → Fix Released
description: updated
Revision history for this message
Tyler Hicks (tyhicks) wrote :

@cascardo thanks for the debdiffs! I noticed that the nbd package is patchless (run 'what-patch' in the source directory to check this) but you added a patches via quilt. As much as I prefer quilt over patchless source packages, can you change it back to patchless and apply the patches directly to the source?

Here's a good example of how it should be done with the commit description and origin in the changelog itself:

  https://launchpad.net/ubuntu/+source/nbd/1:3.7-1ubuntu0.1

Sorry for the busy work :/

Changed in nbd (Ubuntu Bionic):
assignee: nobody → Thadeu Lima de Souza Cascardo (cascardo)
importance: Undecided → Medium
status: New → Incomplete
Changed in nbd (Ubuntu Artful):
assignee: nobody → Thadeu Lima de Souza Cascardo (cascardo)
importance: Undecided → Medium
status: New → Incomplete
Revision history for this message
Thadeu Lima de Souza Cascardo (cascardo) wrote :

Attaching a new debdiff, as simple diff (no quilt), to bionic.

Changed in nbd (Ubuntu Bionic):
status: Incomplete → In Progress
Revision history for this message
Thadeu Lima de Souza Cascardo (cascardo) wrote :

The latest version for bionic has been built on ppa:cascardo/ppa3, and has been tested on a ppc64le bionic system.

Revision history for this message
Tyler Hicks (tyhicks) wrote :

Thanks for fixing up the debdiff! I've sponsored it to Bionic after making a couple changes:

 - Added links to the upstream commits in the changelog. This is helpful since the patchless style of packaging doesn't have broken out patches where you can add the origin in the patch tags.

 - Used the version string 1:3.16.2-1ubuntu0.1 to match the version bump that's documented here: https://wiki.ubuntu.com/SecurityTeam/UpdatePreparation#Update_the_packaging

Changed in nbd (Ubuntu Bionic):
status: In Progress → Fix Committed
Changed in nbd (Ubuntu Xenial):
status: New → Invalid
Changed in nbd (Ubuntu Trusty):
status: New → Invalid
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Kleber, or anyone else affected,

Accepted nbd into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/nbd/1:3.16.2-1ubuntu0.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: added: verification-needed verification-needed-bionic
Changed in linux (Ubuntu Cosmic):
assignee: Colin Ian King (colin-king) → nobody
Revision history for this message
Thadeu Lima de Souza Cascardo (cascardo) wrote :

Server doesn't crash when using the package from bionic-proposed.

tags: added: verification-done-bionic
removed: verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package nbd - 1:3.16.2-1ubuntu0.1

---------------
nbd (1:3.16.2-1ubuntu0.1) bionic; urgency=medium

  * Fix bugs causing nbd-smoke-test to fail (LP: #1772024)
    - Fix segfault when exporting only from a file on the command line.
      + https://github.com/NetworkBlockDevice/nbd/commit/4c924b7b64fb1b6cb9be8e8f508d459c0ed05a60
    - Fix fd leaks when fork fails.
      + https://github.com/NetworkBlockDevice/nbd/commit/0e094066a2676149e511f41a5eee1062de73e198
    - debian/control: change Maintainer

 -- Thadeu Lima de Souza Cascardo <email address hidden> Wed, 30 May 2018 15:10:02 -0300

Changed in nbd (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Adam Conrad (adconrad) wrote : Update Released

The verification of the Stable Release Update for nbd has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Mathew Hodson (mhodson)
no longer affects: linux (Ubuntu Cosmic)
no longer affects: linux (Ubuntu Bionic)
no longer affects: linux (Ubuntu Artful)
no longer affects: linux (Ubuntu Xenial)
no longer affects: linux (Ubuntu Trusty)
no longer affects: linux (Ubuntu)
Changed in nbd (Ubuntu Artful):
status: Incomplete → Won't Fix
no longer affects: nbd (Ubuntu Xenial)
no longer affects: nbd (Ubuntu Trusty)
tags: removed: verification-needed
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.