summaryrefslogtreecommitdiff
path: root/redfish-core/include/registries/storage_device_message_registry.hpp
blob: cf60d8a365f8fbef18dd01d05f95761cfe48a15d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
#pragma once
/****************************************************************
 *                 READ THIS WARNING FIRST
 * This is an auto-generated header which contains definitions
 * for Redfish DMTF defined messages.
 * DO NOT modify this registry outside of running the
 * parse_registries.py script.  The definitions contained within
 * this file are owned by DMTF.  Any modifications to these files
 * should be first pushed to the relevant registry in the DMTF
 * github organization.
 ***************************************************************/
#include "registries.hpp"

#include <array>

// clang-format off

namespace redfish::registries::storage_device
{
const Header header = {
    "Copyright 2020-2023 DMTF. All rights reserved.",
    "#MessageRegistry.v1_6_2.MessageRegistry",
    "StorageDevice.1.2.1",
    "Storage Device Message Registry",
    "en",
    "This registry defines the messages for storage devices.",
    "StorageDevice",
    "1.2.1",
    "DMTF",
};
constexpr const char* url =
    "https://redfish.dmtf.org/registries/StorageDevice.1.2.1.json";

constexpr std::array registry =
{
    MessageEntry{
        "BatteryCharging",
        {
            "A battery charging condition was detected.",
            "A charging condition for the battery located in '%1' was detected.",
            "Warning",
            1,
            {
                "string",
            },
            "None.  There may be reduced performance and features while the battery is charging.",
        }},
    MessageEntry{
        "BatteryFailure",
        {
            "A battery failure condition was detected.",
            "A failure condition for the battery located in '%1' was detected.",
            "Critical",
            1,
            {
                "string",
            },
            "Ensure all cables are properly and securely connected.  Replace the failed battery.",
        }},
    MessageEntry{
        "BatteryMissing",
        {
            "A battery missing condition was detected.",
            "The battery located in '%1' is missing.",
            "Critical",
            1,
            {
                "string",
            },
            "Attach the battery.  Ensure all cables are properly and securely connected.",
        }},
    MessageEntry{
        "BatteryOK",
        {
            "The health of a battery has changed to OK.",
            "The health of the battery located in '%1' has changed to OK.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ControllerDegraded",
        {
            "A storage controller degraded condition was detected.",
            "A degraded condition for the storage controller located in '%1' was detected due to reason '%2'.",
            "Warning",
            2,
            {
                "string",
                "string",
            },
            "Reseat the storage controller in the PCI slot.  Update the controller to the latest firmware version.  If the issue persists, replace the controller.",
        }},
    MessageEntry{
        "ControllerFailure",
        {
            "A storage controller failure was detected.",
            "A failure condition for the storage controller located in '%1' was detected.",
            "Critical",
            1,
            {
                "string",
            },
            "Reseat the storage controller in the PCI slot.  Update the controller to the latest firmware version.  If the issue persists, replace the controller.",
        }},
    MessageEntry{
        "ControllerOK",
        {
            "The storage controller health has changed to OK.",
            "The health of the storage controller located in '%1' has changed to OK.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ControllerPasswordAccepted",
        {
            "The storage controller password was entered.",
            "A password was entered for the storage controller located in '%1'.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ControllerPasswordRequired",
        {
            "The storage controller requires a password.",
            "The storage controller located in '%1' requires a password.",
            "Critical",
            1,
            {
                "string",
            },
            "Enter the controller password.",
        }},
    MessageEntry{
        "ControllerPortDegraded",
        {
            "A controller port degraded condition was detected.",
            "A degraded condition for the controller port located in '%1' was detected due to reason '%2'.",
            "Warning",
            2,
            {
                "string",
                "string",
            },
            "Ensure all cables are properly and securely connected.  Replace faulty cables.",
        }},
    MessageEntry{
        "ControllerPortFailure",
        {
            "A controller port failure condition was detected.",
            "A failure condition for the controller port located in '%1' was detected.",
            "Critical",
            1,
            {
                "string",
            },
            "Ensure all cables are properly and securely connected.  Replace faulty cables.",
        }},
    MessageEntry{
        "ControllerPortOK",
        {
            "The health of a controller port has changed to OK.",
            "The health of the controller port located in '%1' has changed to OK.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "ControllerPreviousError",
        {
            "A storage controller error was detected prior to reboot.",
            "A previous error condition for the storage controller located in '%1' was detected due to '%2'.",
            "Warning",
            2,
            {
                "string",
                "string",
            },
            "Update the controller to the latest firmware version.  If the issue persists, replace the controller.",
        }},
    MessageEntry{
        "DriveFailure",
        {
            "A drive failure condition was detected.",
            "A failure condition for the drive located in '%1' was detected.",
            "Critical",
            1,
            {
                "string",
            },
            "Ensure all cables are properly and securely connected.  Ensure all drives are fully seated.  Replace the defective cables, drive, or both.",
        }},
    MessageEntry{
        "DriveFailureCleared",
        {
            "A previously detected failure condition on a drive was cleared.",
            "A failure condition for the drive located in '%1' was cleared.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "DriveInserted",
        {
            "A drive was inserted.",
            "The drive located in '%1' was inserted.",
            "OK",
            1,
            {
                "string",
            },
            "If the drive is not properly displayed, attempt to refresh the cached data.",
        }},
    MessageEntry{
        "DriveMissing",
        {
            "A drive missing condition was detected.",
            "A missing condition for the drive located in '%1' was detected.",
            "Critical",
            1,
            {
                "string",
            },
            "Ensure all cables are properly and securely connected.  Ensure all drives are fully seated.  Replace the defective cables, drive, or both.  Delete the volume if it is no longer needed.",
        }},
    MessageEntry{
        "DriveMissingCleared",
        {
            "A previous drive missing condition was cleared.",
            "A missing condition for the drive located in '%1' was cleared.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "DriveOK",
        {
            "The health of a drive has changed to OK.",
            "The health of the drive located in '%1' has changed to OK.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "DriveOffline",
        {
            "A drive offline condition was detected.",
            "An offline condition for the drive located in '%1' was detected.",
            "Critical",
            1,
            {
                "string",
            },
            "If the drive is unconfigured or needs an import, configure the drive.  If the drive operation is in progress, wait for the operation to complete.  If the drive is not supported, replace it.",
        }},
    MessageEntry{
        "DriveOfflineCleared",
        {
            "A drive offline condition was cleared.",
            "An offline condition for the drive located in '%1' was cleared.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "DrivePredictiveFailure",
        {
            "A predictive drive failure condition was detected.",
            "A predictive failure condition for the drive located in '%1' was detected.",
            "Warning",
            1,
            {
                "string",
            },
            "If this drive is not part of a fault-tolerant volume, first back up all data, then replace the drive and restore all data afterward.  If this drive is part of a fault-tolerant volume, replace this drive as soon as possible as long as the volume health is OK.",
        }},
    MessageEntry{
        "DrivePredictiveFailureCleared",
        {
            "A previously detected predictive failure condition on a drive was cleared.",
            "A predictive failure condition for the drive located in '%1' was cleared.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "DriveRemoved",
        {
            "A drive was removed.",
            "The drive located in '%1' was removed.",
            "Critical",
            1,
            {
                "string",
            },
            "If the drive is still displayed, attempt to refresh the cached data.",
        }},
    MessageEntry{
        "VolumeDegraded",
        {
            "The storage controller has detected a degraded volume condition.",
            "The volume '%1' attached to the storage controller located in '%2' is degraded.",
            "Warning",
            2,
            {
                "string",
                "string",
            },
            "Ensure all cables are properly and securely connected.  Replace failed drives.",
        }},
    MessageEntry{
        "VolumeFailure",
        {
            "The storage controller has detected a failed volume condition.",
            "The volume '%1' attached to the storage controller located in '%2' has failed.",
            "Critical",
            2,
            {
                "string",
                "string",
            },
            "Ensure all cables are properly and securely connected.  Ensure all drives are fully seated and operational.",
        }},
    MessageEntry{
        "VolumeOK",
        {
            "A volume health has changed to OK.",
            "The health of volume '%1' that is attached to the storage controller located in '%2' has changed to OK.",
            "OK",
            2,
            {
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "VolumeOffine",
        {
            "The storage controller has detected an offline volume condition.",
            "The volume '%1' attached to the storage controller located in '%2' is offline.",
            "Critical",
            2,
            {
                "string",
                "string",
            },
            "Use storage software to enable, repair, or import the volume.  You may also delete or move volume back to the original controller.",
        }},
    MessageEntry{
        "VolumeOffline",
        {
            "The storage controller has detected an offline volume condition.",
            "The volume '%1' attached to the storage controller located in '%2' is offline.",
            "Critical",
            2,
            {
                "string",
                "string",
            },
            "Use storage software to enable, repair, or import the volume.  You may also delete or move volume back to the original controller.",
        }},
    MessageEntry{
        "VolumeOfflineCleared",
        {
            "The storage controller has detected an online volume condition.",
            "The volume '%1' attached to the storage controller located in '%2' is online.",
            "OK",
            2,
            {
                "string",
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "WriteCacheDataLoss",
        {
            "The write cache is reporting loss of data in posted-writes memory.",
            "The write cache on the storage controller located in '%1' has data loss.",
            "Critical",
            1,
            {
                "string",
            },
            "Check the controller resource properties to determine the cause of the write cache data loss.",
        }},
    MessageEntry{
        "WriteCacheDegraded",
        {
            "The write cache state is degraded.",
            "The write cache state on the storage controller located in '%1' is degraded.",
            "Critical",
            1,
            {
                "string",
            },
            "Check the controller to determine the cause of write cache degraded state, such as a missing battery or hardware failure.",
        }},
    MessageEntry{
        "WriteCacheProtected",
        {
            "A storage controller write cache state is in protected mode.",
            "The write cache state on the storage controller located in '%1' is in protected mode.",
            "OK",
            1,
            {
                "string",
            },
            "None.",
        }},
    MessageEntry{
        "WriteCacheTemporarilyDegraded",
        {
            "The write cache state is temporarily degraded.",
            "The write cache state on the storage controller located in '%1' is temporarily degraded.",
            "Warning",
            1,
            {
                "string",
            },
            "Check the controller to determine the cause of write cache temporarily degraded state, such as a battery is charging or a data recovery rebuild operation is pending.",
        }},

};

enum class Index
{
    batteryCharging = 0,
    batteryFailure = 1,
    batteryMissing = 2,
    batteryOK = 3,
    controllerDegraded = 4,
    controllerFailure = 5,
    controllerOK = 6,
    controllerPasswordAccepted = 7,
    controllerPasswordRequired = 8,
    controllerPortDegraded = 9,
    controllerPortFailure = 10,
    controllerPortOK = 11,
    controllerPreviousError = 12,
    driveFailure = 13,
    driveFailureCleared = 14,
    driveInserted = 15,
    driveMissing = 16,
    driveMissingCleared = 17,
    driveOK = 18,
    driveOffline = 19,
    driveOfflineCleared = 20,
    drivePredictiveFailure = 21,
    drivePredictiveFailureCleared = 22,
    driveRemoved = 23,
    volumeDegraded = 24,
    volumeFailure = 25,
    volumeOK = 26,
    volumeOffine = 27,
    volumeOffline = 28,
    volumeOfflineCleared = 29,
    writeCacheDataLoss = 30,
    writeCacheDegraded = 31,
    writeCacheProtected = 32,
    writeCacheTemporarilyDegraded = 33,
};
} // namespace redfish::registries::storage_device