-
Notifications
You must be signed in to change notification settings - Fork 72
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
curl not giving any data on RESTCONF. #34
Comments
Bad gateway is (typically) if there is no fastcgi program accessible from nginx, in this case the clixon_restconf daemon. |
Can you please supply nginx config file. And exactly how you start backend, restconf and curl command? |
oh ya hi!!! Thanks a lot, it is working now but some part. Can you help me with this....
No multiple restcof's. And Have checked README.md under apps/restconf/. Why restconf is not able to get the data. or Should the question be from where it is reading all that data. Thanks a lot!!! Regards, |
Oh sorry!!! My nginx config file is like this `# Default server configuration server {
}` Not able to get the data now that is the only part remaining. |
Seems like you have not setup the clixon group. |
Also www-data need to be member of that group: |
I have updated https://github.com/clicon/clixon/blob/develop/doc/FAQ.md and https://github.com/clicon/clixon/blob/develop/example/README.md to make this clearer. |
Ya ya !!! |
Whoa!!!
Yo some data came. Ah Thanks a lot so how can I use more manipulation. I know you posted some already at FAQ. But any other suggestions please not the RFC :) Thanks once again for your so fast responses and help. |
Hi!!! And i think this is just state data. i think I'm not getting the configuration data. Is it so?? Regards, |
Restconf GET gives a combined configuration and state data resources, it differs form netconf in that way that there is no separate config and state data get method. |
Hi @olofhagsand !!!
I'm trying to run RESTCONF on my localhost, but on doing a curl, it is giving 502 Bad Gateway
.Can you figure out, what am I missing on configuring restconf???? Some output for running processes are as follows (for clixon & for nginx)...
AS ROOT : 01:31 PM : yang :) ps aux | grep [c]lixon
<title>502 Bad Gateway</title>root 10189 0.0 0.0 28408 396 pts/0 Ss+ Jul11 0:00 /usr/sbin/clixon_backend -F -f /data/clixon.conf
root 10470 0.0 0.0 28412 484 pts/0 Ss+ Jul11 0:00 /usr/sbin/clixon_backend -F -f /data/clixon.conf
root 11228 0.0 0.0 28412 488 pts/0 Ss+ Jul11 0:00 /usr/sbin/clixon_backend -F -f /data/clixon.conf
root 16151 0.0 0.1 65612 4332 pts/4 S+ 11:26 0:00 sudo su -c /www-data/clixon_restconf -f /usr/local/etc/example.xml -s /bin/sh root
root 16152 0.0 0.1 65140 4036 pts/4 S+ 11:26 0:00 su -c /www-data/clixon_restconf -f /usr/local/etc/example.xml -s /bin/sh root
root 16165 0.0 0.0 4628 808 ? Ss 11:26 0:00 sh -c /www-data/clixon_restconf -f /usr/local/etc/example.xml
root 16166 0.0 0.0 23648 3300 ? S 11:26 0:00 /www-data/clixon_restconf -f /usr/local/etc/example.xml
root 18001 0.0 0.0 30528 3392 pts/1 S+ 12:49 0:00 clixon_backend -Ff /usr/local/etc/example.xml
root 18015 0.0 0.0 24376 3412 pts/2 S+ 12:50 0:00 clixon_netconf -f /usr/local/etc/example.xml
AS ROOT : 01:31 PM : yang :) ps aux | grep [n]ginx
root 16416 0.0 0.0 140656 1504 ? Ss 11:37 0:00 nginx: master process /usr/sbin/nginx -g daemon on; master_process on;
www-data 16417 0.0 0.1 143272 6272 ? S 11:37 0:00 nginx: worker process
www-data 16418 0.0 0.1 143272 6272 ? S 11:37 0:00 nginx: worker process
AS ROOT : 01:31 PM : yang :)
AS ROOT : 01:31 PM : yang :)
AS ROOT : 01:31 PM : yang :) curl -G http://127.0.0.1/restconf/data
502 Bad Gateway
nginx/1.14.0 (Ubuntu) AS ROOT : 01:33 PM : yang :) AS ROOT : 01:31 PM : yang :) ps aux | grep [c]lixon root 10189 0.0 0.0 28408 396 pts/0 Ss+ Jul11 0:00 /usr/sbin/clixon_backend -F -f /data/clixon.conf root 10470 0.0 0.0 28412 484 pts/0 Ss+ Jul11 0:00 /usr/sbin/clixon_backend -F -f /data/clixon.conf root 11228 0.0 0.0 28412 488 pts/0 Ss+ Jul11 0:00 /usr/sbin/clixon_backend -F -f /data/clixon.conf root 16151 0.0 0.1 65612 4332 pts/4 S+ 11:26 0:00 sudo su -c /www-data/clixon_restconf -f /usr/local/etc/example.xml -s /bin/sh root root 16152 0.0 0.1 65140 4036 pts/4 S+ 11:26 0:00 su -c /www-data/clixon_restconf -f /usr/local/etc/example.xml -s /bin/sh root root 16165 0.0 0.0 4628 808 ? Ss 11:26 0:00 sh -c /www-data/clixon_restconf -f /usr/local/etc/example.xml root 16166 0.0 0.0 23648 3300 ? S 11:26 0:00 /www-data/clixon_restconf -f /usr/local/etc/example.xml root 18001 0.0 0.0 30528 3392 pts/1 S+ 12:49 0:00 clixon_backend -Ff /usr/local/etc/example.xml root 18015 0.0 0.0 24376 3412 pts/2 S+ 12:50 0:00 clixon_netconf -f /usr/local/etc/example.xml AS ROOT : 01:31 PM : yang :) ps aux | grep [n]ginx root 16416 0.0 0.0 140656 1504 ? Ss 11:37 0:00 nginx: master process /usr/sbin/nginx -g daemon on; master_process on; www-data 16417 0.0 0.1 143272 6272 ? S 11:37 0:00 nginx: worker process www-data 16418 0.0 0.1 143272 6272 ? S 11:37 0:00 nginx: worker process AS ROOT : 01:31 PM : yang :) AS ROOT : 01:31 PM : yang :) AS ROOT : 01:31 PM : yang :) curl -G http://127.0.0.1/restconf/data <title>502 Bad Gateway</title>
502 Bad Gateway
nginx/1.14.0 (Ubuntu) AS ROOT : 01:33 PM : yang :)
Regards,
Shubham
The text was updated successfully, but these errors were encountered: