Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

C++ exception with description ":- cleanup_macsec_device: Cannot show MACsec ports" #743

Closed
kcudnik opened this issue Dec 14, 2020 · 1 comment · Fixed by #744
Closed
Labels

Comments

@kcudnik
Copy link
Collaborator

kcudnik commented Dec 14, 2020

Error popped out here: sonic-net/sonic-buildimage#6202

C++ exception with description ":- cleanup_macsec_device: Cannot show MACsec ports" thrown in SetUp(). this is by macsec issue

and it's related to this code:

index 8e9cdcc..b6cfe0a 100644
--- a/vslib/src/MACsecManager.cpp
+++ b/vslib/src/MACsecManager.cpp
@@ -835,7 +835,7 @@ void MACsecManager::cleanup_macsec_device() const

     std::string macsecInfos;

-    if (!exec("ip macsec show", macsecInfos))
+    if (!exec("/sbin/ip macsec show", macsecInfos))
     {

since "ip" command may not be in default user PATH, then sh/bash will not find it, resolution is to put explicit /sbin/ip path or add string variable that could be changed

exception is thrown in MACsecManager constructor when calling cleanup_macsec_device

@kcudnik kcudnik added the Bug label Dec 14, 2020
@kcudnik
Copy link
Collaborator Author

kcudnik commented Dec 14, 2020

@Pterosaur can you take a look?

jianyuewu pushed a commit to jianyuewu/sonic-sairedis that referenced this issue Feb 7, 2025
* [portstat] fix header used

Signed-off-by: Mykola Faryma <[email protected]>

* [portstat] fix print table_as_json

Signed-off-by: Mykola Faryma <[email protected]>

* Fix tx_ovr field
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant