Just want to clarify that OFP project only provides operational topology:  
/restconf/operational/network-topology:network-topology/topology/flow:1 that 
BTW cannot be modified by user because this is discovered using LLDP packets as 
described in the docs. I am not sure what is the purpose of reading/writting in 
the config topology: 
/restconf/configuration/network-topology:network-topology/topology/flow:1, but 
whatever it is, it is not implemented in ODL.

BR/Luis


> On Jul 23, 2020, at 10:27 AM, Tejas Nevrekar <tejas.nevre...@gmail.com> wrote:
> 
> Hi Carlos,
> 
> Note that the topology is always discovered from mininet and hence will 
> always be in /restconf/operational. More details on how this works is 
> https://docs.opendaylight.org/projects/openflowplugin/en/latest/users/operation.html
>  
> <https://docs.opendaylight.org/projects/openflowplugin/en/latest/users/operation.html>
> 
> Quick answer is there is no easy way by which you can update what's in 
> /restconf/operational by writing to /restconf/config/....
> 
> However, you can write to the 
> /restconf/config/network-topology:network-topology/topology/flow:1 by 
> constructing the full payload containing nodes/links. A simple way to do that 
> is to do a GET  
> /restconf/operational/network-topology:network-topology/topology/flow:1 and 
> provide the output of that in a PUT to  
> /restconf/config/network-topology:network-topology/topology/flow:1.
> 
> Please let us know if this helped.
> 
> Regards,
> 
> -Tejas.
>
> 
> On Thu, Jul 23, 2020 at 10:42 AM Carlos Martins via lists.opendaylight.org 
> <http://lists.opendaylight.org/><carlosmartinsufu=yahoo.com...@lists.opendaylight.org
>  <mailto:yahoo.com...@lists.opendaylight.org>> wrote:
> Hello everyone!!!
> 
> I need your help about MDSAL. 
> 
> I am creating a college project with ODL(Oxygen - karaf 0.8.0) + MININET 
> (2.2.1) and I have installed the features:
> 
> 1) odl-restconf-all, odl-dluxapps-topology, odl-l2switch-switch-ui,  and 
> odl-netconf-connector-all
> 
> 2) running the mininet like mn --topo linear,3 
> --controller=remote,ip=<MY_IP>,port=6633 --switch ovs
> 
> However, I am unable to get the config data store to put or delete links of 
> the topology.
> 
> For example:
> 
> The link 
> 
> 1) GET  
> http://localhost:8181/restconf/operational/network-topology:network-topology 
> <http://localhost:8181/restconf/operational/network-topology:network-topology>
>  -> Works, return all topology
> 2) GET 
> http://localhost:8181/restconf/operational/network-topology:network-topology/topology/flow:1/link/openflow:2:3
>  
> <http://localhost:8181/restconf/operational/network-topology:network-topology/topology/flow:1/link/openflow:2:3>
>  ->  Works, return my link openflow:2:3 
> 
> But 
> 
> 3) GET 
> http://localhost:8181/restconf/config/network-topology:network-topology/topology/flow:1/link/openflow:2:3
>  
> <http://localhost:8181/restconf/config/network-topology:network-topology/topology/flow:1/link/openflow:2:3>
>   - > Does not work, return error 
> 
> error-message": "Request could not be completed because the relevant data 
> model content does not exist "
> 
> and 
> 
> 4) DELETE 
> http://localhost:8181/restconf/config/network-topology:network-topology/topology/flow:1/link/openflow:2:3
>  
> <http://localhost:8181/restconf/config/network-topology:network-topology/topology/flow:1/link/openflow:2:3>
>  ->  Does not work, return error
>
>  "error-message": "Data does not exist for path: 
> /(urn:TBD:params:xml:ns:yang:network-topology?revision=2013-10-21)network-topology/topology/topology[{(urn:TBD:params:xml:ns:yang:network-topology?revision=2013-10-21)topology-id=flow:1}]/link/link[{(urn:TBD:params:xml:ns:yang:network-topology?revision=2013-10-21)link-id=openflow:2:3}]"
>
>
> OBS: 
>
> 1) My topology is created by MININET and odl-l2switch-switch-ui inside DLUX 
> UI;
> 2) Anyone link in the config path in RESTCONF does not work ( 
> http://localhost:8181/restconf/config/* 
> <http://localhost:8181/restconf/config/*>);
> 3) I am using curl commands like;
> 
> curl -H "Content-Type: application/xml" -u admin:admin -X DELETE 
> http://localhost:8181/restconf/config/network-topology:network-topology/topology/flow:1/link/openflow:2:3
>  
> <http://localhost:8181/restconf/config/network-topology:network-topology/topology/flow:1/link/openflow:2:3>
>
> So, how can I change my topology using RESTCONF commands?
> 
> Thanks !!!
> 
> 
> ----------------------------------------------- 
> Carlos Martins
> 
> carlosmartins...@yahoo.com.br <mailto:carlosmartins...@yahoo.com.br>
> 
> -----------------------------------------------
> 
> 

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#8618): https://lists.opendaylight.org/g/Discuss/message/8618
Mute This Topic: https://lists.opendaylight.org/mt/75740317/21656
Group Owner: discuss+ow...@lists.opendaylight.org
Unsubscribe: https://lists.opendaylight.org/g/Discuss/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to