Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

zpool status: add -E flag for pool exclusion#17902

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
ixhamza wants to merge1 commit intoopenzfs:master
base:master
Choose a base branch
Loading
fromtruenas:zpool-status-exclude

Conversation

@ixhamza
Copy link
Member

@ixhamzaixhamza commentedNov 5, 2025
edited
Loading

Motivation and Context

Currently,zpool status lacks an option to exclude specific pools from output. Useful for hidingtest/backup/boot pools when monitoring systems with many pools.

Description

Adds-E flag to exclude specified pools from output. Takes comma-separated pool names and filters them out.
Example:zpool status -E tank,backup excludestank andbackup, showing all other pools.

How Has This Been Tested?

Manually tested exclusion from all pools and specific pools, edge cases (trailing commas, duplicate flags, invalid arguments), and combination with other flags.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Quality assurance (non-breaking change which makes the code more robust against bugs)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Library ABI change (libzfs, libzfs_core, libnvpair, libuutil and libzfsbootenv)
  • Documentation (a change to man pages or other documentation)

Checklist:

Adds -E flag to exclude comma-separated pools from zpool status output.Usage: 'zpool status -E tank,backup' shows all pools except tank andbackup.Signed-off-by: Ameer Hamza <ahamza@ixsystems.com>
Copy link
Contributor

@behlendorfbehlendorf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Actually there is an existing undocumented interface to exclude pools. The__ZFS_POOL_EXCLUDE environment variable can be set with a list of pools to exclude and it's applied to all of the subcommands. This is used by the test suite today to protect existing pools on a test system. I think adding a proper command line option for this is useful, but we should 1) add it to all the subcommands where it makes sense, and 2) use the same code internally to implement both the-E flag and__ZFS_POOL_EXCLUDE environment variable.

@behlendorfbehlendorf added the Status: Code Review NeededReady for review and testing labelNov 5, 2025
@ixhamza
Copy link
MemberAuthor

Thanks@behlendorf for the feedback, totally agreed. I'll extend it to all applicable subcommands and integrate with__ZFS_POOL_EXCLUDE using a shared implementation. Will update the patch.

@ixhamzaixhamza added the Status: Work in ProgressNot yet ready for general review labelNov 5, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@behlendorfbehlendorfbehlendorf left review comments

At least 1 approving review is required to merge this pull request.

Assignees

No one assigned

Labels

Status: Code Review NeededReady for review and testingStatus: Work in ProgressNot yet ready for general review

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@ixhamza@behlendorf

[8]ページ先頭

©2009-2025 Movatter.jp