python - Windows Flask服务器程序关闭了之后,端口仍然偶尔出现处于监听状态
高洛峰
高洛峰 2017-04-18 09:47:30
0
2
502

服务器程序关闭了之后,端口仍然偶尔出现处于监听状态是啥意思?

1.flask启动配置

如下
app.run(debug=True,
            host='0.0.0.0',
            port=5800,
            threaded=True,
            processes=0,
            use_debugger=True,
            use_reloader=False)

结果如下:

如下图所示,偶尔会出现端口被占用的情况,但是我用任务管理器看了,进程确实不存在了

高洛峰
高洛峰

拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...

reply all(2)
伊谢尔伦

app.run comes with the framework and is only used for testing. It cannot be used during deployment

黄舟

【Author's Statement】I found the reason

Using TCPView to monitor the process in real time, I found that a process named winvnc4.exe would occupy the port from time to time. Because the machine was very old, I didn’t know when this process was started and no one used it, so I deleted it and closed it. ,done

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!