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

Cannot configure service instances via YANG on 17.2 due to wrong CLI commands #33

Open
sebageek opened this issue Jun 8, 2020 · 1 comment

Comments

@sebageek
Copy link
Collaborator

sebageek commented Jun 8, 2020

It looks like the YANG stack generates wrong CLI commands to configure a service instance on a port channel. YANG generates service-instance, CLI refuses this, probably wants service instance.

For your convenience, here is the full YANG call we're doing and the response.

Request:

<nc:rpc xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="yang-trace">
  <nc:edit-config>
    <nc:target>
      <nc:running/>
    </nc:target>
    <nc:config>
      <native xmlns="http://cisco.com/ns/yang/Cisco-IOS-XE-native">
        <bridge-domain>
          <brd-id xmlns="http://cisco.com/ns/yang/Cisco-IOS-XE-bridge-domain" operation="merge">
            <bridge-domain-id>3062</bridge-domain-id>
            <member operation="replace">
              <member-interface>
                <interface>Port-channel1</interface>
                <service-instance>3062</service-instance>
              </member-interface>
              <member-interface>
                <interface>Port-channel2</interface>
                <service-instance>3062</service-instance>
              </member-interface>
              <BD-VIF>
                <name>5565</name>
              </BD-VIF>
              <BD-VIF>
                <name>5566</name>
              </BD-VIF>
            </member>
          </brd-id>
        </bridge-domain>
      </native>
    </nc:config>
  </nc:edit-config>
</nc:rpc>

Response:

'severity': 'error', 'tag': 'invalid-value', 'path': None, 'message': 'inconsistent value: Device refused one or more commands', 'type': 'application'

<detail xmlns="http://cisco.com/yang/cisco-ia">
  <bad-cli>
    <bad-command> member Port-channel1 service-instance 3062</bad-command>
    <error-location>2</error-location>
    <parser-response/>
    <parser-context>bridge-domain 3062
 member Port-channel1 service-instance 3062</parser-context>
  </bad-cli>
  <bad-cli>
    <bad-command> member Port-channel2 service-instance 3062</bad-command>
    <error-location>2</error-location>
    <parser-response/>
    <parser-context>bridge-domain 3062
 member Port-channel1 service-instance 3062
 member Port-channel2 service-instance 3062</parser-context>
  </bad-cli>
  <bad-cli>
    <bad-command> member BD-VIF5565</bad-command>
    <error-location>2</error-location>
    <parser-response/>
    <parser-context>bridge-domain 3062
 member Port-channel1 service-instance 3062
 member Port-channel2 service-instance 3062
 member BD-VIF5565</parser-context>
  </bad-cli>
  <bad-cli>
    <bad-command> member BD-VIF5566</bad-command>
    <error-location>2</error-location>
    <parser-response/>
    <parser-context>bridge-domain 3062
 member Port-channel1 service-instance 3062
 member Port-channel2 service-instance 3062
 member BD-VIF5565
 member BD-VIF5566</parser-context>
  </bad-cli>
</detail>
</error-info>

Version in use:

qa-de-1-asr13a#show ver
Cisco IOS XE Software, Version V172_1_SAP_ES2
Cisco IOS Software [Amsterdam], c8000aep Software (X86_64_LINUX_IOSD-UNIVERSALK9-M), Version 17.2.1-SAP, CUST-SPECIAL:V172_1_SAP_ES2
This software is supported for a limited time under special agreement with Cisco Systems, Inc. ES2
Copyright (c) 1986-2020 by Cisco Systems, Inc.
Compiled Thu 07-May-20 16:39 by mcpre
@sebageek
Copy link
Collaborator Author

sebageek commented Jul 6, 2020

Cisco advised us not to use <service-instance>, as it is only present for backwardscompability, but to use <service-instance-list><service-instance>{id}</service-instance></service-instance-list> for each entry. The same goes for #28. Will try out.

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

No branches or pull requests

1 participant