Skip to content

Instantly share code, notes, and snippets.

@kvaps
Last active February 18, 2024 17:15
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kvaps/078aa2676e9b29032cce9f972054cbe3 to your computer and use it in GitHub Desktop.
Save kvaps/078aa2676e9b29032cce9f972054cbe3 to your computer and use it in GitHub Desktop.
Troubleshoot auto-placing with LINSTOR
# linstor r c blbla --auto-place 4 --replicas-on-same opennebula-1=true -s thindata
ERROR:
Description:
    Not enough available nodes
Details:
    Not enough nodes fulfilling the following auto-place criteria:
     * has a deployed storage pool named 'thindata'
     * the storage pool 'thindata' has to have at least '104857600' free space
     * the current access context has enough privileges to use the node and the storage pool
     * the node is online
    Auto-placing resource: blbla
Show reports:
    linstor error-reports show 5DEE75F9-00000-000024
# Query nodes with storagepool thindata, with more than 104857600 free space
linstor -m sp l | jq -r '.[].stor_pools[] | select(.stor_pool_name=="thindata") | select(.free_space.free_capacity>104857600) | .node_name' > /tmp/1  

# Query online nodes with opennebula-1=true aux property set
linstor -m n l | jq -rc '.[].nodes[] | select(.connection_status==2) | select(.props | from_entries | select(."Aux/opennebula-1"=="true")) | .name' > /tmp/2

# Compare the lists
comm  /tmp/1 /tmp/2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment