%yaourt -Qi ocaml-ocsigenserver
name : ocaml-ocsigenserver
version : 2.0.2-1
URL : http://ocsigen.org/
%cat ocsigen.conf.qachina
...
<ocsigen>
<server>
<port>8000</port>
<logdir>/media/E/RnD/ocaml/test/log/</logdir>
<datadir>/media/E/RnD/ocaml/test/data</datadir>
<user>***</user>
<group>***</group>
<charset>utf-8</charset>
<findlib path="/usr/lib/ocaml"/>
<extension findlib-package="ocsigenserver.ext.staticmod"/>
<extension findlib-package="ocsigenserver.ext.cgimod">
<cgitimeout value="30"/>
</extension>
<host charset="utf-8" hostfilter="*">
<site path="ocsigenstuff">
<static dir="/srv/ocsigenserver/ocsigenstuff" />
</site>
<site path="qachina">
<cgi regexp="cgi-bin/([^/]*)" dir="/media/E/www/qachina/cgi-bin/" script="1" />
<static dir="/media/E/www/qachina" />
</site>
<static dir="/srv/ocsigenserver" />
</host>
</server>
</ocsigen>
%ocsigen -c ocsigen.conf.qachina
当访问http://127.0.0.1:8000时,它工作得很好!但是,无论访问http://127.0.0.1:8000/ocsigenstuff或http://127.0.0.1:8000/qachina,它都会报告404错误!
任何建议都是赞赏的!
你的配置文件没有问题。Ocsigen正在目录中查找"index.html",但您提供了"index.htm",因此它返回"page not found"错误。
正如stassahan所指出的,这样的问题可以通过使用-V选项运行ocsigen来发现。