May-10-2019, 12:17 PM
Hello.
I have problem with deploying cherrypy on Centos7.
I've worked with cherrypy on Windows (json, postgresql etc.) for few years now without any problems and I don't uderstand what I do wrong in case of Centos.
My "obervations" so far:
- Cherrypy is installed as Python3 package
- There is no any issues with Python3 scripts
- SSH, sFTP work without any issues
- Apache operates on ports like 80, 6060, 9090 without any issues
- iptables and firewalld turned off
- no other software is listening to port 2020
- cherrypy starts without syntax error notifications
- no cherrypy processes duplicated
- 'localhost' and '127.0.0.1' are resolved properly
Sample cherrypy script:
command:
netstat -tulpn | grep :2020
output:
LISTEN 5239/python3 (PID is correct - this is process started by cherrypy)
command:
wget http://127.0.0.1:2020
output:
Connecting to 127.0.0.1:2020... connected.
HTTP request sent, awaiting response...
- the same effect if I use Python3 'requests' module (no response from cherrypy)
- unfortunately cherrypy wasn't able to write down any logs during requests
Could somebody with more experience with centos please point me in the right direction, because I have no idea where to go next / what to check.
Regards.
I have problem with deploying cherrypy on Centos7.
I've worked with cherrypy on Windows (json, postgresql etc.) for few years now without any problems and I don't uderstand what I do wrong in case of Centos.
My "obervations" so far:
- Cherrypy is installed as Python3 package
- There is no any issues with Python3 scripts
- SSH, sFTP work without any issues
- Apache operates on ports like 80, 6060, 9090 without any issues
- iptables and firewalld turned off
- no other software is listening to port 2020
- cherrypy starts without syntax error notifications
- no cherrypy processes duplicated
- 'localhost' and '127.0.0.1' are resolved properly
Sample cherrypy script:
import cherrypy class HelloWorld(object): @cherrypy.expose def index(self): return "Hello World!" cherrypy.config.update({'Access-Control-Allow-Origin': 'http://127.0.0.1', 'server.socket_host': '127.0.0.1', 'server.socket_port': 2020}) cherrypy.quickstart(HelloWorld())The problem is that I can't receive any response to a request.
command:
netstat -tulpn | grep :2020
output:
LISTEN 5239/python3 (PID is correct - this is process started by cherrypy)
command:
wget http://127.0.0.1:2020
output:
Connecting to 127.0.0.1:2020... connected.
HTTP request sent, awaiting response...
- the same effect if I use Python3 'requests' module (no response from cherrypy)
- unfortunately cherrypy wasn't able to write down any logs during requests
Could somebody with more experience with centos please point me in the right direction, because I have no idea where to go next / what to check.
Regards.