Fix for LLDP portname exposed as MAC address bug#3152
Fix for LLDP portname exposed as MAC address bug#3152sumukhatv merged 8 commits intosonic-net:masterfrom sumukhatv:lldp_portname
Conversation
to get notifications to apply LLDP port config
Removing this since it is not serving any purpose
jleveque
left a comment
There was a problem hiding this comment.
As comments. Also, please add a few more comments in the code to briefly explain the new logic.
This is not prteset in Config DB
|
retest mellanox please |
|
retest vs please |
dockers/docker-lldp-sv2/lldpmgrd
Outdated
| log_info("Port name {} oper status: {}".format(port_name, port_oper_status)) | ||
| return port_oper_status == "up" | ||
| else: | ||
| log_error("Port name {} does not have key oper_status".format(port_name)) |
There was a problem hiding this comment.
Let's don't output any error here?
There was a problem hiding this comment.
For multiple cases we return False. Outputting an error message is the only way to find out the reason for False.
In reply to: 304107933 [](ancestors = 304107933)
There was a problem hiding this comment.
That key should always be present. I think this log message is helpful for catching unexpected circumstances.
There was a problem hiding this comment.
The key will not be presented when we creating this table.
So on sonic initialization you can catch some "errors" here.
I think it's not an error at all.
There was a problem hiding this comment.
Good point. We might see some false alarms at boot time and when reloading config. Maybe it is better to simply remove it.
dockers/docker-lldp-sv2/lldpmgrd
Outdated
|
|
||
| # handle config change | ||
| if (fvp_dict.has_key("alias") or fvp_dict.has_key("description")): | ||
| if op in ["SET", "DEL"]: |
There was a problem hiding this comment.
can we combine two ifs into one?
The permissions got changed inadverently in this PR: #3152
* Subscribe to both ConfigDB and AppDB to get notifications to apply LLDP port config * the operstate file is not consistent Removing this since it is not serving any purpose * Remove check for PortInitDone and PortConfigDone This is not prteset in Config DB * Remove checking State DB for port creation * Check for key to be present before fetching it * Addressing review comments
The permissions got changed inadverently in this PR: #3152
…lly (#19273) #### Why I did it src/sonic-swss ``` * 70eb766 - (HEAD -> master, origin/master, origin/HEAD) ADD VOQ COUNTERS(SAI_SWITCH_STAT_PACKET_INTEGRITY_DROP, SAI_QUEUE_ST…T_CREDIT_WD_DELETED_PACKETS) support for VOQ/Fabric switches (#3152) (10 hours ago) [saksarav-nokia] ``` #### How I did it #### How to verify it #### Description for the changelog
…lly (#19554) #### Why I did it src/sonic-swss ``` * d3073b7c - (HEAD -> 202405, origin/202405) [muxorch] Fixing bug with updateRoute and mux neighbors (#3187) (19 hours ago) [Nikola Dancejic] * b16d6b2a - ADD VOQ COUNTERS(SAI_SWITCH_STAT_PACKET_INTEGRITY_DROP, SAI_QUEUE_ST…T_CREDIT_WD_DELETED_PACKETS) support for VOQ/Fabric switches (#3152) (19 hours ago) [saksarav-nokia] * 12a95e57 - Revamp module build script to make it work for 5.15 on Ubuntu 20.04 (#3212) (19 hours ago) [Saikrishna Arcot] * 87cf38e0 - Fix in switchorch: unsupported attribute causes skipping of processing the rest of configurations (#3209) (19 hours ago) [Amir] * 8f333b6 - [subnet decap] Support decap rule generation based on T0 VIP route (#3183) (5 weeks ago) [Longxiang Lyu] * 9bcb9b6 - Fixing appl_db FABRIC_MONITOR notification issue. (#3176) (5 weeks ago) [jfeng-arista] * fff544e - Rotate record file before writing new log. (#3158) (5 weeks ago) [mint570] * 80f5207 - Add SWSS support for link event damping feature (#2933) (5 weeks ago) [Roy Yi] * b3ebfc4 - [muxorch] Using bulker to program routes/neighbors during switchover (#3148) (5 weeks ago) [Nikola Dancejic] ``` #### How I did it #### How to verify it #### Description for the changelog
- What I did
Fixed the LLDP portname bug
- How I did it
By subscribing to notifications from APP DB and Config DB to apply the lldp port config command
- How to verify it
We should not see portname as MAC address in the lldp messages
- Description for the changelog
Subscribe to Config DB and Application DB to get notifications to apply the LLDP port config correctly
- A picture of a cute animal (not mandatory but encouraged)