summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Install elog parser and mako script for native processingMarri Devender Rao2017-10-112-19/+40
| | | | | | | | Installed elog parser and mako scripts are used by repositories to build elog-errors.hpp for local application specific errors Change-Id: I2353185d28db59b052d2167d6f37f1b385978bb3 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Enable Cereal class versioningVishwanatha Subbanna2017-10-113-7/+36
| | | | | | | | | Cereal class versioning helps to handle data de-serialization across different class versions that differ in the way, a particular data is serialized. Change-Id: Ica01c4cb0c213e0dca8824fcfcfaa5cb43c5bc2e Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
* phosphor-log-manager: Fix for deserialize cereal exceptionJayanth Othayoth2017-09-201-6/+17
| | | | | | | | | | | This commit provides a fix for an issue in which the cereal deserialize() would crash the phosphor-log-manager incase persistence file is empty in restore path. Resolves openbmc/openbmc#2337 Change-Id: Id9d8c066d0dc50cba62a67060c1ee8d43d046ff1 Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>
* Add implementation for delete all error log entries in one shotNagaraju Goruganti2017-09-135-7/+76
| | | | | | | Resolves openbmc/openbmc#1561. Change-Id: Iac5aaee1bdf9b87ccce9bf8801468ac5a8f9be6c Signed-off-by: Nagaraju Goruganti <ngorugan@in.ibm.com>
* Add _PID information in elog AdditionalDataJayanth Othayoth2017-09-121-0/+3
| | | | | | | | dreport need PID information to collect process specific journal for InternalFailure type error triggered dump. Change-Id: I313caa4795f7c0d47c1f42dae0653008cdbd5967 Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>
* Implement a cap on the number of committed errorsMarri Devender Rao2017-08-163-1/+34
| | | | | | | Resolves openbmc/openbmc#1617 Change-Id: I5850e5addb723e6f5102eb4677bb365285c1a633 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* commit: Add call to Synchronize journal dbus methodAdriana Kobylak2017-08-071-0/+9
| | | | | | | | | | | Call the Synchronize method at the beginning of the Commit function to request that all pending messages are written into the journal. Fixes: openbmc/openbmc#1297 Change-Id: Id0ab04ff0cb9b7eeac3b7c2aaeb8730a3b4ed524 Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
* Grammar fixes in app-local-errors READMEGunnar Mills2017-08-011-6/+6
| | | | | Change-Id: I217403a4a94f12b692a877418b34ed6a1cf8e142 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
* Remove elog-errors-HostEvent.hpp from phosphor-logging repoTom Joseph2017-07-253-88/+2
| | | | | | | Resolves openbmc/phosphor-logging#4 Change-Id: I15ccdef0dd63216991bbd113e47beb057df14df8 Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Add association intf if there is inventory path metadataTom Joseph2017-07-252-0/+25
| | | | | Change-Id: I7d717d8ea5ccb3186bc18a4d1fea848eb7b0fdff Signed-off-by: Tom Joseph <tomjoseph@in.ibm.com>
* Fix host error logged as INFOMarri Devender Rao2017-07-131-1/+1
| | | | | | | | | | | At present org.open_power.Error.Host.Event.Event is handcoded and is not part of the error map used by log manager to identify the type of the error. Resolves openbmc/openbmc#1953 Change-Id: I2f390c29c9b47adcf20efc32bbb02cf026d55758 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* update README.mdMarri Devender Rao2017-06-271-1/+16
| | | | | | | | Captured steps for generating application specific elog-errors.hpp file. Change-Id: I8fb7815f2fa86c52843b7eec6d562111d8179b7d Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Move serialization template functionsDeepak Kodihalli2017-06-252-44/+44
| | | | | | | | Move serialization template functions from elog_serialize.hpp to elog.serialize.cpp, since they are called only within the cpp. Change-Id: I8df216e1d4a745d1386fc310fc5d4d9535a8b7c3 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* serialization: add testsDeepak Kodihalli2017-06-264-9/+176
| | | | | | | Resolves openbmc/openbmc#1684. Change-Id: Ia554147001e51b05fe8692ae0b39e3efaf481130 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Remove persisted error file upon error deletionDeepak Kodihalli2017-06-261-0/+6
| | | | | Change-Id: If2418ad9350d7f3bdbfe28a00728f431f08baf9f Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Persist changes to 'Resolved' propertyDeepak Kodihalli2017-06-262-9/+21
| | | | | | | | When an error is marked resolved, serialize and persist the changed 'Resolved' property. Change-Id: I922af84cbb826e1e43a0f0c99740868222ccb1fe Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Persist error d-bus objectsDeepak Kodihalli2017-06-268-13/+198
| | | | | | | | | | | | Use Cereal to implement serialization and de-serialization of properties of error d-bus objects. Serialize and persist error d-bus objects as they are put on the bus. De-serialize and restore them (if persistent ones exist) when phosphor-log-manager starts up. Change-Id: I1f5df1abbe74bfdb86e3e82a78ff7115e90e2112 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* fix checkstop error logged as INFOMarri Devender Rao2017-06-201-1/+10
| | | | | | | | | | Fix lookup mako template to use sdbus++ error name in error level and error meta map. Resolves openbmc/openbmc#1800 Change-Id: Id3bd7d8113ad0305f25a8fc321f6b79ab5033bb0 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* elog-gen: python3 fixes for printPatrick Williams2017-06-031-3/+3
| | | | | | | In python3 print requires () wrapping around parameters. Change-Id: I830ef0d0e8c9e42c1157b708153bf96599346977 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
* Readme file for handling application specific errorsMarri Devender Rao2017-06-031-0/+52
| | | | | Change-Id: I7f19ab8a2218e826e0c7c89eee0f70de55e8a6eb Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Use sdbusplus errName instead of phosphor errName in commitMarri Devender Rao2017-06-031-1/+1
| | | | | Change-Id: I2e5e1add72ee4fa29ecb8e858b101bbd648aeeec Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Remove inheriting from sdbus exception for error metadataMarri Devender Rao2017-06-031-3/+15
| | | | | | | | | | For logging/reporting exceptions, applications need to use exceptions generated by using sdbus++. For metadata, use header file generated by elog-gen script. Change-Id: Id8f61f8692bfd694d8875359d883465c1124bedf Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Allow parsing of error yaml files without metadata yaml fileMarri Devender Rao2017-06-031-37/+49
| | | | | | | | | | | At present parser throws error if metadata yaml file is not found, modified to not to return error. Restruture the code to loop through the entries in the error yaml file rather than through the meta yaml file. Change-Id: Iaae61690201aeffd8d9caa41515b29b7cc0b59a2 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Host event error should be logged as ERR instead of INFOMarri Devender Rao2017-05-261-2/+2
| | | | | Change-Id: I34555ba7c4a61f8bd7fa423719429e8d990e2488 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* python3: iteritems does not existPatrick Williams2017-05-012-2/+2
| | | | | | | | | | Change iteritems to items, which is slightly slower on python2 but exists in both. None of the maps manipulated by this program are large enough for the items vs iteritems to be a concern. Change-Id: I63032ddde53a116431cc2cbe01828448a4d4f328 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
* elog-gen.py : strip whitespacesDeepak Kodihalli2017-04-201-1/+1
| | | | | | | | | Strip trailing and leading whitespaces from the error description. Resolves openbmc/openbmc#1481. Change-Id: Ia223ab34746e64d87dacd1f23ade7e4fc63ca9df Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Add/adjust tests for new commit and report methodsMarri Devender Rao2017-04-121-2/+8
| | | | | Change-Id: I49ac9574958f4870b04dedd91580c15825c6dd36 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Add new report interfaceMarri Devender Rao2017-04-121-0/+29
| | | | | | | | Added new report interface that creates elog entry and also commits it Change-Id: I68ebbd25561617774f498be073df4ecb627e0ef9 Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Add new commit API and deprecate older commit methodMarri Devender Rao2017-04-124-15/+69
| | | | | | | | Added new commit method that accepts an sdbusplus exception Deprecate commit which accepts an exception name Change-Id: I9b5c91eb13466eb576c329ebb7fd00ce33f7dd9f Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* entry: store parent referenceDeepak Kodihalli2017-04-112-3/+12
| | | | | | | | Have the entry object store a reference to the error manager, passed via the entry ctor. Change-Id: I2c4a8c4c95929ab7005620f44ac17e9654d8e906 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* entry: implement xyz.openbmc_project.Object.DeleteDeepak Kodihalli2017-04-112-1/+12
| | | | | | | | | Implement xyz.openbmc_project.Object.Delete to delete an entry object. Resolves openbmc/openbmc#1327. Change-Id: I265c26fb9434d0d4cb066fbfa85729782318bd8f Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* manager: define erase methodDeepak Kodihalli2017-04-102-0/+15
| | | | | | | The erase method can erase an entry object specified by id. Change-Id: I86bb2a214b8cf9b951af37f69767ff025f2f5fd0 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Entry: implement setting 'Resolved' propertyDeepak Kodihalli2017-03-311-0/+15
| | | | | | | | | | When an error is marked resolved, delete error associations, if any. When an error is marked un-resolved, re-create error associations, if there were any. Change-Id: I49acd2b6f01810e3b19e3fddbc716eb539fc20c0 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Entry: store associationsDeepak Kodihalli2017-03-311-0/+5
| | | | | | | | Store a copy of the entry object's associations, in case we need to recreate them, for example when marking an error as unresolved. Change-Id: I50001365211325505ed3a72b19a46b1438cc9731 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Entry: default 'Resolved' propertyDeepak Kodihalli2017-03-291-0/+1
| | | | | | | Set the 'Resolved' property of an error as 'false' by default. Change-Id: I0618e1f6ca2f74ce3d06aef9572becfcd78d9b60 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* build: add configure flag for metadata handlersDeepak Kodihalli2017-03-291-0/+6
| | | | | | | | | Error metadata handlers are compiled based on a specific compile flag (-DPROCESS_META), which in turn is set if a configure flag is enabled (--enable-metadata-processing). Change-Id: I77319f38cfd219bb831f9a3ee731441211e7bb9b Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Move object_mapper per dbus path conventions.Leonel Gonzalez2017-03-201-1/+1
| | | | | | | Partial fix for openbmc/openbmc#1112. Change-Id: Id01fdae36576d99d90775e4c2f6443b87c1198ee Signed-off-by: Leonel Gonzalez <lgonzalez@us.ibm.com>
* Describe a compile flagDeepak Kodihalli2017-03-161-0/+4
| | | | | | | Add a comment to describe the PROCESS_META compile flag. Change-Id: I9dc652fd2f3f7b595177112114b53a650c514772 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Fix incorrect template specializationDeepak Kodihalli2017-03-162-2/+2
| | | | | Change-Id: I15c18d8e241226b1e9fcbf9c36c703b47b488ce5 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Map sdbusplus exception to phosphor exceptionDeepak Kodihalli2017-03-154-26/+104
| | | | | | | | | | | | | Errors will be created by using the sdbusplus error types, which results in an sdbusplus exception being thrown. Error metadata can be verified at compile-time by checking the error against phosphor-logging error types. This commit maps the sdbusplus error type to the phosphor type, for this purpose, via template specializations. Change-Id: Iee37e2a3846cc3acf3a62270a520ff0c395fd36d Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* callouts: implement metadata handlerDeepak Kodihalli2017-03-154-2/+69
| | | | | | | | Implement handler of the metadata CALLOUT_DEVICE_PATH. This handler will convert a device path to an inventory path and call out the latter. Change-Id: Icbf9c841884ec139f35ea2ac94648e355b421bb2 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Update .gitignoreDeepak Kodihalli2017-03-151-0/+11
| | | | | Change-Id: I5171d013f994a3b40f8c8640d4af99d534ffcf71 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* test: add callout-testDeepak Kodihalli2017-03-157-1/+93
| | | | | | | | Add test program which can create callouts based on an input device path. It creates an error, with callouts, with name TestCallout. Change-Id: I96b66b73ae4a9c00daff06222841a13747c07408 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Make generated code to be const and externAdriana Kobylak2017-03-154-6/+22
| | | | | | | | | | | | Set generated maps to be const so that they don't get accidentally overwritten. Use .find() to access these generated data sets as the [] operator is not const. Declare the generated maps as extern so that there's no need to include the generated .cpp file. Change-Id: I4efdcace099bec738e1fa9b67decbedd515d3dfa Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
* build: add rule to generate callout mappingsDeepak Kodihalli2017-03-152-3/+13
| | | | | | | | | The callout mappings are generated at build time by a script, which needs an input YAML file. This change enables providing such a YAML file by the phosphor-logging recipe. Change-Id: I8e174d60e37eabb6d26ff7822ab5c9f38d35e0a6 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* callouts: add script to generate callout mappingsDeepak Kodihalli2017-03-152-0/+55
| | | | | | | | Add a script that can generate callout mappings. The script needs an input YAML to denote callout mappings. Add an example YAML. Change-Id: I7b49fe4c586bf7abfed2865cfd776de4d5745ef5 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* callouts: add example output YAMLDeepak Kodihalli2017-03-151-0/+1
| | | | | | | | | | YAML is of the form: <sysfs device path>: <inventory path to be called out> This will help generate code to map device paths to inventory objects. Change-Id: I5613e766d0c6b39d9b2c4a6146a747ab321555cb Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Add utility to parse error metadataDeepak Kodihalli2017-03-151-0/+21
| | | | | | | | Add method to parse out the metadata name and value from the error metadata, which is of the format "name=value". Change-Id: I7b6ba790c97faced664a11eb5806f7f87e8166a7 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* Invoke metadata handlerDeepak Kodihalli2017-03-152-0/+39
| | | | | | | | Check if error metadata fields have associated handlers, if yes, invoke them before construction the error d-bus object. Change-Id: I197385c5c43242f633274b82289cd70c85c1d6e7 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
* build: generate elog-process-metadata.cppDeepak Kodihalli2017-03-151-2/+9
| | | | | | | Add rules to generate and build elog-process-metadata.cpp. Change-Id: If9b61dfd2fbd731708e41a48428115ee40b12d6b Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
OpenPOWER on IntegriCloud