Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1422798 - [3.3]Custom build failed due to 'client is newer than server' -- docker-1.10.3
[3.3]Custom build failed due to 'client is newer than server' -- docker-1.10.3
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Build (Show other bugs)
3.3.1
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Cesar Wong
Wenjing Zheng
: Regression
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2017-02-16 04:39 EST by XiuJuan Wang
Modified: 2017-07-24 10 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Known Issue
Doc Text:
Cause: Running a custom build with an image that contains a Docker binary that is a different version than the Docker running on the OpenShift node, will result in an error. Consequence: The build will fail with a message about mismatched Docker API version. Workaround (if any): Set the DOCKER_API_VERSION environment variable in the BuildConfig to match the API version running on the node. For example: oc set env bc/buildcfg DOCKER_API_VERSION=1.22 Note that this will only work if the version of the Docker binary on the custom builder image is newer than the version running on the OpenShift node.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-04-12 15:13:09 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:0884 normal SHIPPED_LIVE Red Hat OpenShift Container Platform 3.5 RPM Release Advisory 2017-04-12 18:50:07 EDT

  None (edit)
Description XiuJuan Wang 2017-02-16 04:39:46 EST
Description of problem:
Create env with docker 1.10.3.
Custom build will fail due to 'client is newer than server'(client API version: 1.24, server API version: 1.22)

Version-Release number of selected component (if applicable):
docker-1.10.3

#oc version
oc v3.3.1.14
kubernetes v1.3.0+52492b4
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://ip-172-18-14-198.ec2.internal
openshift v3.3.1.14
kubernetes v1.3.0+52492b4


How reproducible:
always

Steps to Reproduce:
1.Check 'docker version' in master
# docker version
Client:
 Version:         1.10.3
 API version:     1.22
 Package version: docker-common-1.10.3-59.el7.x86_64
 Go version:      go1.6.2
 Git commit:      429be27-unsupported
 Built:           Fri Nov 18 17:03:44 2016
 OS/Arch:         linux/amd64

Server:
 Version:         1.10.3
 API version:     1.22
 Package version: docker-common-1.10.3-59.el7.x86_64
 Go version:      go1.6.2
 Git commit:      429be27-unsupported
 Built:           Fri Nov 18 17:03:44 2016
 OS/Arch:         linux/amd64

2.Create a custom build
3.

Actual results:
#oc  build-logs ruby-sample-build-2
Command "build-logs" is deprecated, use "oc logs build/<build-name>" instead.
Sending build context to Docker daemon 124.9 kB
Error response from daemon: client is newer than server (client API version: 1.24, server API version: 1.22)
Error response from daemon: client is newer than server (client API version: 1.24, server API version: 1.22)


Expected results:
Custom build should succeed.

Additional info:
Comment 1 Cesar Wong 2017-02-16 08:23:34 EST
Can you please include details about the custom build that you ran? (build config, source repo, etc)

Does the custom builder image include a docker client binary? If it does, and the version doesn't match what we are running on the node, there's really nothing we can do from the product side. As the end-user, if you are going to include a docker client binary in your image, you need to make sure that it's compatible.
Comment 2 XiuJuan Wang 2017-02-17 04:25:00 EST
Cesar,
I use [1] template with docker.io/openshift/origin-custom-docker-builder image.

The docker version in docker.io/openshift/origin-custom-docker-builder is 1.12.6-cs6, it doesn't match the docker version(1.10.3, api version 1.22) in my env.

Can we do something to allow custom build when the docker versions are dismatch in image and server?

[1] https://raw.githubusercontent.com/openshift/origin/master/examples/sample-app/application-template-custombuild.json
Comment 3 Ben Parees 2017-02-17 10:06:16 EST
Looks like if you add DOCKER_API_VERSION=1.22 as an environment variable on the buildconfig, that might solve it.  Can you try that?
Comment 4 Ben Parees 2017-02-17 10:07:05 EST
(based on this thread: https://github.com/docker/machine/issues/2147#issuecomment-237787281)
Comment 5 XiuJuan Wang 2017-02-20 00:53:06 EST
Ben,
It works when export DOCKER_API_VERSION=1.22 in buildconfig when client is newer than server with docker version.
Thanks.
Move this bug to verified.
Comment 7 errata-xmlrpc 2017-04-12 15:13:09 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:0884

Note You need to log in before you can comment on or make changes to this bug.