Following this forum post, I was attempting to simulate link failures using
sudo mlxlink -p 1 -d mlx5_0 --port_state DN
However, in the mlxlink documentation, I saw this note:
Do not use mlxlink to disable the port connecting between the host and the unmanaged switch using (“–port_state dn”) flag.
Why does this command even exist then? What is the reason for this warning? Is it simply to deter users from running a command that would prevent traffic from being sent/received? Or would toggling the port state repeatedly potentially cause some other issues e.g., damaging hardware or resulting in NIC or cable failures?
Hello Blues,
You can run the command below on the target server.
sudo mlxlink -p 1 -d mlx5_0 --port_state DN
However, in most cases, you manage the server remotely, similar to the following:
sudo mlxlink -p 1 -d lid-LID --port_state DN
LID refers to the LID of the target server.
However, you are not allowed to do this because you would be locked out if you did so.
Thanks,
Yuying
1 Like
Hi Yuying,
Thank you so much for your reply. So, just to clarify, as long as I do not do --port_state DN
on the NIC I am using to SSH into a server, it is fine to run this command: sudo mlxlink -p 1 -d mlx5_0 --port_state DN
?
Hi Blues,
Sure. Please feel safe to do that.
Thanks,
Yuying
1 Like
Amazing, thank you so much! Happy New Year!