• cobbler登录web界面时出现“Internal Server Error”


      当进行cobbler配置后,并进行web登录时,出现错误:

    先查看其日志位置

      #cat /etc/httpd/conf.d/ssl.conf

      在其中位置发现其错误的日志位置为/etc/httpd/logs/ssl_error_log

        打开文件#cat  /etc/httpd/logs/ssl_error_log

        

      日志回查:   1、在/usr/share/cobbler/web/cobbler.wsgi发现26行错误:_application=get_wsgi_application()错误,这个就表示有控件出错

            2、向下看/usr/lib/python2.7/site-packages/django/core/wsgi.py中发现13行问题,是由于get_wsgi_application所引起的,错误提示为django.setup(set_prefix=False)

            3、向下看/usr/lib/python2.7/site-pages/django/_init_.py中发现22行错误,错误提示:configure_loggin(settings.LOGGING_CONFIG,settings.LOGGING)

      根据日志的问题判断是django的版本的问题

      查看django的版本

        #cat -n /usr/share/cobbler/web/settings.py

        第89行:from django.conf.global_settings import TEMPLATE_CONTEXT_PROCESSORS

        查看资料,确定版本的问题

    解决方法
      

      #下载pip.py
        wget https://bootstrap.pypa.io/get-pip.py
    
      #调用本地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
    注:此解决方法来源于:https://blog.51cto.com/12643266/2339793,如需要转载,请标注。

    查看效果

    完全解决
    至此关于cobbler安装好之后出现错误:Internal Server Errorr的引起的原因是由于django引起,以后多加注意;

     

  • 相关阅读:
    免费录屏工具
    树莓派4安装mysql
    python中,print、变量、赋值详细理解篇01
    mysql db [Warning] IP address 'xxxx' could not be resolved: Name or service not known
    添加脚本命令
    LRUCache实现方案
    HTTP/2做错了什么?刚刚辉煌2年就要被弃用了!?
    TS 中的 export declare interface 和 export interface 到底有什么不同?
    使用nexus搭建npm私服
    nodejs 安装
  • 原文地址:https://www.cnblogs.com/wang50902/p/10760404.html
Copyright © 2020-2023  润新知