3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
12 *
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21 /*
22 * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
23 */
24
25 #pragma dictionary "DISK"
26
27 #define P disk
28
29 fru P;
30 asru P;
31
32 /*
33 * Over all comments for this file:
34 * <disk-as-detector> The disk-as-detector DE provides the mapping between
35 * ereports generated by a kernel disk driver sd(7D) and resulting faults.
36 */
37
38 /*
39 * SERD engine for media error fault propagation:
40 *
41 * This strategy is designed to give a file system, like ZFS, the
42 * ability to attempt data recovery/relocation without faulting a disk.
43 * This implementation depends on a file system retry to the same lba
44 * to trigger a fault when recovery/relocation is not possible.
45 *
46 * We let the engine propagate one error only once every 1 minute and then if we
47 * still get 2 or more * errors within 24 hours for the same LBA, there is a fault.
48 */
49 engine serd.io.scsi.cmd.disk.dev.rqs.merr@P, N=1, T=24h;
50
51 /*
52 * disk-as-detector: fault events.
53 */
54 event fault.io.scsi.cmd.disk.dev.rqs.derr@P;
55 event fault.io.scsi.cmd.disk.dev.rqs.merr@P,
56 engine=serd.io.scsi.cmd.disk.dev.rqs.merr@P;
57
58 /*
59 * The uderr fault will be defined at some future time.
60 * event fault.io.scsi.cmd.disk.dev.uderr@P;
61 */
62
63 /*
64 * disk-as-detector: upset events.
65 * NOTE: For now we define an upset to implement discard.
66 */
67 event upset.io.scsi.cmd.disk.dev.rqs.derr@P;
168 ereport.io.scsi.cmd.disk.tran@P;
169
170 /*
171 * --------------------------------------
172 * The remainder of this file contains rules associated with the operation of
173 * cmd/fm/modules/common/disk-monitor/disk_monitor.c code.
174 *
175 * The disk DE provides a very simple 1-to-1 mapping between SCSI disk events
176 * generated by the disk-transport fmd module, and the resulting faults.
177 */
178
179 /*
180 * Fault events.
181 */
182 event fault.io.disk.over-temperature@P,
183 FITrate=10, FRU=P, ASRU=P;
184 event fault.io.disk.predictive-failure@P, FITrate=10,
185 FITrate=10, FRU=P, ASRU=P;
186 event fault.io.disk.self-test-failure@P, FITrate=10,
187 FITrate=10, FRU=P, ASRU=P;
188
189 /*
190 * ereports.
191 */
192 event ereport.io.scsi.disk.over-temperature@P;
193 event ereport.io.scsi.disk.predictive-failure@P;
194 event ereport.io.scsi.disk.self-test-failure@P;
195
196 /*
197 * Propagations.
198 */
199 prop fault.io.disk.over-temperature@P ->
200 ereport.io.scsi.disk.over-temperature@P;
201
202 prop fault.io.disk.self-test-failure@P ->
203 ereport.io.scsi.disk.self-test-failure@P;
204
205 prop fault.io.disk.predictive-failure@P ->
206 ereport.io.scsi.disk.predictive-failure@P {
207 setpayloadprop("asc", payloadprop("additional-sense-code")) &&
208 setpayloadprop("ascq", payloadprop("additional-sense-code-qualifier")) };
|
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
12 *
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21 /*
22 * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
23 * Copyright 2016 Nexenta Systems, Inc. All rights reserved.
24 */
25
26 #pragma dictionary "DISK"
27
28 #define P disk
29
30 fru P;
31 asru P;
32
33 /*
34 * Over all comments for this file:
35 * <disk-as-detector> The disk-as-detector DE provides the mapping between
36 * ereports generated by a kernel disk driver sd(7D) and resulting faults.
37 */
38
39 /*
40 * SERD engine for media error fault propagation:
41 *
42 * This strategy is designed to give a file system, like ZFS, the
43 * ability to attempt data recovery/relocation without faulting a disk.
44 * This implementation depends on a file system retry to the same lba
45 * to trigger a fault when recovery/relocation is not possible.
46 *
47 * We let the engine propagate one error only once every 1 minute and then if we
48 * still get 2 or more errors within 24 hours for the same LBA,
49 * there is a fault.
50 */
51 engine serd.io.scsi.cmd.disk.dev.rqs.merr@P, N=1, T=24h;
52
53 /*
54 * disk-as-detector: fault events.
55 */
56 event fault.io.scsi.cmd.disk.dev.rqs.derr@P;
57 event fault.io.scsi.cmd.disk.dev.rqs.merr@P,
58 engine=serd.io.scsi.cmd.disk.dev.rqs.merr@P;
59
60 /*
61 * The uderr fault will be defined at some future time.
62 * event fault.io.scsi.cmd.disk.dev.uderr@P;
63 */
64
65 /*
66 * disk-as-detector: upset events.
67 * NOTE: For now we define an upset to implement discard.
68 */
69 event upset.io.scsi.cmd.disk.dev.rqs.derr@P;
170 ereport.io.scsi.cmd.disk.tran@P;
171
172 /*
173 * --------------------------------------
174 * The remainder of this file contains rules associated with the operation of
175 * cmd/fm/modules/common/disk-monitor/disk_monitor.c code.
176 *
177 * The disk DE provides a very simple 1-to-1 mapping between SCSI disk events
178 * generated by the disk-transport fmd module, and the resulting faults.
179 */
180
181 /*
182 * Fault events.
183 */
184 event fault.io.disk.over-temperature@P,
185 FITrate=10, FRU=P, ASRU=P;
186 event fault.io.disk.predictive-failure@P, FITrate=10,
187 FITrate=10, FRU=P, ASRU=P;
188 event fault.io.disk.self-test-failure@P, FITrate=10,
189 FITrate=10, FRU=P, ASRU=P;
190 event fault.io.disk.ssm-wearout@P;
191
192 /*
193 * ereports.
194 */
195 event ereport.io.scsi.disk.over-temperature@P;
196 event ereport.io.scsi.disk.predictive-failure@P;
197 event ereport.io.scsi.disk.self-test-failure@P;
198 event ereport.io.scsi.disk.ssm-wearout@P;
199
200 /*
201 * Propagations.
202 */
203 prop fault.io.disk.over-temperature@P ->
204 ereport.io.scsi.disk.over-temperature@P;
205
206 prop fault.io.disk.self-test-failure@P ->
207 ereport.io.scsi.disk.self-test-failure@P;
208
209 prop fault.io.disk.predictive-failure@P ->
210 ereport.io.scsi.disk.predictive-failure@P {
211 setpayloadprop("asc", payloadprop("additional-sense-code")) &&
212 setpayloadprop("ascq", payloadprop("additional-sense-code-qualifier")) };
213
214 prop fault.io.disk.ssm-wearout@P ->
215 ereport.io.scsi.disk.ssm-wearout@P {
216 setpayloadprop("current-wearout-percentage",
217 payloadprop("current-ssm-wearout"))
218 && setpayloadprop("threshold-wearout-percentage",
219 payloadprop("threshold-ssm-wearout")) };
|