了解shell安装脚本错误

时间:2012-04-24 11:25:56

标签: linux bash web2py sh

我正在尝试在干净的CentOS 6安装上运行此web2py install script,并收到以下错误:

checkmodule:  loading policy configuration from httpd.te
httpd.te:1:ERROR 'Building a policy module, but no module specification found.
' at token 'EOF' on line 1:

checkmodule:  error(s) encountered while parsing configuration
semodule_package:  Could not open file No such file or directory:  httpd.mod
semodule:  Failed on httpd.pp!

 - Configure Apache to use mod_wsgi

Stopping httpd:                                            [FAILED]
Starting httpd: Syntax error on line 1 of /etc/httpd/conf.d/default.conf:
Invalid command 'EOF', perhaps misspelled or defined by a module not included in the server configuration
                                                           [FAILED]

 - Complete!

./setup-web2py-fedora.sh: line 407: EOF: command not found
./setup-web2py-fedora.sh: line 408: EOF: command not found
./setup-web2py-fedora.sh: line 409: EOF: command not found

我不明白为什么脚本在处理'EOF'时遇到问题,因为它应该是heredoc的分界标识符。

1 个答案:

答案 0 :(得分:1)

在第182行有一个错误的EOF(正确的一个,匹配<< EOF,出现在第193行)。这最终会在httpd.te文件内部,这会在checkmodule尝试处理时导致语法错误。