mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-04 10:19:26 +00:00
Add and document kern.geom.stripe.fast_failed sysctl, which shows how
many times "fast" mode failed.
This commit is contained in:
parent
ec70430134
commit
cea363682f
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=133205
@ -183,6 +183,13 @@ This
|
||||
.Xr sysctl 8
|
||||
variable is read-only and can only be set as a tunable in
|
||||
.Xr loader.conf 5 .
|
||||
.It Va kern.geom.stripe.fast_failed
|
||||
How many times
|
||||
.Dq "fast mode"
|
||||
failed because of insufficient amount of memory.
|
||||
If this value is big, you should considern increasing
|
||||
.Va kern.geom.stripe.maxmem
|
||||
value.
|
||||
.El
|
||||
.Sh EXAMPLES
|
||||
The following example shows how to set up striped device from four disks
|
||||
|
@ -89,6 +89,9 @@ static u_int g_stripe_maxmem = MAX_IO_SIZE * 10;
|
||||
TUNABLE_INT("kern.geom.stripe.maxmem", &g_stripe_maxmem);
|
||||
SYSCTL_UINT(_kern_geom_stripe, OID_AUTO, maxmem, CTLFLAG_RD, &g_stripe_maxmem,
|
||||
0, "Maximum memory that can be allocated in \"fast\" mode (in bytes)");
|
||||
static u_int g_stripe_fast_failed = 0;
|
||||
SYSCTL_UINT(_kern_geom_stripe, OID_AUTO, fast_failed, CTLFLAG_RD,
|
||||
&g_stripe_fast_failed, 0, "How many times \"fast\" mode failed");
|
||||
|
||||
/*
|
||||
* Greatest Common Divisor.
|
||||
@ -583,8 +586,11 @@ g_stripe_start(struct bio *bp)
|
||||
fast = 1;
|
||||
}
|
||||
error = 0;
|
||||
if (fast)
|
||||
if (fast) {
|
||||
error = g_stripe_start_fast(bp, no, offset, length);
|
||||
if (error != 0)
|
||||
g_stripe_fast_failed++;
|
||||
}
|
||||
/*
|
||||
* Do use "economic" when:
|
||||
* 1. "Economic" mode is ON.
|
||||
|
Loading…
Reference in New Issue
Block a user