Hi,

Thank you for you reply, that just a mistake when I send this mail.
Actually I wrote


 root@ryu-vm:~# curl -X POST -d '{"match": {"nw_dst": "10.0.0.1",
"nw_proto": "UDP", "tp_dst": "5002"}, "actions":{"queue": "1"}}'
http://localhost:8080/qos/rules/0000000000000001


when I use RYU controller set my switch just as the Ryu-book <
http://osrg.github.io/ryu-book/ja/html/rest_qos.html>.


And when I set the queue

curl -X POST -d '{"port_name": "s1-eth1", "type": "linux-htb",
"max_rate": "1000000", "queues": [{"max_rate": "500000"}, {"min_rate":
"800000"}]}' http://localhost:8080/qos/queue/0000000000000001

and confirm it as

 http://localhost:8080/qos/rules/0000000000000001

the feedback is ok, and everything goes seems well.

Only I set the 'rules'


 root@ryu-vm:~# curl -X POST -d '{"match": {"nw_dst": "10.0.0.1",
"nw_proto": "UDP", "tp_dst": "5002"}, "actions":{"queue": "1"}}'
http://localhost:8080/qos/rules/0000000000000001


the feedback is OK, however when I confirm it by:

curl -X GET http://localhost:8080/qos/rules/0000000000000001


and the feedback:

 [{"switch_id":"0000000000000001"},"command_result":[]}]


I am going crazy!

I do things just as the Ryu-book <
http://osrg.github.io/ryu-book/ja/html/rest_qos.html>, the only difference
is that my controller is on my host computer (ip: 192.168.56.1) not the VM,
and I set the OVS:

 ovs-vsctl set controller s1 tcp:192.168.56.1

things goes well.

and I set the ovsdb_addr by:

root@ryu-vm:~# curl -X PUT -d '"tcp:192.168.56.1:6632"'
http://localhost:8080/v1.0/conf/switches/0000000000000001/ovsdb_addr


is that right?


I can set 'queue' and confirm it, the why I can NOT set the 'rules' ?!


I really crazy!

Thank you again for reply, and I will republish the mailing list later.




2014-11-06 8:02 GMT+08:00 Yusuke Iwase <[email protected]>:

> Hi,
>
> On 2014年11月05日 21:36, Yafeng Zhou wrote:
> > Hello All,
> >
> > I am learning SDN, and I used Ryu as the controller. And these days I am
> trying to set qos on switches, and I do this by ryu-book <
> http://osrg.github.io/ryu-book/ja/html/rest_qos.html>. Something goes
> well, however when I set the qos rules as:
> >
> > root@ryu-vm:~# curl -X POST -d '{"port_name": "s1-eth1", "type":
> "linux-htb", "max_rate": "1000000", "queues": [{"max_rate": "500000"},
> {"min_rate": "800000"}]}' http://localhost:8080/qos/queue/0000000000000001
>
> This commad adds only settings for queues to switches.
> So the response to confirm qos rules (flow entries of switch) is empty.
>
> To add qos rules, please try following command.
> This command is described in Ryu-book. (
> http://osrg.github.io/ryu-book/ja/html/rest_qos.html#id4)
>
> root@ryu-vm:~# curl -X POST -d '{"match": {"nw_dst": "10.0.0.1",
> "nw_proto": "UDP", "tp_dst": "5002"}, "actions":{"queue": "1"}}'
> http://localhost:8080/qos/rules/0000000000000001
>
> >
> >
> >
> > the response is OK, however when I goes to confirm that as:
> >
> > root@ryu-vm:~# curl -X GET
> http://localhost:8080/qos/rules/0000000000000001
> >
> > and the response is empty!
> > And I use theborwser:
> http://localhost:8080/qos/rules/0000000000000001
> >
> > it feedback as:
> >
> > [{"switch_id":"0000000000000001"},"command_result":[]}]
> >
> >
> >
> >
> > Can anybody tell where I am wrong?
> >
> > Thank you in advance!
> >
> >
> >
> >
> ------------------------------------------------------------------------------
> >
> >
> >
> > _______________________________________________
> > Ryu-devel mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/ryu-devel
> >
>
------------------------------------------------------------------------------
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to