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

Option for removing MED policy from interface #292

Open
maloy-ghosh opened this issue Jul 12, 2018 · 3 comments
Open

Option for removing MED policy from interface #292

maloy-ghosh opened this issue Jul 12, 2018 · 3 comments

Comments

@maloy-ghosh
Copy link

maloy-ghosh commented Jul 12, 2018

From the documents http://vincentbernat.github.io/lldpd/usage.html, it is possible to configure a MED policy via

configure [ports ethX [,…]] med policy application application [unknown] [tagged] [vlan vlan] [priority priority] [dscp dscp]

This adds Network Policy TLV to LLDP packets. But is there an option to remove (unconfigure) a policy from interface?

I was trying something like this in lldpcli (built from source on 7db1168 redhat: install lldpcli as setuid _lldpd)

[lldpcli] # unconfigure ports <name> med 
2018-07-12T14:25:38 [WARN/lldpctl] incomplete command

[lldpcli] # unconfigure ports med tab does not show anything in completion.

Am I missing anything? What is the correct syntax of the unconfigure port med commands?

@vincentbernat
Copy link
Member

This hasn't been implemented. The manual page is extensive and if you don't have an unconfigure option specified, it doesn't work. You can use unconfigure med fast-start but it's not available as a per-port setting. This explains why you can go to med and not have completion after that.

I think unconfiguring a MED policy should not be very complex to do.

@maloy-ghosh
Copy link
Author

maloy-ghosh commented Jul 17, 2018

So locally I have fixed the issue by creating a command configure ports <port> med policy application <app> disabled and handled it according to other fields (like unknown/tagged etc)

Would such a change be accepted upstream? Then I can prepare a formal pull request for it.

@vincentbernat
Copy link
Member

Yes, please, open a PR. It should be pretty simple to change your patch to have unconfigure ports <port> med policy application <app> instead. If you can't figure out, open a PR either way, I'll fix that.

maloy-ghosh pushed a commit to maloy-ghosh/lldpd that referenced this issue Jul 18, 2018
Before it was possible to enable/modify network policy TLVs on a port
but it was not possible to disable them[1].

This commit introduces a new command in the form `configure ports <port>
med policy application <app> disabled` to explicitly disable an
application TLV from a port.

[1] lldpd#292
maloy-ghosh pushed a commit to maloy-ghosh/lldpd that referenced this issue Jul 18, 2018
Before it was possible to enable/modify network policy TLVs on a port
but it was not possible to disable them[1].

This commit introduces a new command in the form `configure ports <port>
med policy application <app> disabled` to explicitly disable an
application TLV from a port.

[1] lldpd#292
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants