Cobbler 登录web界面提示报错“Internal Server Error”
JasonMingHao关注0人评论2882人阅读2019-01-07 16:41:49
在访问cobbler web界面到时候出现以下提示
Cobbler 登录web界面提示报错“Internal Server Error”
ssl的报错日志如下:
[root@Cobbler ~]# tail -f /var/log/httpd/ssl_error_log
[Mon Jan 07 16:24:53.363029 2019] [:error] [pid 3383] [remote 10.0.0.1:212] mod = importlib.import_module(self.SETTINGS_MODULE)
[Mon Jan 07 16:24:53.363032 2019] [:error] [pid 3383] [remote 10.0.0.1:212] File "/usr/lib64/python2.7/importlib/__init__.py", line 37, in import_module
[Mon Jan 07 16:24:53.363084 2019] [:error] [pid 3383] [remote 10.0.0.1:212] __import__(name)
[Mon Jan 07 16:24:53.363089 2019] [:error] [pid 3383] [remote 10.0.0.1:212] File "/usr/share/cobbler/web/settings.py", line 89, in
[Mon Jan 07 16:24:53.363097 2019] [:error] [pid 3383] [remote 10.0.0.1:212] from django.conf.global_settings import TEMPLATE_CONTEXT_PROCESSORS
[Mon Jan 07 16:24:53.363124 2019] [:error] [pid 3383] [remote 10.0.0.1:212] ImportError: cannot import name TEMPLATE_CONTEXT_PROCESSORS
查看cobbler的py配置文件
初步判断应该是pythone-django版本问题
#下载pip.py
wget
#调用本地python运行pip.py脚本
python get-pip.py
#安装pip
pip install Django==1.8.9
#查看pip版本号
python -c "import django; print(django.get_version())"
#重启httpd
systemctl restart httpd
最后完美解决
阅读(1338) | 评论(0) | 转发(0) |