Skip to content

Commit

Permalink
Align PSU DB count field with the schema Spec. (sonic-net#509)
Browse files Browse the repository at this point in the history
Signed-off-by: Nazarii Hnydyn <nazariig@mellanox.com>
  • Loading branch information
nazariig authored and liat-grozovik committed Apr 24, 2019
1 parent 7a55329 commit fbe4ede
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion scripts/psushow
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def psu_status_show(index):
# Currently set chassis_num to 1, need to improve it once new platform API is implemented
chassis_num = 1
chassis_name = "chassis {}".format(chassis_num)
num_psus = db.get(db.STATE_DB, 'CHASSIS_INFO|{}'.format(chassis_name), 'num_psus')
num_psus = db.get(db.STATE_DB, 'CHASSIS_INFO|{}'.format(chassis_name), 'psu_num')
if not num_psus:
print "Error! Failed to get the number of PSUs!"
return -1
Expand Down
2 changes: 1 addition & 1 deletion sonic-utilities-tests/mock_tables/state_db.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"tx4power": "N/A"
},
"CHASSIS_INFO|chassis 1": {
"num_psus": "2"
"psu_num": "2"
},
"PSU_INFO|PSU 1": {
"presence": "true",
Expand Down

0 comments on commit fbe4ede

Please sign in to comment.