宝塔用_5204 发表于 2023-7-27 22:01:29

【已完成】nginx无法安装

为了能快速了解并处理您的问题,请提供以下基础信息:面板、插件版本:免费版 7.9.0, nginx全部版本
系统版本:windows server 2019,系统语言是英语
问题描述:安装nginx失败,修复面板了也没用,
相关截图(日志、错误):
Waiting for connection:node.aapanel.com:80
speed:1712 ms ,idle : 3379
-------------------------------------------------
The HTTP Service service is not started.

More help is available by typing NET HELPMSG 3521.

Attempting stop...

Internet services successfully stopped

ERROR: The process "nginx_server.exe" not found.
ERROR: The process "nginx.exe" not found.
Traceback (most recent call last):
File "F:\BtSoft\panel\install\panel_nginx.py", line 284, in set_webserver_access
    print("\u6b63\u5728\u8bbe\u7f6e %s \u6743\u9650" % f)
File "C:\Program Files\python\lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)
UnicodeEncodeError: 'charmap' codec can't encode characters in position 0-3: character maps to <undefined>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "install_soft.py", line 37, in <module>
    module.install_soft(downurl)
File "F:\BtSoft\panel\install\panel_nginx.py", line 60, in install_soft
    self.set_webserver_access()
File "F:\BtSoft\panel\install\panel_nginx.py", line 287, in set_webserver_access
    print("\u6279\u91cf\u8bbe\u7f6e\u53ea\u8bfb\u6743\u9650\u5931\u8d25\uff0c\u53ef\u80fd\u4f1a\u5f71\u54cdnginx\u4f7f\u7528\uff0c\u5982nginx\u65e0\u6cd5\u542f\u52a8\uff0c\u8bf7\u624b\u52a8\u7ed9\u3010{}\u3011\u6dfb\u52a0\u3010{}\u3011\u53ea\u8bfb\u6743\u9650".format(','.join(flist),user))
File "C:\Program Files\python\lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)
UnicodeEncodeError: 'charmap' codec can't encode characters in position 0-15: character maps to <undefined>

盏尽 发表于 2023-7-27 23:12:15

您好,您可以尝试先修复一下面板,然后再尝试前面的操作看是否可行;
如果不行,可能是面板依赖的python环境损坏了,先停止宝塔面板,然后将下面这个目录删掉
C:\Program Files\python
然后下载这个包覆盖安装一下看看是否能解决,覆盖安装不影响原来数据与正在运行的网站。
http://download.bt.cn/win/panel/BtSoft.zip

宝塔用_5204 发表于 2023-7-27 23:46:52

本帖最后由 宝塔用_5204 于 2023-7-27 23:50 编辑

堡塔运维盏尽 发表于 2023-7-27 23:12
您好,您可以尝试先修复一下面板,然后再尝试前面的操作看是否可行;
如果不行,可能是面板依赖的python环 ...
修复面板后重试无效;

停止面板,删除python文件夹后重装面板,没有解决nginx无法安装的问题,仍然报之前一样的错误{:3_44:}
Waiting for connection:node.aapanel.com:80
speed:1722 ms ,idle : 4836
-------------------------------------------------

The HTTP Service service was stopped successfully.


Attempting stop...

Internet services successfully stopped

ERROR: The process "nginx_server.exe" not found.
ERROR: The process "nginx.exe" not found.
Traceback (most recent call last):
File "F:\BtSoft\panel\install\panel_nginx.py", line 284, in set_webserver_access
    print("\u6b63\u5728\u8bbe\u7f6e %s \u6743\u9650" % f)
File "C:\Program Files\python\lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)
UnicodeEncodeError: 'charmap' codec can't encode characters in position 0-3: character maps to <undefined>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "install_soft.py", line 37, in <module>
    module.install_soft(downurl)
File "F:\BtSoft\panel\install\panel_nginx.py", line 60, in install_soft
    self.set_webserver_access()
File "F:\BtSoft\panel\install\panel_nginx.py", line 287, in set_webserver_access
    print("\u6279\u91cf\u8bbe\u7f6e\u53ea\u8bfb\u6743\u9650\u5931\u8d25\uff0c\u53ef\u80fd\u4f1a\u5f71\u54cdnginx\u4f7f\u7528\uff0c\u5982nginx\u65e0\u6cd5\u542f\u52a8\uff0c\u8bf7\u624b\u52a8\u7ed9\u3010{}\u3011\u6dfb\u52a0\u3010{}\u3011\u53ea\u8bfb\u6743\u9650".format(','.join(flist),user))
File "C:\Program Files\python\lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)
UnicodeEncodeError: 'charmap' codec can't encode characters in position 0-15: character maps to <undefined>

宝塔用_5204 发表于 2023-7-28 00:45:54

堡塔运维盏尽 发表于 2023-7-27 23:12
您好,您可以尝试先修复一下面板,然后再尝试前面的操作看是否可行;
如果不行,可能是面板依赖的python环 ...

修复好了!!!

把 F:/BtSoft/panel/install/panel_nginx.py 文件中 284行附近的中文翻译成英文就好了,我哭死,差点就要放弃宝塔了

宝塔用_5204 发表于 2023-7-28 00:47:47

已经解决了把宝塔面板F:\BtSoft\panel\install\panel_nginx.py", line 284 附近的中文翻译成英文,然后在安装nginx 就安装成功了
页: [1]
查看完整版本: 【已完成】nginx无法安装