Link to home
Start Free TrialLog in
Avatar of bibu
bibu

asked on

Problem on Mono mod installation(mod enables running asp.net on linux)

1. I use a normal user installed mono runtime,
2. then install mod-mono
3. in apache's config file I add the following line:
=======================================
LoadModule mono_module modules/mod_mono.so
Alias /test "/var/www/html/aspnet"
AddMonoApplications default "/test:/var/www/html/aspnet"
<Location /test >
        SetHandler mono
</Location>
=======================================
4. then I restart apache, in its error_log I get the following result:

 [error] Failed running '/usr/lib/pkgconfig/../../bin/mono /usr/lib/pkgconfig/../../lib/xsp/1.0/mod-mono-server.exe --filename /tmp/mod_mono_server_default --applications --port 8079 /test:/var/www/html/aspnet --nonstop (null) (null) (null) (null) (null) (null)'. Reason: Permission denied

and If I access the page through "http://127.0.0.1/test/index.aspx", get a 503 error[Service Temporarily Unavailable]

I changed to that user, and running the Permission denied code in error_log, seems I can start it without problem, why it failed when running in apache?
ASKER CERTIFIED SOLUTION
Avatar of sleep_furiously
sleep_furiously

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of bibu
bibu

ASKER

yes, it's the case, We enabled SELinux, and we'll test it again after dinner, hope it will work, I will let you know the result soon:)
Avatar of bibu

ASKER

I think the mod-mono works for apache, now no permission denied message appeared, but could you please shed me a light on why I get the following error when I access the index.aspx?
======================================

Stack Trace:

System.ComponentModel.Win32Exception: Some sort of w32 error occurred: 0
in <0x00168> System.IO.FAMWatcher:StartMonitoringDirectory (System.IO.FAMData data)
in <0x0018c> System.IO.FAMWatcher:StartDispatching (System.IO.FileSystemWatcher fsw)
in <0x0001a> System.IO.FileSystemWatcher:Start ()
in <0x00032> System.IO.FileSystemWatcher:set_EnableRaisingEvents (Boolean value)
in (wrapper remoting-invoke-with-check) System.IO.FileSystemWatcher:set_EnableRaisingEvents (bool)
in <0x00127> System.Web.Configuration.FileWatcherCache:.ctor (System.Web.Configuration.ConfigurationData data)
in <0x0004a> System.Web.Configuration.ConfigurationData:get_FileCache ()
in <0x00020> System.Web.Configuration.ConfigurationData:GetConfigOptLocation (System.String sectionName, System.Web.HttpContext context, Boolean useLoc)
in <0x00276> System.Web.Configuration.ConfigurationData:GetConfig (System.String sectionName, System.Web.HttpContext context)
in <0x0005a> System.Web.Configuration.WebDefaultConfig:GetConfig (System.String sectionName, System.Web.HttpContext context)
in <0x00017> System.Web.Configuration.WebConfigurationSettings:GetConfig (System.String sectionName, System.Web.HttpContext context)
in <0x0000d> System.Web.HttpContext:GetConfig (System.String name)
in <0x00028> System.Web.Configuration.CompilationConfiguration:GetInstance (System.Web.HttpContext context)
in <0x0001a> System.Web.UI.BaseParser:get_CompilationConfig ()
in <0x0013f> System.Web.UI.TemplateParser:.ctor ()
in <0x0000a> System.Web.UI.ApplicationFileParser:.ctor (System.String fname, System.Web.HttpContext context)
in <0x00034> System.Web.UI.ApplicationFileParser:GetCompiledApplicationType (System.String inputFile, System.Web.HttpContext context)
in <0x000ae> System.Web.HttpApplicationFactory:InitType (System.Web.HttpContext context)
in <0x00050> System.Web.HttpApplicationFactory:GetApplication (System.Web.HttpContext context)
in <0x00083> System.Web.HttpRuntime:RealProcessRequest (System.Object o)
Some versions of mono gave this vague error when the server lacked permissions to the directory being watched.

"You cannot monitor a directory on which you don't have appropiate permissions."

http://bugzilla.ximian.com/show_bug.cgi?id=53011
Avatar of bibu

ASKER

Thanks furiously, it finally works, your answer greatly helped us