我正在尝试将端口80用于我的应用程序服务器,但是当我执行时,netstat -aon
我得到:
TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 4
当我在任务管理器中查找过程时,它显示的PID 4
是SYSTEM
,就是这样.没有延期......没什么.只是" SYSTEM
".这里发生了什么?
我害怕结束这个过程,我该怎么办?
更新:
我已经通过另一个Stack Overflow问题解决了这个问题,该问题的解决方案是让IIS停止在端口80上侦听指定的IP地址.
File "C:\Python25\lib\SocketServer.py", line 330, in __init__
self.server_bind()
File "C:\Python25\lib\BaseHTTPServer.py", line 101, in server_bind
SocketServer.TCPServer.server_bind(self)
File "C:\Python25\lib\SocketServer.py", line 341, in server_bind
self.socket.bind(self.server_address)
File "<string>", line 1, in bind
socket.error: (10013, 'Permission denied')
Run Code Online (Sandbox Code Playgroud)
我尝试启动Google App Engine开发服务器,并在我第一次尝试运行它时收到此错误.有任何想法吗?我是python的新手.
所以我是Python的新手,刚刚尝试安装和运行Django.我正在通过官方教程,当我尝试运行python manage.py runserver时,我得到了Errno 10013:尝试以其访问权限禁止的方式访问套接字.
我正在使用Windows 7,并以管理员身份运行cmd.exe控制台.有人可以用简单的英语解释如何解决这个问题吗?本教程的下一步是访问 http://127.0.0.1:8000/,它应该说欢迎来到Django,但我的只是提出错误.
在此先感谢您的帮助.
我收到这个问题已经快一个月了,非常感谢您的帮助。尝试登录Django Web应用程序时,我在/ accounts / login /遇到OSError。我能够以127.0.0.1:8000/admin登录,但无法在/ accounts / login登录,从而产生错误代码:
OSError at /accounts/login/
[WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions
Request Method: POST
Request URL: http://127.0.0.1:8000/accounts/login/
Django Version: 1.11.1
Exception Type: OSError
Exception Value:
[WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions
Exception Location: C:\Python35-32\lib\socket.py in create_connection, line 702
Python Executable: C:\Python35-32\myvenv_python3\Scripts\python.exe
Python Version: 3.5.2
Python Path:
['C:\\Users\\Kaleab\\Desktop\\ecomstore',
'C:\\Python35-32\\lib\\site-packages\\sqlalchemy-1.1.7-py3.5-win32.egg',
'C:\\Python27', …
Run Code Online (Sandbox Code Playgroud) 这是我的server.py:
import BaseHTTPServer
import SocketServer
class TestRequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):
def do_GET(self):
self.wfile.write("hello world at %s" % __file__)
server = BaseHTTPServer.HTTPServer(('', 10000), TestRequestHandler)
#server = SocketServer.ThreadingTCPServer(('', 8888), TestRequestHandler)
server.serve_forever()
Run Code Online (Sandbox Code Playgroud)
这是我的client.py:
import urllib2
req = urllib2.Request('http://127.0.0.1:10000/')
handle = urllib2.urlopen(req)
content = handle.read()
Run Code Online (Sandbox Code Playgroud)
然后我启动server.py,它的工作原理.
当我启动client.py时,我在Windows 7,Python 2.6上遇到此错误:
Traceback (most recent call last):
File "D:\Dropbox\Forge\urllib-error\client.py", line 3, in <module>
handle = urllib2.urlopen(req)
File "C:\Python26\lib\urllib2.py", line 126, in urlopen
return _opener.open(url, data, timeout)
File "C:\Python26\lib\urllib2.py", line 391, in open
response = …
Run Code Online (Sandbox Code Playgroud)