Building a docker image in ppc64le fails when calling apt update: "Invalid cross-device link"

My builds on ppc64le have been failing for the past day. I am running docker build where file contains

FROM arm64v8/ubuntu:xenial

ARG PLATFORM=arm64v8
RUN apt update

This is the branch of the repo. A few weeks ago it built with no problems. Any ideas?

Here is a snippet of the error

Selecting previously unselected package libidn11:ppc64el.
(Reading database ... 4777 files and directories currently installed.)
Preparing to unpack .../libidn11_1.32-3ubuntu1.2_ppc64el.deb ...
Unpacking libidn11:ppc64el (1.32-3ubuntu1.2) ...
dpkg: error processing archive /var/cache/apt/archives/libidn11_1.32-3ubuntu1.2_ppc64el.deb (--unpack):
 unable to install new version of './usr/share/doc/libidn11': Invalid cross-device link
Selecting previously unselected package libssl1.0.0:ppc64el.
Preparing to unpack .../libssl1.0.0_1.0.2g-1ubuntu4.16_ppc64el.deb ...
Unpacking libssl1.0.0:ppc64el (1.0.2g-1ubuntu4.16) ..
dpkg: error processing archive /var/cache/apt/archives/libssl1.0.0_1.0.2g-1ubuntu4.16_ppc64el.deb (--unpack):
 unable to install new version of './usr/share/doc/libssl1.0.0': Invalid cross-device link

@mattip. There were some backend changes made recently which are causing this failure and is only seen for ubuntu container.

We are also seeing input/output errors, like in this build https://travis-ci.com/github/pypa/manylinux/jobs/379354273

Just want to say that we are experiencing similar issues. Invoking apt-get inside docker build causes the build to fail due to “Invalid cross-device link”. This issue seems to have come up before https://github.com/docker/for-linux/issues/480
but the cause appears to be different this time.

1 Like

According to https://github.com/docker/for-linux/issues/480#issuecomment-438850163, this happens in overlayfs when its upper and work are on different filesystems, in violation of the driver’s requirements. In kernel 4.19, a default for overlayfs was changed which apparently made this failure mode more prominent.

https://travis-ci.com/github/native-api/test_travis/builds/192296826 shows that currently, both upper and work are in /var/lib/docker/overlay2. And I can’t reproduce the error with apt install wget.

This failure has been resolved now.

test job: Travis CI - Test and Deploy with Confidence