2

Does anyone know why I cannot call Restful API provided by OpenDaylight, even I have installed RESTCONF, l2switch, md-sal modules. My responses from dlux are alwyas like this:

Data-missing : Request could not be completed because the relevant data model content does not exist. - : Request could not be completed because the relevant data model content does not existenter image description here

How can I complete this "relevant data model"?? I am sure that I have installed md-sal & restconf-all & l2switch-all modules, so what else I still need? I use Carbon distribution. Thank you all!! YC

2 Answers2

1

I suspect you're sending an invalid REST request, trying to access data that doesn't exist.

There are example REST requests in the NetVirt Postman Collections.

dfarrell07
  • 2,872
  • 2
  • 21
  • 26
0

Ensure your RESCONF flow explicitly contains an Ethertype and IP Protocol.

For example:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<flow xmlns="urn:opendaylight:flow:inventory">
    <instructions>
        <instruction>
            <order>0</order>
            <go-to-table>
                <table_id>1</table_id>
            </go-to-table>
        </instruction>
    </instructions>
    <table_id>0</table_id>
    <id>256</id>
    <match>
        <ethernet-match>
            <ethernet-type>
                <type>2048</type>
            </ethernet-type>
        </ethernet-match>
        <ipv4-source>192.168.11.0/24</ipv4-source>
        <ipv4-destination>192.168.11.0/24</ipv4-destination>
        <ip-match>
            <ip-protocol>6</ip-protocol>         
        </ip-match>
        <in-port>0</in-port>
    </match>   
    <hard-timeout>0</hard-timeout>
    <cookie>10</cookie>
    <idle-timeout>0</idle-timeout>
    <flow-name>flow-instruction-go-to-table</flow-name>
    <priority>200</priority>
</flow>

Be sure to change the instruction and ipv4 address stanzas to match your flow.

John Sobanski
  • 147
  • 1
  • 11