History log of /openbmc/phosphor-debug-collector/dump_manager_bmc.cpp (Results 1 – 25 of 27)
Revision Date Author Comments
# 4207adcd 01-Feb-2025 Patrick Williams <patrick@stwcx.xyz>

clang-format: update latest spec and reformat

Copy the latest format file from the docs repository and apply.

Change-Id: I88079e69decd57b30d0455a723fd051be8449e36
Signed-off-by: Patrick Williams <p

clang-format: update latest spec and reformat

Copy the latest format file from the docs repository and apply.

Change-Id: I88079e69decd57b30d0455a723fd051be8449e36
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# 418d460a 25-Nov-2024 Jayanth Othayoth <ojayanth@gmail.com>

clang-tidy: Enable bugprone-unchecked-optional

Modified code to address issues flagged by
bugprone-unchecked-optional-access check.

Tested: Build and unit tests passed successfully.

Change-Id: Icd

clang-tidy: Enable bugprone-unchecked-optional

Modified code to address issues flagged by
bugprone-unchecked-optional-access check.

Tested: Build and unit tests passed successfully.

Change-Id: Icd445afaf827f7c346e44dfe3ce9ba98374e176a
Signed-off-by: Jayanth Othayoth <ojayanth@gmail.com>

show more ...


# 17ba876c 25-Nov-2024 Jayanth Othayoth <ojayanth@gmail.com>

clang-tidy: Enable bugprone-narrowing-conversions

Modified code to address issues flagged by this check.

Tested: Build and unit tests passed successfully.

Change-Id: Idd5e3701725a833324535d29f0bff

clang-tidy: Enable bugprone-narrowing-conversions

Modified code to address issues flagged by this check.

Tested: Build and unit tests passed successfully.

Change-Id: Idd5e3701725a833324535d29f0bfffb3ba180e88
Signed-off-by: Jayanth Othayoth <ojayanth@gmail.com>

show more ...


# 973b291e 16-Aug-2024 Patrick Williams <patrick@stwcx.xyz>

clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version. The way clang-18
handles lambda forma

clang-format: re-format for clang-18

clang-format-18 isn't compatible with the clang-format-17 output, so we
need to reformat the code with the latest version. The way clang-18
handles lambda formatting also changed, so we have made changes to the
organization default style format to better handle lambda formatting.

See I5e08687e696dd240402a2780158664b7113def0e for updated style.
See Iea0776aaa7edd483fa395e23de25ebf5a6288f71 for clang-18 enablement.

Change-Id: I748aeef75e2078199193cd98013dd2fe7f6b5db8
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# 93f06410 02-Jun-2024 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Add Serialization Support for Dump Entry Attributes

Implemented serialization of dump entry attributes using the
nlohmann::json library. Added serialization support in the Dump Entry
class, serializ

Add Serialization Support for Dump Entry Attributes

Implemented serialization of dump entry attributes using the
nlohmann::json library. Added serialization support in the Dump Entry
class, serializing attributes including originatorId, originatorType,
and startTime. These attributes are not part of the dump filename and
thus require serialization to ensure their state is preserved.

Deserialization will occur only if the serialization version matches
and the dump ID in the dump object matches the ID in the
serialized file.

Tests:
- Created BMC dumps and restarted service
- Created BMC dumps and restarted BMC
- Created 200 BMC dumps and restarted service and BMC multiple times

File:
```
{"dumpId":2,"originatorId":"","originatorType":1,"startTime":1718199238942411,"version":1}
```

Change-Id: I16ecb058bddd464c8771bd8d08a50ea1877747ed
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

show more ...


# e70edac3 20-Oct-2023 Patrick Williams <patrick@stwcx.xyz>

clang-format: copy latest and re-format

clang-format-17 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest

clang-format: copy latest and re-format

clang-format-17 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest .clang-format from the docs repository and reformat the
repository.

Change-Id: I04f38c33863fd3e2c9c6e9e20efc14105b79aedd
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# 1615b824 31-May-2023 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Remove internal dump create interface

The createDump method was revised to support key-value parameters,
allowing flexible dump type specification. This change negates the need
for the internal crea

Remove internal dump create interface

The createDump method was revised to support key-value parameters,
allowing flexible dump type specification. This change negates the need
for the internal create interface, exclusive to the
phosphor-debug-collector repository.

This commit removes all instances of the internal create method,
replacing them with the updated createDump method. The modified
createDump approach ensures a consistent dump initiation procedure
and enables all applications to request various dump types.

Manual Tests:
- Validate the creation of a user-requested BMC dump.
- Validate the creation of a dump due to an InternalFailure.
- Generate a core dump to validate the corresponding BMC dump creation.
- Ensure that system-generated dumps are allowed when user-requested
dump is in progress.
- Ensure simultaneous user requested dumps are prevented

Checkstop dump
busctl call xyz.openbmc_project.Logging /xyz/openbmc_project/logging \
xyz.openbmc_project.Logging.Create Create ssa{ss} \
org.open_power.Host.Boot.Error.Checkstop \
xyz.openbmc_project.Logging.Entry.Level.Error 0

Logs:
Initiating new BMC dump with type: checkstop path: /xyz/openbmc_\
project/logging/entry/78
performing dump compression /tmp/BMCDUMP.XX.0000003.20230724015349
Report is available in /var/lib/phosphor-debug-collector/dumps/3

Automated tests:
Create_And_Delete_User_Initiated_BMC_Dump_Multiple_Times
Create_Two_User_Initiated_BMC_Dumps
Create_Two_User_Initiated_BMC_Dumps_And_Delete_One
Delete_All_User_Initiated_BMC_Dumps_And_Verify
Delete_User_Initiated_BMC_Dump_And_Verify
Verify_BMC_Core_Dump_When_Host_Powered_Off
Verify_BMC_Dump_Create_Errors_While_Another_BMC_Dump_In_Progress
Verify_BMC_Dump_Default_Location_In_BMC
Verify_Core_Dump_Size
Verify_Core_Watchdog_Initiated_BMC_Dump
Verify_Dump_Persistency_On_BMC_Reset
Verify_Dump_Persistency_On_Dump_Service_Restart
Verify_Error_Log_And_Dump_For_Internal_Failure
Verify_Error_Response_For_Already_Deleted_Dump_Id
Verify_Error_While_Initiating_BMC_Dump_During_Dumping_State
Verify_Internal_Failure_Initiated_BMC_Dump_Size
Verify_Multiple_BMC_Dump_Creation
Verify_User_Initiated_BMC_Dump_At_Host_Booting
Verify_User_Initiated_BMC_Dump_Size
Verify_User_Initiated_BMC_Dump_When_Host_Booted
Verify_User_Initiated_BMC_Dump_When_Host_Powered_Off

Built with master and p10bmc

Change-Id: I9f91375788201e2badf51d87f8117154a8e1ed8a
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

show more ...


# e4350f93 29-Jun-2023 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Add elog dump type to common create

This commit modifies the Elog BMC dump creation process to utilize the
common BMC dump creation interface. Elog BMC dumps are a special type
of dumps triggered up

Add elog dump type to common create

This commit modifies the Elog BMC dump creation process to utilize the
common BMC dump creation interface. Elog BMC dumps are a special type
of dumps triggered upon the logging of certain predefined set of error
logs. These dumps incorporate data based on the type of the error log.
In the existing process, upon occurrence of a predefined error log, the
error log watch function would inform the dump manager via an internal
DBus interface. Now, with this change, the error log watch function will
request the dump manager to create an Elog BMC dump that includes the
relevant error data, error type, and the object path of the error log
entry via the common create DBus interface.

Test:
Create an InternalFailure and make sure dump is created
>busctl call xyz.openbmc_project.Logging \
/xyz/openbmc_project/logging \
xyz.openbmc_project.Logging.Create Create ssa{ss} \
xyz.openbmc_project.Common.Error.InternalFailure \
xyz.openbmc_project.Logging.Entry.Level.Error 0

Trace:
phosphor-dump-manager[542]: Initiating new BMC dump \
with type: elog path: /xyz/openbmc_project/logging/entry/12

phosphor-dump-manager[2918]: Report is available in \
/var/lib/phosphor-debug-collector/dumps/6

Tested checkstop dump

Built with master and p10bmc

Change-Id: I734b052fc24e7893a61755790be49e8a1e594be5
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

show more ...


# 3604710d 29-Jun-2023 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

BMCDump: dump subtype input parameter support

The BMC dump is not accepting any parameters to specify the type of
dump or level of data to be collected. It was always creating a default
user-request

BMCDump: dump subtype input parameter support

The BMC dump is not accepting any parameters to specify the type of
dump or level of data to be collected. It was always creating a default
user-requested dump.

This commit allows for the specification of the dump type during the
dump creation process. A new table has been added in a new header file
which stores the valid dump types. When a new dump is requested, the
specified dump type is verified against this table. If no dump type is
mentioned, a user-requested BMC dump is created for backward
compatibility. If an invalid dump type is mentioned, an Invalid
Argument exception is thrown.

Tested:
- Create BMC dump with no arguments
- Create BMC dump with type as user
- Create a error log dump and make sure other types of dumps
which is using internal interface is not impacted.
- Built with master and p10bmc

Change-Id: I79f68be6ac6892ac7754b7221db64c22330b1822
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

show more ...


# d1f670fe 05-Jun-2023 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Implementing Phosphor-Logging/LG2 logging

This commit introduces changes in the phosphor-debug-collector
repository to implement structured logging using the LG2
framework. The existing log calls in

Implementing Phosphor-Logging/LG2 logging

This commit introduces changes in the phosphor-debug-collector
repository to implement structured logging using the LG2
framework. The existing log calls in the repository,
have been replaced with LG2 logging, facilitates better
log tracking and troubleshooting by offering improved
detail in JSON object values.

Test:
- Created BMC dump
- Created system dump

Here is a example
{
"_EXE" : "/tmp/phosphor-dump-manager",
"_MACHINE_ID" : "f9ca96d99c7b4ba688556f632ffeff5d",
"_CAP_EFFECTIVE" : "1ffffffffff",
"LOG2_FMTMSG" : "Invalid Dump file name, FILENAME: {FILENAME}",
"__CURSOR" : "s=721ae7a5b6ed43ec904f2bb03e3c0403;i=2a8d0;\
b=b372b9a5989e46bb8e62b33310e181ea;m=2c05fda2b;t=5fdf0684c1e70;x=1592f60584d6486c",
"CODE_FUNC" : "void phosphor::dump::bmc::Manager::\
createEntry(const std::filesystem::__cxx11::path&)",
"_SYSTEMD_SLICE" : "system-dropbear.slice",
"CODE_LINE" : "174",
"__REALTIME_TIMESTAMP" : "1686583867350640",
"PRIORITY" : "3",
"_SYSTEMD_UNIT" : "dropbear@1-9.3.29.238:22-9.3.84.138:45432.service",
"_PID" : "16209",
"_BOOT_ID" : "b372b9a5989e46bb8e62b33310e181ea",
"_SOURCE_REALTIME_TIMESTAMP" : "1686583867350580",
"_TRANSPORT" : "journal",
"_HOSTNAME" : "openbmc",
"SYSLOG_IDENTIFIER" : "phosphor-dump-manager",
"MESSAGE" : "Invalid Dump file name, \
FILENAME: BMCDUMP.XXXXXXX.0000006.20230612153010",
"CODE_FILE" : \
"/usr/src/debug/phosphor-debug-collector/1.0+gitAUTOINC+a17f1c92ce-r1\
/dump_manager_bmc.cpp",
"_UID" : "0",
"_CMDLINE" : "/tmp/phosphor-dump-manager",
"_RUNTIME_SCOPE" : "system",
"FILENAME" : "BMCDUMP.XXXXXXXX.0000006.20230612153010",
"_SYSTEMD_INVOCATION_ID" : "64a11629aade4c96ab62154cbc4be8b7",
"__MONOTONIC_TIMESTAMP" : "11817441835",
"_SYSTEMD_CGROUP" : "/system.slice/system-dropbear.slice/\
dropbear@1-9.3.29.238:22-9.3.84.138:45432.service",
"_COMM" : "phosphor-dump-m",
"_GID" : "0"
}

Change-Id: I3a52b812b059b64d945493de2e2cc68a43f6d72a
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

show more ...


# 78e88402 10-May-2023 Patrick Williams <patrick@stwcx.xyz>

clang-format: copy latest and re-format

clang-format-16 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest

clang-format: copy latest and re-format

clang-format-16 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest .clang-format from the docs repository and reformat the
repository.

Change-Id: If4790d4928efc3e6690ca090aa79f0c7737c3683
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>

show more ...


# 3ed02c32 28-Jun-2022 Marri Devender Rao <devenrao@in.ibm.com>

sdevent:inode entry is not released after creating dump

For every dump generated an "anon_inode:[pidfd]" entry is
created for the associated process and the same is not
released.

When the number of

sdevent:inode entry is not released after creating dump

For every dump generated an "anon_inode:[pidfd]" entry is
created for the associated process and the same is not
released.

When the number of inode entries reach the maximum count
dump request will fail and the dump service takes a reset
with a core dump.

When a dump is requested a child process is spawned to
perform dump collection, parent process waits on the
child process completion using sd-event-add-child
systemd call.

sd-event-add-child adds an inode entry which needs to
be released during the callback method called after
child process exit using unref but the same is not done.

Now switching to sdeventplus::source::Child wrapper class for
sd-event-add-child which takes care of releasing the inode fd.

Tested:
'''
Without the fix for the 3 dumps created noticed 3 anon_inode:[pidfd]
are added but not cleared
root@rain135bmc:/proc/2044/fd# ls -la
dr-x------ 2 root root 0 Jun 27 08:38 .
dr-xr-xr-x 8 root root 0 Jun 27 08:38 ..
lr-x------ 1 root root 64 Jun 27 08:39 0 -> /dev/null
lrwx------ 1 root root 64 Jun 27 08:39 1 -> socket:[21586]
lrwx------ 1 root root 64 Jun 27 08:39 10 ->anon_inode:[timerfd]
lrwx------ 1 root root 64 Jun 27 08:47 11 ->anon_inode:[pidfd]
lrwx------ 1 root root 64 Jun 27 08:47 12 ->anon_inode:[pidfd]
lrwx------ 1 root root 64 Jun 27 08:47 13 ->anon_inode:[pidfd]

After the fix noticed all the anon_inode:[pidfd] are cleared
dr-x------ 2 root root 0 Jun 27 08:38 .
dr-xr-xr-x 8 root root 0 Jun 27 08:38 ..
lr-x------ 1 root root 64 Jun 27 08:39 0 -> /dev/null
lrwx------ 1 root root 64 Jun 27 08:39 1 -> socket:[21586]
lrwx------ 1 root root 64 Jun 27 08:39 10 ->anon_inode:[timerfd]
'''

Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
Change-Id: I9a2fec0a2287bfe978b811671c1cfeb1356e59d2

show more ...


# 73953b8f 15-Feb-2022 Marri Devender Rao <devenrao@in.ibm.com>

bmcdump: ignore dump request when a dump is in progress

At present generating a user dump is an asynchronous call
and does not block the user to generate another dump.

This can cause out-of-memory

bmcdump: ignore dump request when a dump is in progress

At present generating a user dump is an asynchronous call
and does not block the user to generate another dump.

This can cause out-of-memory issues if dumps are
generated in a loop.

Adding a check to see if the user-initiated dump is
already in progress before starting another user
dump request.

Return "Unavailable" error if generate user dump request is
received while a user dump generation is in progress.

Tested:
'''
root@p10bmc:~# busctl --verbose call xyz.openbmc_project.Dump.Manager
/xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
MESSAGE "o" {
OBJECT_PATH "/xyz/openbmc_project/dump/bmc/entry/3";
};

root@p10bmc:~# busctl --verbose call xyz.openbmc_project.Dump.Manager
/xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
Call failed: The operation is not allowed
root@p10bmc:~# busctl --verbose call xyz.openbmc_project.Dump.Manager
/xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
Call failed: The operation is not allowed
root@p10bmc:~# busctl --verbose call xyz.openbmc_project.Dump.Manager
/xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
MESSAGE "o" {
OBJECT_PATH "/xyz/openbmc_project/dump/bmc/entry/4";
};

'''

Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
Change-Id: Ic9434f34c040405f8664f7dc71109e7cb67a80c2

show more ...


# 4cb0799f 09-May-2022 Chirag Sharma <chirshar@in.ibm.com>

dump: failure as open file handles are not closed

Dump manager adds watch using inotify_add_watch when
dump generation starts and closes the fd(file handle)
returned by the inotify_add_watch after d

dump: failure as open file handles are not closed

Dump manager adds watch using inotify_add_watch when
dump generation starts and closes the fd(file handle)
returned by the inotify_add_watch after dump generation
is completed.

Due to logic error, the fd is not closed, due to that
the application exhausts the fd count over time when a
lot of dumps are generated and it fails eventually.

The dump manager maintains stl::map of the path and watch
objects for newly created dumps so that when dump generation
is completed it can create D-Bus objects for the dumps.

When adding new entry to the stl::map dump directory is passed
and when clearing the entry the file path of dump file is pased
due to this entry from stl::map is not cleard and so is the
watch object.

Tested:
Post changes able to trigger 200+ dumps without any issue.

Verfied the open fd for the dump manager process before and after
dump genration and ensured that fd's are not incread.

before dump generation
root@p10bmc:~# ls -la /proc/4890/fd
dr-x------ 2 root root 0 Jan 20 10:03 .
dr-xr-xr-x 8 root root 0 Jan 20 10:03 ..
lr-x------ 1 root root 64 Jan 20 10:04 0 -> /dev/null
lrwx------ 1 root root 64 Jan 20 10:04 1 -> socket:[35868]
lrwx------ 1 root root 64 Jan 20 10:04 2 -> socket:[35868]
lrwx------ 1 root root 64 Jan 20 10:03 3 -> socket:[35873]
lrwx------ 1 root root 64 Jan 20 10:04 4 ->
anon_inode:[eventpoll]
lr-x------ 1 root root 64 Jan 20 10:04 5 -> anon_inode:inotify
lrwx------ 1 root root 64 Jan 20 10:04 6 ->
anon_inode:[timerfd]

after dump generation
root@p10bmc:~# ls -la /proc/4890/fd
dr-x------ 2 root root 0 Jan 20 10:03 .
dr-xr-xr-x 8 root root 0 Jan 20 10:03 ..
lr-x------ 1 root root 64 Jan 20 10:04 0 -> /dev/null
lrwx------ 1 root root 64 Jan 20 10:04 1 -> socket:[35868]
lrwx------ 1 root root 64 Jan 20 10:04 2 -> socket:[35868]
lrwx------ 1 root root 64 Jan 20 10:03 3 -> socket:[35873]
lrwx------ 1 root root 64 Jan 20 10:04 4 ->
anon_inode:[eventpoll]
lr-x------ 1 root root 64 Jan 20 10:04 5 -> anon_inode:inotify
lrwx------ 1 root root 64 Jan 20 10:04 6 ->
anon_inode:[timerfd]
lrwx------ 1 root root 64 Jan 20 10:05 7 -> socket:[35916]

Signed-off-by: Chirag Sharma <chirshar@in.ibm.com>
Change-Id: I67c704719e9991fdff478891f9dc72045fb0e9e1

show more ...


# 74a1f39c 27-Oct-2021 Asmitha Karunanithi <asmitk01@in.ibm.com>

Implement OriginatedBy interface in dump entry dbus obj

This new interface "OriginatedBy" will be implemented
by all the dump entry dbus objects. It contains a property
"OriginatorId" which stores t

Implement OriginatedBy interface in dump entry dbus obj

This new interface "OriginatedBy" will be implemented
by all the dump entry dbus objects. It contains a property
"OriginatorId" which stores the unique id of the user that
has initiated the dump. The unique id in this case is a string
that contains the ip address of the client that initiated
the dump.

The dbus interface change for the same is at:
[1] https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-dbus-interfaces/+/47057

Tested By:

[1] busctl call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 2 "xyz.openbmc_project.Dump.Create.CreateParameters.OriginatorId" s "<unique-id>" "xyz.openbmc_project.Dump.Create.CreateParameters.OriginatorType" s "xyz.openbmc_project.Common.OriginatedBy.OriginatorTypes.Client" o "/xyz/openbmc_project/dump/bmc/entry/2"

[2] busctl --verbose call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/resource xyz.openbmc_project.Dump.Create CreateDump a{sv} 4 "com.ibm.Dump.Create.CreateParameters.VSPString" s "vsp" "com.ibm.Dump.Create.CreateParameters.Password" s "password" "com.ibm.Dump.Create.CreateParameters.OriginatorId" s "<unique-id>" "xyz.openbmc_project.Dump.Create.CreateParameters.OriginatorType" s "xyz.openbmc_project.Common.OriginatedBy.OriginatorTypes.Client"
MESSAGE "o" {
OBJECT_PATH "/xyz/openbmc_project/dump/resource/entry/1";
};

[3] busctl call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/system xyz.openbmc_project.Dump.Create CreateDump a{sv} 2 "com.ibm.Dump.Create.CreateParameters.OriginatorId" s "<unique-id>" "xyz.openbmc_project.Dump.Create.CreateParameters.OriginatorType" s "xyz.openbmc_project.Common.OriginatedBy.OriginatorTypes.Client" o "/xyz/openbmc_project/dump/system/entry/1"

Signed-off-by: Asmitha Karunanithi <asmitk01@in.ibm.com>
Change-Id: I23c9f769fd39cd84e042d6effbb3d71c7af4e889

show more ...


# c0ab9d43 18-Aug-2022 Claire Weinan <cweinan@google.com>

Populate timestamps with microsecond precision

xyz.openbmc_project.Time.EpochTime is defined as time elapsed since the
epoch in microseconds.

xyz.openbmc_project.Common.Progress.StartTime and
xyz.o

Populate timestamps with microsecond precision

xyz.openbmc_project.Time.EpochTime is defined as time elapsed since the
epoch in microseconds.

xyz.openbmc_project.Common.Progress.StartTime and
xyz.openbmc_project.Common.Progress.CompletedTime are similarly
defined as microseconds.

Change timestamps that are currently captured in seconds to
microseconds.

Tested:

Check xyz.openbmc_project.Time.EpochTime,
xyz.openbmc_project.Common.Progress.StartTime, and
xyz.openbmc_project.Common.Progress.CompletedTime timestamps of dump
entries.

Example:
busctl introspect xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/bmc/entry/1

Signed-off-by: Claire Weinan <cweinan@google.com>
Change-Id: I6ea220af07f06ad79de0b62b24ce6cd5ba5fd33d

show more ...


# fc69f35c 17-May-2022 Xie Ning <xiening.xll@bytedance.com>

Add rotate support if the space is full

delete the first existing file if the space is not enough

Tested:
1. create dump and make the space is not enough
busctl call xyz.openbmc_project.Dump.Manage

Add rotate support if the space is full

delete the first existing file if the space is not enough

Tested:
1. create dump and make the space is not enough
busctl call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
busctl tree xyz.openbmc_project.Dump.Manager `-/xyz
`-/xyz/openbmc_project
`-/xyz/openbmc_project/dump
|-/xyz/openbmc_project/dump/bmc
| `-/xyz/openbmc_project/dump/bmc/entry
| |-/xyz/openbmc_project/dump/bmc/entry/10
| |-/xyz/openbmc_project/dump/bmc/entry/6
| |-/xyz/openbmc_project/dump/bmc/entry/7
| |-/xyz/openbmc_project/dump/bmc/entry/8
| `-/xyz/openbmc_project/dump/bmc/entry/9
`-/xyz/openbmc_project/dump/internal
`-/xyz/openbmc_project/dump/internal/manager

2. create dump again and the the first existing file will be deleted

Signed-off-by: Xie Ning <xiening.xll@bytedance.com>
Change-Id: Ic3b376d7e6512a264f849de760363f4e167421c7

show more ...


# 56bd797e 25-Feb-2022 Xie Ning <xiening.xll@bytedance.com>

Fix the invalid value of Elapsed property

The Elapsed property is described in microseconds in the interface but the result value is in seconds before

Tested:
1. get the property by this: busctl in

Fix the invalid value of Elapsed property

The Elapsed property is described in microseconds in the interface but the result value is in seconds before

Tested:
1. get the property by this: busctl introspect xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/bm:c/entry/20 xyz.openbmc_project.Time.EpochTime
2. check the value
NAME TYPE SIGNATURE RESULT/VALUE FLAGS
.Elapsed property t 1645758497000000 emits-change writable

Change-Id: Ib6cd5261c4cd6ac7de239f291a9f5fb556b29e89
Signed-off-by: Xie Ning <xiening.xll@bytedance.com>

show more ...


# ddc3366e 19-Jul-2021 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Update dump create parameters

Dump create parameters are a set of parameters accepted
in dict format while creating the dump. So far the values
can be only strings but now unit64 also added. This co

Update dump create parameters

Dump create parameters are a set of parameters accepted
in dict format while creating the dump. So far the values
can be only strings but now unit64 also added. This commit
address the changes to handle the updated dictionary

Testing:
- Full build with interface change is successful
- Created dumps with new interface
Resource Dump:
busctl --verbose call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/resource xyz.openbmc_project.Dump.Create CreateDump a{sv} 2 "com.ibm.Dump.Create.CreateParameters.VSPString" s "vsp" "com.ibm.Dump.Create.CreateParameters.Password" s "0"
MESSAGE "o" {
OBJECT_PATH "/xyz/openbmc_project/dump/resource/entry/1";
};

BMC Dump:
busctl --verbose call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/bmc xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
MESSAGE "o" {
OBJECT_PATH "/xyz/openbmc_project/dump/bmc/entry/92";
};

System Dump:
busctl --verbose call xyz.openbmc_project.Dump.Manager /xyz/openbmc_project/dump/system xyz.openbmc_project.Dump.Create CreateDump a{sv} 0
MESSAGE "o" {
OBJECT_PATH "/xyz/openbmc_project/dump/system/entry/1";
};

Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
Change-Id: I37ab7d870954e1b52500f5975735286433fbb8df

show more ...


# 858fbb2e 30-Jun-2021 George Liu <liuxiwei@inspur.com>

Add fmtlib for phosphor-debug-collector

Call fmtlib to get additional information from journal.

Tested: built phosphor-debug-collector successfully
and Unit Test passes.

Signed-off-by: Geo

Add fmtlib for phosphor-debug-collector

Call fmtlib to get additional information from journal.

Tested: built phosphor-debug-collector successfully
and Unit Test passes.

Signed-off-by: George Liu <liuxiwei@inspur.com>
Change-Id: Ibe65637a0b29b76269fb4bc3f498438901c9306a

show more ...


# bb9366d0 24-Jun-2021 Tim Lee <timlee660101@gmail.com>

Adjust current size of total dump files in dump directory

Symptom:
"Verify Maximum BMC Dump Creation" test item got failed sometimes.
This test item expect that dump space is enough to create a new

Adjust current size of total dump files in dump directory

Symptom:
"Verify Maximum BMC Dump Creation" test item got failed sometimes.
This test item expect that dump space is enough to create a new BMC dump file.
But, dump manager doesn't think dump space is enough to create
according to current size of dump directory.

Root cause:
dump manager is using std::filesystem::file_size to calculate total size of
dump log files in dump directory. Then total size is divided by 1024
convert to KB. However, test item is using linux command "du -s" to calculate
total size of dump log files in dump directory.
The calculation result is different between dump manager and test item
then cause test got failed sometimes.

Solution:
calculate each dump file with std::ceil() and convert size to KB then
calculate total dump files size in dump directory. That's can reduce size
difference of total dump files between dump manager
and test item then avoid this test got failed.

Tested:
Run 3~4 times robot
Verify_Maximum_BMC_Dump_Creation redfish/managers/test_bmc_dumps.robot
Verify Maximum BMC Dump Creation :: Create maximum BMC dump and ve... | PASS |
1 critical test, 1 passed, 0 failed
1 test total, 1 passed, 0 failed

Signed-off-by: Tim Lee <timlee660101@gmail.com>
Change-Id: Ic1a6d941d12516678ff21789355941653d319858

show more ...


# 0af74a5e 08-Apr-2021 Jayanth Othayoth <ojayanth@in.ibm.com>

Update clang-format

Update to the latest OpenBMC clang-format.

Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>
Change-Id: I54010d3c756af4c85786285644038d449730612b


# 3fc6df48 08-Apr-2021 Jayanth Othayoth <ojayanth@in.ibm.com>

c++17: drop experimental::filesystem

Use the real filesystem library, and drop support for building with
experimental under c++14.

Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>
Change-Id: I

c++17: drop experimental::filesystem

Use the real filesystem library, and drop support for building with
experimental under c++14.

Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>
Change-Id: I730c0d6dce53b5e0aa0867cddb7f325cdb9b45fc

show more ...


# 969f9a59 30-Oct-2020 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Update createDump to accept additional parameters

Updating create dump implementation to match the change
in the interface to accept the additional parameters.

Testing:
Created BMC dump
Creat

Update createDump to accept additional parameters

Updating create dump implementation to match the change
in the interface to accept the additional parameters.

Testing:
Created BMC dump
Created system dump

Dbus changes associated with this:
https://gerrit.openbmc-project.xyz/c/openbmc/phosphor-dbus-interfaces/+/37355

Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
Change-Id: I1402a9c4c8e0e5c6277055d835f7d024673831d8

show more ...


# a6ab806d 29-Oct-2020 Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>

Progress tracking support for dump entries.

A new attribute status is added which indicates the status of the
dump creation. The user requested dump entries will be created
with InProgress and updat

Progress tracking support for dump entries.

A new attribute status is added which indicates the status of the
dump creation. The user requested dump entries will be created
with InProgress and updated to Completed once the dump creation
is completed

Test: Request user initiated BMC and system dump and
make sure the progress is changing and the dump details
are updated correctly

Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj@in.ibm.com>
Change-Id: I68e25c865765dff97913af00bf89c8c3a4b65d43

show more ...


12