Closed sony2 closed 8 years ago
On 11/19/15 4:46 , sony2 wrote:
I have created a non-COAL Setup of sdc-docker. I am able to do a docker pull successfully, but I am not able to start a Docker Container:
docker run -it busybox Error response from daemon: could not get default network (f34641f0-8eb9-11e5-9e06-79f850120e70)
Docker Info:
Containers: 0 Images: 2 Storage Driver: sdc SDCAccount: xxx Execution Driver: sdc-0.3.0 Logging Driver: json-file Kernel Version: 3.12.0-1-amd64 Operating System: SmartDataCenter CPUs: 0 Total Memory: 0 B Name: xxxx ID: 888f1b69-7912-47fc-9776-f31410cb86c3 WARNING: bridge-nf-call-iptables is disabled WARNING: bridge-nf-call-ip6tables is disabled
sdc-docker img: f0ceec72-8a6a-11e5-abfe-9f96a3bc0f31
sdc-dockeradm log:
POST /v1.21/containers/create HTTP/1.1 host: my.sdc-docker:2376 user-agent: Docker-Client/1.9.0 (darwin) content-length: 1018 content-type: application/json accept-encoding: gzip { "Hostname": "", "Domainname": "", "User": "", "AttachStdin": true, "AttachStdout": true, "AttachStderr": true, "Tty": true, "OpenStdin": true, "StdinOnce": true, "Env": [], "Cmd": null, "Image": "busybox", "Volumes": {}, "WorkingDir": "", "Entrypoint": null, "OnBuild": null, "Labels": {}, "StopSignal": "SIGTERM", "HostConfig": { "Binds": null, "ContainerIDFile": "", "LxcConf": [], "Memory": 0, "MemoryReservation": 0, "MemorySwap": 0, "KernelMemory": 0, "CpuShares": 0, "CpuPeriod": 0, "CpusetCpus": "", "CpusetMems": "", "CpuQuota": 0, "BlkioWeight": 0, "OomKillDisable": false, "MemorySwappiness": -1, "Privileged": false, "PortBindings": {}, "Links": null, "PublishAllPorts": false, "Dns": null, "DnsOptions": null, "DnsSearch": null, "ExtraHosts": null, "VolumesFrom": null, "Devices": [], "NetworkMode": "host", "IpcMode": "", "PidMode": "", "UTSMode": "", "CapAdd": null, "CapDrop": null, "GroupAdd": null, "RestartPolicy": { "Name": "no", "MaximumRetryCount": 0 }, "SecurityOpt": null, "ReadonlyRootfs": false, "Ulimits": null, "LogConfig": { "Type": "", "Config": {} }, "CgroupParent": "", "ConsoleSize": [ 0, 0 ], "VolumeDriver": "" }, "Name": "trusting_blackwell" } -- HTTP/1.1 404 Not Found content-type: text/plain content-length: 68 date: Thu, 19 Nov 2015 12:35:00 GMT x-request-id: f34641f0-8eb9-11e5-9e06-79f850120e70 x-response-time: 50 server: Triton/1.9.0 (linux) could not get default network (f34641f0-8eb9-11e5-9e06-79f850120e70) -- DockerError: could not get default network; caused by ResourceNotFoundError: The resource you requested does not exist at DockerError._DockerBaseError (/opt/smartdc/docker/lib/errors.js:175:15) at new DockerError (/opt/smartdc/docker/lib/errors.js:196:22) at Object.ufdsErrorWrap (/opt/smartdc/docker/lib/errors.js:629:20) at /opt/smartdc/docker/lib/backends/sdc/containers.js:168:29 at f (/opt/smartdc/docker/node_modules/once/once.js:17:25) at /opt/smartdc/docker/node_modules/ufds/lib/index.js:1687:20 at f (/opt/smartdc/docker/node_modules/once/once.js:17:25) at EventEmitter.<anonymous> (/opt/smartdc/docker/node_modules/ufds/lib/index.js:3030:13) at EventEmitter.emit (events.js:95:17) at _done (/opt/smartdc/docker/node_modules/ufds/node_modules/ldapjs/lib/client/client.js:1133:22) Caused by: ResourceNotFoundError: The resource you requested does not exist at translateError (/opt/smartdc/docker/node_modules/ufds/lib/index.js:232:21) at EventEmitter.<anonymous> (/opt/smartdc/docker/node_modules/ufds/lib/index.js:3030:16) at EventEmitter.emit (events.js:95:17) at _done (/opt/smartdc/docker/node_modules/ufds/node_modules/ldapjs/lib/client/client.js:1133:22) at messageCallback (/opt/smartdc/docker/node_modules/ufds/node_modules/ldapjs/lib/client/client.js:1217:18) at Parser.onMessage (/opt/smartdc/docker/node_modules/ufds/node_modules/ldapjs/lib/client/client.js:833:14) at Parser.emit (events.js:95:17) at Parser.write (/opt/smartdc/docker/node_modules/ufds/node_modules/ldapjs/lib/messages/parser.js:105:8) at CleartextStream.onData (/opt/smartdc/docker/node_modules/ufds/node_modules/ldapjs/lib/client/client.js:820:26) at CleartextStream.emit (events.js:95:17) -- req.timers: { "handler-0": 35, "bunyan": 68, "handler-2": 244, "checkReadonlyMode": 21, "checkServices": 30, "reqAuth": 14722, "reqClientApiVersion": 32, "readBody": 334, "parseBody": 144, "validateCreateContainer": 47, "checkApprovedForProvisioning": 20, "reqImageIncludeSmartos": 23761, "parseQueryString": 125, "containerCreate": 10293 }
Reply to this email directly or view it on GitHub: https://github.com/joyent/sdc-docker/issues/55
Have you enabled fabrics in this environment?
No, I only have admin and external networks.
@sony2 Probably not well tested but I'm guessing you'll want to set metadata.USE_FABRICS = false
on the "docker" SAPI service. I'm guessing you currently have "USE_FABRICS": true
, the default as setup by sdcadm experimental udpate-docker
, in this output:
# sdc-sapi /services?name=docker | json -H 0.metadata
{
"SERVICE_NAME": "docker",
"SERVICE_DOMAIN": "docker.nightly-1.joyent.us",
"USE_TLS": true,
"user-script": "..."
}
sdc-sapi /services?name=docker | json -H 0.metadata
{
...
"USE_FABRICS": "false",
...
}
It has working until I have updated to the latest dev release.
Hrm, that is "false"
, instead of false
. I wonder if that makes a difference. What is the content of "/opt/smartdc/docker/etc/config.json" in your "docker0" zone?
Specifically, you will want to have this:
"overlay": {
"enabled": false
},
"overlay": {
"enabled": true
},
@sony2 Okay, there we go. Sorry that this is easily surprising. I think you should be able to do this:
echo '{"metadata": {"USE_FABRICS": false}}' | sapiadm update $(sdc-sapi /services?name=docker | json -H 0.uuid)
Then either wait for the sdc-docker config to get updated (~90s polling period) or force it with:
sdc-login -l docker
svcadm restart config-agent
Then ensure that you have "enabled": false
in that config file.
Now it works, Thank you for the support.
Glad you got it working again.
I have created a non-COAL Setup of sdc-docker. I am able to do a docker pull successfully, but I am not able to start a Docker Container:
Docker Info:
sdc-docker img: f0ceec72-8a6a-11e5-abfe-9f96a3bc0f31
sdc-dockeradm log: