-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change checksum & IO delay ratelimit values #7252
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,6 +56,16 @@ | |
*/ | ||
int metaslabs_per_vdev = 200; | ||
|
||
/* | ||
* Rate limit delay events to this many IO delays per second. | ||
*/ | ||
unsigned int zfs_delays_per_second = 20; | ||
|
||
/* | ||
* Rate limit checksum events after this many checksum errors per second. | ||
*/ | ||
unsigned int zfs_checksums_per_second = 20; | ||
|
||
/* | ||
* Virtual device management. | ||
*/ | ||
|
@@ -351,8 +361,8 @@ vdev_alloc_common(spa_t *spa, uint_t id, uint64_t guid, vdev_ops_t *ops) | |
* and checksum events so that we don't overwhelm ZED with thousands | ||
* of events when a disk is acting up. | ||
*/ | ||
zfs_ratelimit_init(&vd->vdev_delay_rl, DELAYS_PER_SECOND, 1); | ||
zfs_ratelimit_init(&vd->vdev_checksum_rl, CHECKSUMS_PER_SECOND, 1); | ||
zfs_ratelimit_init(&vd->vdev_delay_rl, &zfs_delays_per_second, 1); | ||
zfs_ratelimit_init(&vd->vdev_checksum_rl, &zfs_checksums_per_second, 1); | ||
|
||
list_link_init(&vd->vdev_config_dirty_node); | ||
list_link_init(&vd->vdev_state_dirty_node); | ||
|
@@ -3752,5 +3762,14 @@ module_param(metaslabs_per_vdev, int, 0644); | |
MODULE_PARM_DESC(metaslabs_per_vdev, | ||
"Divide added vdev into approximately (but no more than) this number " | ||
"of metaslabs"); | ||
|
||
module_param(zfs_delays_per_second, uint, 0644); | ||
MODULE_PARM_DESC(zfs_delays_per_second, "Rate limit delay events to this many " | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: update also zfs-module-parameters(5)? |
||
"IO delays per second"); | ||
|
||
module_param(zfs_checksums_per_second, uint, 0644); | ||
MODULE_PARM_DESC(zfs_checksums_per_second, "Rate limit checksum events " | ||
"to this many checksum errors per second (do not set below zed" | ||
"threshold)."); | ||
/* END CSTYLED */ | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should note that setting these values too low could cause the zed to not behave as expected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For posterity...
As I read the code,
checksum_N
= 10 andchecksum_T
= 10 minutes, not 1 second in the SERD engine. This is consistent with Solaris. So effectively, we're good unless set to 0, which is effectively disabling the ereports.