abhi
1
I’m able to retrieve the restconf root using the ./well-known/host-meta URL.
Per the restconf draft, we should be able to retrieve the restconf capabilities. But when I try the below http request, I’m getting back no data.
GET http://127.0.0.1:8008/restconf/data/ietf-restconf-monitoring:restconf-state/capabilities
The output is:
204 No Content
I have made sure the confd loadPath is specified for the fxs and the yang files, when starting confd.
Any idea what could be wrong?
Thanks
Not sure what you are doing. I get:
$ curl -i -X GET -H “Accept: application/yang-data+xml” -u admin:admin http://localhost:38008/restconf/data/ietf-restconf-monitoring:restconf-state/capabilities
HTTP/1.1 200 OK
Server:
Date: Fri, 13 Jan 2017 17:38:51 GMT
Last-Modified: Fri, 01 Jan 1971 06:00:00 GMT
Cache-Control: private, no-cache, must-revalidate, proxy-revalidate
Etag: 1484-322591-164902
Content-Type: application/yang-data+xml
Transfer-Encoding: chunked
Pragma: no-cache
<capabilities xmlns="urn:ietf:params:xml:ns:yang:ietf-restconf-monitoring" xmlns:rcmon="urn:ietf:params:xml:ns:yang:ietf-restconf-monitoring">
<capability>urn:ietf:params:restconf:capability:defaults:1.0?basic-mode=explicit</capability>
<capability>urn:ietf:params:restconf:capability:depth:1.0</capability>
<capability>urn:ietf:params:restconf:capability:fields:1.0</capability>
<capability>urn:ietf:params:restconf:capability:with-defaults:1.0</capability>
<capability>http://tail-f.com/ns/restconf/collection/1.0</capability>
<capability>http://tail-f.com/ns/restconf/query-api/1.0</capability>
</capabilities>
abhi
3
Weird. I tried the same command as you, but got back an empty response. Not sure what I could be missing
$ curl -i -X GET -H "Accept: application/yang-data+xml" -u admin:admin
http://0.0.0.0:8008/restconf/data/ietf-restconf-monitoring:restconf-state/capabilities
HTTP/1.1 204 No Content
Server:
Date: Fri, 13 Jan 2017 18:02:57 GMT
Cache-Control: private, no-cache, must-revalidate, proxy-revalidate
Content-Length: 0
Content-Type: application/yang-data+xml
Pragma: no-cache
Weird indeed.
… and since you can retrieve ./well-known/host-meta
the server is obviously running.
There’s no configuration I am aware of that would hide the capabilities. Is it a permission thing, can you log in as admin?
abhi
5
Yes. I am able to login as admin
I really don’t have any other ideas… all I did was to enable RESTCONF in one of the examples in the default ConfD installation.
If you can’t get it to work I think it’s best to open a RT-ticket.
1 Like