单声道 IOMAP 区分大小写

发布于 2024-10-07 20:05:49 字数 1971 浏览 9 评论 0原文

在我的 CentOS mod_mono 2.8 (mono 2.8.1) 机器上安装 BlogEngine.NET 时遇到一些问题。

BlogEngine.NET 代码引用名为“Bin”的文件夹。查看目录的内容,有一个名为“bin”的文件夹 - 编译后的源代码所在的正常位置。

不能将文件夹重命名为“Bin”,因为这会导致单声道问题(它需要将文件夹命名为“bin”)。

我遇到了这个: http://www.mono-project.com/IOMap

这表明Mono 中的 IOMap 将使单声道“忽略”大小写敏感性。

我从 su 将 MONO_IOMAP=all 添加到我的环境中,当我调用 env 时它就会出现。但是,这似乎不起作用 - 它仍然区分大小写。

然后,我将 MonoSetEnv MONO_IOMAP=all 添加到特定子域的 apache vhosts 文件中,但这仍然不起作用。

有什么想法我做错了吗?我是否很盲目,没有为除 root 之外的任何其他用户添加 MONO_IOMAP=allenv


更新:该站点的hosts.conf 如下所示:

<VirtualHost *:80>
    ServerAdmin [email protected]
    DocumentRoot /home/host/www/host.net/blog
    ServerName blog.host.net
    ErrorLog /home/host/www/host.net/logs/blog.host.net-error.log
    TransferLog  /home/host/www/host.net/logs/blog.host.net-access.log
    CustomLog /home/host/www/host.net/logs/blog.host.net-access_combined.log combined

    DirectoryIndex index.html index.aspx

    MonoServerPath blog.host.net "/usr/local/bin/mod-mono-server2"
    MonoExecutablePath blog.host.net "/usr/local/bin/mono"
    MonoDebug blog.host.net true
    MonoSetEnv blog.host.net MONO_IOMAP=all
    MonoApplications blog.host.net "/:/home/host/www/host.net/blog"

    <Location "/">
            Allow from all
            Order allow,deny
            MonoSetServerAlias blog.host.net
            SetHandler mono
            SetOutputFilter DEFLATE
            SetEnvIfNoCase Request_URI "\.(?:gif|jpe?g|png)$" no-gzip dont-vary
    </Location>
    <IfModule mod_deflate.c>
            AddOutputFilterByType DEFLATE text/html text/plain text/xml text/javascript
    </IfModule>
</VirtualHost>

Having some problems installing BlogEngine.NET onto my CentOS mod_mono 2.8 (mono 2.8.1) box.

The BlogEngine.NET code references a folder named 'Bin'. On looking at the contents of the directory, there is a folder called 'bin' - the normal place for the compiled source to reside.

Renaming the folder to 'Bin' is not an option, as this will cause mono problems (it requires the folder to be called 'bin').

I came accross this: http://www.mono-project.com/IOMap

Which suggests that IOMap in Mono will make mono 'ignore' case sensitivity.

I added MONO_IOMAP=all to my env, from su, and it appears when I call env However, this doesn't seem to work - it is still case sensitive.

I then added MonoSetEnv MONO_IOMAP=all to my apache vhosts file for a specific subdomain, and this still doesn't work.

Any ideas what I am doing wrong? Am I being blind and not adding MONO_IOMAP=all to env for any other users than root?


Update: My hosts.conf for this site looks like:

<VirtualHost *:80>
    ServerAdmin [email protected]
    DocumentRoot /home/host/www/host.net/blog
    ServerName blog.host.net
    ErrorLog /home/host/www/host.net/logs/blog.host.net-error.log
    TransferLog  /home/host/www/host.net/logs/blog.host.net-access.log
    CustomLog /home/host/www/host.net/logs/blog.host.net-access_combined.log combined

    DirectoryIndex index.html index.aspx

    MonoServerPath blog.host.net "/usr/local/bin/mod-mono-server2"
    MonoExecutablePath blog.host.net "/usr/local/bin/mono"
    MonoDebug blog.host.net true
    MonoSetEnv blog.host.net MONO_IOMAP=all
    MonoApplications blog.host.net "/:/home/host/www/host.net/blog"

    <Location "/">
            Allow from all
            Order allow,deny
            MonoSetServerAlias blog.host.net
            SetHandler mono
            SetOutputFilter DEFLATE
            SetEnvIfNoCase Request_URI "\.(?:gif|jpe?g|png)$" no-gzip dont-vary
    </Location>
    <IfModule mod_deflate.c>
            AddOutputFilterByType DEFLATE text/html text/plain text/xml text/javascript
    </IfModule>
</VirtualHost>

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

未央 2024-10-14 20:05:49

尝试使用服务器别名设置 MonoSetEnv,例如我的虚拟主机配置如下所示:

DocumentRoot /var/www/my.domain.com/
ServerName my.domain.com

MonoServerPath mydomaincom /usr/local/bin/mod-mono-server4
MonoSetEnv mydomaincom MONO_IOMAP=all
AddMonoApplications mydomaincom "/:/var/www/my.domain.com/"

<Location />
    Allow from all
    Order allow,deny
    MonoSetServerAlias mydomaincom
    SetHandler mono
    SetOutputFilter DEFLATE
    SetEnvIfNoCase Request_URI "\.(?:gif|jpe?g|png)$" no-gzip dont-vary
</Location>
<IfModule mod_deflate.c>
    AddOutputFilterByType DEFLATE text/html text/plain text/xml text/javascript
</IfModule>

Try to set MonoSetEnv with server alias, for example my configuration of virtual host looks like this:

DocumentRoot /var/www/my.domain.com/
ServerName my.domain.com

MonoServerPath mydomaincom /usr/local/bin/mod-mono-server4
MonoSetEnv mydomaincom MONO_IOMAP=all
AddMonoApplications mydomaincom "/:/var/www/my.domain.com/"

<Location />
    Allow from all
    Order allow,deny
    MonoSetServerAlias mydomaincom
    SetHandler mono
    SetOutputFilter DEFLATE
    SetEnvIfNoCase Request_URI "\.(?:gif|jpe?g|png)$" no-gzip dont-vary
</Location>
<IfModule mod_deflate.c>
    AddOutputFilterByType DEFLATE text/html text/plain text/xml text/javascript
</IfModule>
望喜 2024-10-14 20:05:49

我只需将 MonoSetEnv MONO_IOMAP=all 添加到我的 httpd.conf 配置文件(通常位于 /etc/apache2/httpd.conf< /代码>)。

MonoSetEnv MONO_IOMAP=all

I was able to resolve this by simply adding MonoSetEnv MONO_IOMAP=all to my httpd.conf configuration file (usually located at /etc/apache2/httpd.conf).

MonoSetEnv MONO_IOMAP=all
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文