0

我正在尝试使用此处发布的说明在 AWS 上设置一个基本的 CKAN 站点:https ://github.com/okfn/ckan/wiki/How-to-Install-CKAN-2.0-from-source-on-Ubuntu -12.04-on-EC2#create-ckan-users

完成本教程后,我坐在这里盯着 500 Internal Server Error 页面。真可惜。

我是使用 Python 进行 Web 应用程序的新手,还不太了解 wsgi 脚本,所以如果我遗漏了一些明显的东西,请原谅我。这是我的错误日志的回溯。任何关于我应该在哪里寻找的提示将不胜感激。干杯。

>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] mod_wsgi (pid=13943): Target WSGI script '/home/ubuntu/public_html/mysite.com/pyenv/bin/mothership.py' can$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] mod_wsgi (pid=13943): Exception occurred processing WSGI script '/home/ubuntu/public_html/mysite.com/pyenv$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] Traceback (most recent call last):
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]   File "/home/ubuntu/public_html/mysite.com/pyenv/bin/mothership.py", line 10, in <module>
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]     fileConfig(config_filepath)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]   File "/home/ubuntu/public_html/mysite.com/pyenv/lib/python2.7/site-packages/paste/script/util/logging_co$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]     handlers = _install_handlers(cp, formatters)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]   File "/home/ubuntu/public_html/mysite.com/pyenv/lib/python2.7/site-packages/paste/script/util/logging_co$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]     h = apply(klass, args)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] TypeError: __init__() takes at most 2 arguments (5 given)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] mod_wsgi (pid=13942): Target WSGI script '/home/ubuntu/public_html/mysite.com/pyenv/bin/mothership.py' can$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] mod_wsgi (pid=13942): Exception occurred processing WSGI script '/home/ubuntu/public_html/mysite.com/pyenv$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] Traceback (most recent call last):
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]   File "/home/ubuntu/public_html/mysite.com/pyenv/bin/mothership.py", line 10, in <module>
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]     fileConfig(config_filepath)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]   File "/home/ubuntu/public_html/mysite.com/pyenv/lib/python2.7/site-packages/paste/script/util/logging_co$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]     handlers = _install_handlers(cp, formatters)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]   File "/home/ubuntu/public_html/mysite.com/pyenv/lib/python2.7/site-packages/paste/script/util/logging_co$
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253]     h = apply(klass, args)
>[Wed Jul 24 21:02:40 2013] [error] [client 192.245.194.253] TypeError: __init__() takes at most 2 arguments (5 given)
4

1 回答 1

3

这个邮件线程似乎是答案。(我通过谷歌搜索部分回溯找到了它。)

您的配置 ini 文件中的日志记录配置。日志记录参数显然需要如下所示:

args = ("/var/log/ckan/[yoursite.com]/ckan.log", "a", 20000000, 9)
于 2013-07-28T21:38:47.657 回答