Skip to content

Commit

Permalink
inventory: move serial console to system
Browse files Browse the repository at this point in the history
SerialConsole was deprecated in Manager v1_10_0 and has been
removed in bmcweb [1].

Because the SerialConsole values were not available anymore, the
Managers were not displayed because "setBmcInfo" couldn't find the
"SerialConsole" properties. THe following error will be logged:

```
TypeError: Cannot read properties of undefined (reading 'ConnectTypesSupported')
    at Wa.setBmcInfo (app.25e72670.js:58:745295)
    at app.25e72670.js:50:2774
    at app.25e72670.js:50:10113
    at Array.forEach (<anonymous>)
    at app.25e72670.js:50:10092
    at Wa._withCommit (app.25e72670.js:50:11953)
    at Wa.commit (app.25e72670.js:50:10066)
    at Wa.commit (app.25e72670.js:50:9518)
    at o.commit (app.25e72670.js:50:2216)
    at app.25e72670.js:58:745747
```

[1]: openbmc/bmcweb@fa800c8

Tested: BMC manager being listed in the inventory and serial console
        variables being displayed for the system.

Change-Id: I1a24178717805ca50eef2c89042c0bd9ede1d5bc
Signed-off-by: Tan Siewert <tan@siewert.io>
  • Loading branch information
sinuscosinustan committed Jan 24, 2025
1 parent a6becfe commit 223fe5b
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 17 deletions.
3 changes: 0 additions & 3 deletions src/store/modules/HardwareStatus/BmcStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ const BmcStore = {
bmc.name = data.Name;
bmc.partNumber = data.PartNumber;
bmc.powerState = data.PowerState;
bmc.serialConsoleConnectTypes = data.SerialConsole.ConnectTypesSupported;
bmc.serialConsoleEnabled = data.SerialConsole.ServiceEnabled;
bmc.serialConsoleMaxSessions = data.SerialConsole.MaxConcurrentSessions;
bmc.serialNumber = data.SerialNumber;
bmc.serviceEntryPointUuid = data.ServiceEntryPointUUID;
bmc.sparePartNumber = data.SparePartNumber;
Expand Down
3 changes: 3 additions & 0 deletions src/store/modules/HardwareStatus/SystemStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ const SystemStore = {
system.processorSummaryCoreCount = data.ProcessorSummary?.CoreCount;
system.powerState = data.PowerState;
system.serialNumber = data.SerialNumber;
system.serialConsoleEnabled = data.SerialConsole.ServiceEnabled;
system.serialConsoleMaxSessions =
data.SerialConsole.MaxConcurrentSessions;
system.healthRollup = data.Status?.HealthRollup;
system.subModel = data.SubModel;
system.statusState = data.Status?.State;
Expand Down
14 changes: 0 additions & 14 deletions src/views/HardwareStatus/Inventory/InventoryTableBmcManager.vue
Original file line number Diff line number Diff line change
Expand Up @@ -139,20 +139,6 @@
{{ dataFormatter(item.graphicalConsoleEnabled) }}
</dd>
</dl>
<!-- Serial console -->
<p class="mt-1 mb-2 h6 float-none m-0">
{{ $t('pageInventory.table.serialConsole') }}
</p>
<dl class="ml-4">
<dt>{{ $t('pageInventory.table.connectTypesSupported') }}:</dt>
<dd>
{{ dataFormatterArray(item.serialConsoleConnectTypes) }}
</dd>
<dt>{{ $t('pageInventory.table.maxConcurrentSessions') }}:</dt>
<dd>{{ dataFormatter(item.serialConsoleMaxSessions) }}</dd>
<dt>{{ $t('pageInventory.table.serviceEnabled') }}:</dt>
<dd>{{ dataFormatter(item.serialConsoleEnabled) }}</dd>
</dl>
</b-col>
</b-row>
</b-container>
Expand Down
10 changes: 10 additions & 0 deletions src/views/HardwareStatus/Inventory/InventoryTableSystem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,16 @@
<dt>{{ $t('pageInventory.table.coreCount') }}:</dt>
<dd>{{ dataFormatter(item.processorSummaryCoreCount) }}</dd>
</dl>
<!-- Serial console -->
<p class="mt-1 mb-2 h6 float-none m-0">
{{ $t('pageInventory.table.serialConsole') }}
</p>
<dl class="ml-4">
<dt>{{ $t('pageInventory.table.maxConcurrentSessions') }}:</dt>
<dd>{{ dataFormatter(item.serialConsoleMaxSessions) }}</dd>
<dt>{{ $t('pageInventory.table.serviceEnabled') }}:</dt>
<dd>{{ dataFormatter(item.serialConsoleEnabled) }}</dd>
</dl>
</b-col>
</b-row>
</b-container>
Expand Down

0 comments on commit 223fe5b

Please sign in to comment.