docker-machineをupdateした時に出たエラーの対処

docker-machineでdockerを使ってたら、以下のエラーが出たのでその対応!

$ docker ps
Error response from daemon: client is newer than server (client API version: 1.21, server API version: 1.20)

Error response from daemon: client is newer than server with Docker 1.9 RC3 · Issue #2147 · docker/machine · GitHub

docker-machineで作ったサーバをアップグレードすることにしました

docker-machine upgrade [server-name]

$ docker-machine upgrade dev
Detecting the provisioner...
Upgrading docker...
Downloading latest boot2docker iso...
Latest release for github.com/boot2docker/boot2docker is v1.9.1
Downloading https://github.com/boot2docker/boot2docker/releases/download/v1.9.1/boot2docker.iso to /Users/oomagaritomohisa/.docker/machine/cache/boot2docker.iso...
0%....10%....20%....30%....40%....50%....60%....70%....80%....90%....100%
Stopping machine to do the upgrade...
(dev) Stopping VM...
Upgrading machine "dev"...
Starting machine back up...
(dev) Starting VM...
Restarting docker...

docker-machine envをzshrcでやっていたので新たにtmuxでセッションを開いたら、以下の内容が出ました。

Error checking TLS connection: Error checking and/or regenerating the certs: There was an error validating certificates for host "192.168.99.100:2376": dial tcp 192.168.99.100:2376: i/o timeout
You can attempt to regenerate them using 'docker-machine regenerate-certs [name]'.
Be advised that this will trigger a Docker daemon restart which will stop running containers.

docker-machine regenerate-certs [server-name] を実行した

$  docker-machine regenerate-certs dev
Regenerate TLS machine certs?  Warning: this is irreversible. (y/n): y
Regenerating TLS certificates
Detecting the provisioner...
Copying certs to the local machine directory...
Copying certs to the remote machine...
Setting Docker configuration on the remote daemon...

うまく、動きました。