Skip to content

[good-first-issue] List aggregates in cluster_info.py output #34

@hvinn

Description

@hvinn

Estimated time

20-25 minutes

Exact files to change

  • python/cluster_info.py (add a Step 3 block after the existing nodes loop)
  • python/README.md (the Cluster Info example output block)

Expected outcome

After listing nodes, the script also lists each aggregate fetched from
GET /storage/aggregates?fields=name,state,space.block_storage. Each row
shows aggregate name, state, and used percentage. README example output
is updated to match.

How to test

cd python
python cluster_info.py

Output ends with an Aggregates in cluster: N line followed by one row per
aggregate showing name, state, and used %.

ONTAP concepts touched

Aggregate. See docs/ontap-in-5-minutes.md#aggregate.

Hints / gotchas

Mirror the existing nodes loop. The path is /storage/aggregates. The
space-used percentage is space.block_storage.used / space.block_storage.size * 100.
Handle missing fields with .get(..., 0) to avoid KeyError on empty aggregates.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions