Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save papertigers/0193d1c798016a6725b0bd468529e771 to your computer and use it in GitHub Desktop.
Save papertigers/0193d1c798016a6725b0bd468529e771 to your computer and use it in GitHub Desktop.
Diagnosing "No Compute Resources Available" messages in Triton.

No Compute Resources Available

This error is somewhat ambiguious because there is seemingly no indication which resource is exhausted.

Triton chooses compute nodes with a subcomponent called sdc-designation (also refered to as , DAPI). The full DAPI log for a provision job is embedded in the CNAPI log file and can be extracted with the workflow job uuid and the following script.

#!/bin/bash

set -o errexit

job_id=${1:-}

req_id=$(sdc-workflow "/jobs/$job_id" | json -Ha params.x-request-id)
cnapi=$(sdc-vmname cnapi)
grep -h "$req_id" /zones/${cnapi}/root/var/log/sdc/upload/cnapi_* $(svcs -z $cnapi -L cnapi) \
 | bunyan -c this.snapshot -o bunyan --strict | json -ga snapshot \
 | while read snap; do echo -e "${snap}\n" | openssl base64 -d | gunzip - | json ; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment