Skip to content

Fix TestDaemonNoSpaceLeftOnDeviceError#37315

Merged
cpuguy83 merged 1 commit intomoby:masterfrom
thaJeztah:fix_TestDaemonNoSpaceLeftOnDeviceError
Jun 20, 2018
Merged

Fix TestDaemonNoSpaceLeftOnDeviceError#37315
cpuguy83 merged 1 commit intomoby:masterfrom
thaJeztah:fix_TestDaemonNoSpaceLeftOnDeviceError

Conversation

@thaJeztah
Copy link
Member

This test is testing if any "no space left on device" errors
that occur during docker pull will not be masked by other
errors. To test for this, a new loopback-device was created,
and used as --data-dir ("/var/lib/docker").

However, /var/lib/docker is used for storing various
other things, including a cache.db database, used by
BuildKit, which is created during startup of the daemon.
Creation of that file failed (due to --data-dir path
being on a mount with limited size), which caused daemon
start to fail before the test was able to run.

This patch changes the size-limited mount to be used for
the storage-driver directory only, so that the test is
not affected by other parts of the code attempting to
write files in it.

To have a predictable path; the daemon used in this test
is configured to use the vfs storage-driver.

Fixes #37277

This test is testing if any "no space left on device" errors
that occur during `docker pull` will not be masked by other
errors. To test for this, a new loopback-device was created,
and used as `--data-dir` ("/var/lib/docker").

However, `/var/lib/docker` is used for storing various
other things, including a `cache.db` database, used by
BuildKit, which is created during startup of the daemon.
Creation of that file failed (due to `--data-dir` path
being on a mount with limited size), which caused daemon
start to fail before the test was able to run.

This patch changes the size-limited mount to be used for
the storage-driver directory only, so that the test is
not affected by other parts of the code attempting to
write files in it.

To have a predictable path; the daemon used in this test
is configured to use the `vfs` storage-driver.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@thaJeztah
Copy link
Member Author

ping @tonistiigi @vdemeester PTAL

@codecov
Copy link

codecov bot commented Jun 20, 2018

Codecov Report

❗ No coverage uploaded for pull request base (master@de0abf4). Click here to learn what that means.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master   #37315   +/-   ##
=========================================
  Coverage          ?   34.81%           
=========================================
  Files             ?      609           
  Lines             ?    45000           
  Branches          ?        0           
=========================================
  Hits              ?    15667           
  Misses            ?    27218           
  Partials          ?     2115

Copy link
Contributor

@boaz0 boaz0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@cpuguy83 cpuguy83 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@cpuguy83 cpuguy83 merged commit 62c6a8f into moby:master Jun 20, 2018
@thaJeztah thaJeztah deleted the fix_TestDaemonNoSpaceLeftOnDeviceError branch June 20, 2018 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants