1

这几乎是一篇 wiki 帖子,但这些MonoSetEnv MONO_IOMAP=all选项在 Apache2 w/Ubuntu 中对我不起作用,正如我所理解的官方文档中所指定的那样。

 <VirtualHost *:80>
    ServerAdmin webmaster@localhost

    MonoAutoApplication disabled
    MonoSetEnv MONO_IOMAP=all
    MonoDebug true
    MonoApplications "/myapp:/pathto/myapp"
    MonoServerPath "/usr/bin/mod-mono-server4"
...

似乎有一种新的语法来指定它。MonoIOMAP all如下所示:

 <VirtualHost *:80>
    ServerAdmin webmaster@localhost

    MonoAutoApplication disabled
    MonoIOMAP all
    MonoDebug true
    MonoApplications "/myapp:/pathto/myapp"
    MonoServerPath "/usr/bin/mod-mono-server4"

这是特定于 Ubuntu 还是 mono-server4?

大多数帖子仍然提到这种MonoSetEnv方式,我只发现这个与果园 CMS 问题有关,提示我使用新语法......

正在使用的版本

Ubuntu Server 12.04.2 LTS
Server 版本:Apache/2.2.22 (Ubuntu)
Mono JIT 编译器版本 2.10.8.1 (Debian 2.10.8.1-1ubuntu2.2)
mono-server4

4

1 回答 1

1

它在mod_mono (8)手册页中记录如下:

"MonoIOMAP"
Takes alias name and a string of the same format and meaning as the MONO_IOMAP
environment variable (see the mono(1) manpage). The effect is that mod_mono performs
the same actions as mono runtime with MONO_IOMAP in effect, as well as that the
MONO_IOMAP variable with the specified value is exported in the backend environment.
This option is necessary when you're using MONO_IOMAP in your application and there
might be static files with mixed case names - in such case mod_mono attempts to open
the file directly and sends it using apache facilities.
Default value: none

MonoSetEnv应该仍然有效,但是 mod-mono 本身不会对该设置起作用,除非在环境中传递它。

于 2013-05-22T16:53:31.293 回答