Re: [rt-users] Mason: Cannot resolve file to component
The solution that worked for me last night was to run completely separate instances of httpd for each RT instance, instead of using vhost definitions under 1 httpd instance. On 3/23/2010 6:26 PM, Jeff Blaine wrote: Adding some 'warn' statements to Mason/Resolver/File.pm in apache_request_to_comp_path() shows that my virtual host is using my other virtual host's component paths. I installed RT 3.8.7 in /apps/rt. Works fine. I installed (from pristine tar.gz) another instance of RT in /apps/rt_rtsrv1_dev. This does not work. Note the following debug statement after a request to the virtual host associated with /apps/rt_rtsrv1_dev Mar 23 18:07:08 rtdev1 RT: [Mason apache_request_to_comp_path] : current root is /apps/rt/share/html and current file is /apps/rt_rtsrv1_dev/share/html/index.html In this request, a reference to '/apps/rt/anything' is WRONG. So something is bogus with Mason when used with RT on multiple ports controlled by the same Apache install (or something like that). There is no reference to '/apps/rt/' anywhere in the vhost definition nor in the installed tree under /apps/rt_rtsrv1_dev/* On 3/23/2010 3:34 PM, Jeff Blaine wrote: And... the following in RT_SiteConfig.pm does not help (a solution that worked for someone in 2009): Set($MasonComponentRoot, /apps/rt_rtsrv1_dev/share/html); Set($MasonLocalComponentRoot, /apps/rt_rtsrv1_dev/local); Set($MasonDataDir, /apps/rt_rtsrv1_dev/var/mason_data); Set($MasonSessionDir, /apps/rt_rtsrv1_dev/var/session_data); :( On 3/23/2010 3:30 PM, Jeff Blaine wrote: This is 3.8.7 + mod_perl On 3/23/2010 2:57 PM, Jeff Blaine wrote: This has me really scratching my head. If it makes any difference, this host (rtdev1) serves two separate RT instances, each on different ports. The other is working fine rtdev1 RT: [Mason] Cannot resolve file to component: /apps/rt_rtsrv1_dev/share/html/index.html (is file outside component root?) at /usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm line 852. (/usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm:852) [r...@rtdev1 log]# ls -l /apps/rt_rtsrv1_dev/share/html/index.html -rw-r--r-- 1 root bin 5188 Mar 23 13:39 /apps/rt_rtsrv1_dev/share/html/index.html [r...@rtdev1 log]# Listen xx.xx.9.85:443 NameVirtualHost xx.xx.9.85:443 VirtualHost xx.xx.9.85:443 # Copied whole config and altered path/port from working # instance! ServerName rtdev1.our.org:443 # ... SSL options here ... DocumentRoot /apps/rt_rtsrv1_dev/share/html AddDefaultCharset UTF-8 PerlRequire /apps/rt_rtsrv1_dev/bin/webmux.pl Location /NoAuth/images SetHandler default /Location Location / SetHandler perl-script PerlResponseHandler RT::Mason /Location /VirtualHost Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com
Re: [rt-users] Mason: Cannot resolve file to component
This is 3.8.7 + mod_perl On 3/23/2010 2:57 PM, Jeff Blaine wrote: This has me really scratching my head. If it makes any difference, this host (rtdev1) serves two separate RT instances, each on different ports. The other is working fine rtdev1 RT: [Mason] Cannot resolve file to component: /apps/rt_rtsrv1_dev/share/html/index.html (is file outside component root?) at /usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm line 852. (/usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm:852) [r...@rtdev1 log]# ls -l /apps/rt_rtsrv1_dev/share/html/index.html -rw-r--r-- 1 root bin 5188 Mar 23 13:39 /apps/rt_rtsrv1_dev/share/html/index.html [r...@rtdev1 log]# Listen xx.xx.9.85:443 NameVirtualHost xx.xx.9.85:443 VirtualHost xx.xx.9.85:443 # Copied whole config and altered path/port from working # instance! ServerName rtdev1.our.org:443 # ... SSL options here ... DocumentRoot /apps/rt_rtsrv1_dev/share/html AddDefaultCharset UTF-8 PerlRequire /apps/rt_rtsrv1_dev/bin/webmux.pl Location /NoAuth/images SetHandler default /Location Location / SetHandler perl-script PerlResponseHandler RT::Mason /Location /VirtualHost Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com
Re: [rt-users] Mason: Cannot resolve file to component
And... the following in RT_SiteConfig.pm does not help (a solution that worked for someone in 2009): Set($MasonComponentRoot, /apps/rt_rtsrv1_dev/share/html); Set($MasonLocalComponentRoot, /apps/rt_rtsrv1_dev/local); Set($MasonDataDir, /apps/rt_rtsrv1_dev/var/mason_data); Set($MasonSessionDir, /apps/rt_rtsrv1_dev/var/session_data); :( On 3/23/2010 3:30 PM, Jeff Blaine wrote: This is 3.8.7 + mod_perl On 3/23/2010 2:57 PM, Jeff Blaine wrote: This has me really scratching my head. If it makes any difference, this host (rtdev1) serves two separate RT instances, each on different ports. The other is working fine rtdev1 RT: [Mason] Cannot resolve file to component: /apps/rt_rtsrv1_dev/share/html/index.html (is file outside component root?) at /usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm line 852. (/usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm:852) [r...@rtdev1 log]# ls -l /apps/rt_rtsrv1_dev/share/html/index.html -rw-r--r-- 1 root bin 5188 Mar 23 13:39 /apps/rt_rtsrv1_dev/share/html/index.html [r...@rtdev1 log]# Listen xx.xx.9.85:443 NameVirtualHost xx.xx.9.85:443 VirtualHost xx.xx.9.85:443 # Copied whole config and altered path/port from working # instance! ServerName rtdev1.our.org:443 # ... SSL options here ... DocumentRoot /apps/rt_rtsrv1_dev/share/html AddDefaultCharset UTF-8 PerlRequire /apps/rt_rtsrv1_dev/bin/webmux.pl Location /NoAuth/images SetHandler default /Location Location / SetHandler perl-script PerlResponseHandler RT::Mason /Location /VirtualHost Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com
Re: [rt-users] Mason: Cannot resolve file to component
Adding some 'warn' statements to Mason/Resolver/File.pm in apache_request_to_comp_path() shows that my virtual host is using my other virtual host's component paths. I installed RT 3.8.7 in /apps/rt. Works fine. I installed (from pristine tar.gz) another instance of RT in /apps/rt_rtsrv1_dev. This does not work. Note the following debug statement after a request to the virtual host associated with /apps/rt_rtsrv1_dev Mar 23 18:07:08 rtdev1 RT: [Mason apache_request_to_comp_path] : current root is /apps/rt/share/html and current file is /apps/rt_rtsrv1_dev/share/html/index.html In this request, a reference to '/apps/rt/anything' is WRONG. So something is bogus with Mason when used with RT on multiple ports controlled by the same Apache install (or something like that). There is no reference to '/apps/rt/' anywhere in the vhost definition nor in the installed tree under /apps/rt_rtsrv1_dev/* On 3/23/2010 3:34 PM, Jeff Blaine wrote: And... the following in RT_SiteConfig.pm does not help (a solution that worked for someone in 2009): Set($MasonComponentRoot, /apps/rt_rtsrv1_dev/share/html); Set($MasonLocalComponentRoot, /apps/rt_rtsrv1_dev/local); Set($MasonDataDir, /apps/rt_rtsrv1_dev/var/mason_data); Set($MasonSessionDir, /apps/rt_rtsrv1_dev/var/session_data); :( On 3/23/2010 3:30 PM, Jeff Blaine wrote: This is 3.8.7 + mod_perl On 3/23/2010 2:57 PM, Jeff Blaine wrote: This has me really scratching my head. If it makes any difference, this host (rtdev1) serves two separate RT instances, each on different ports. The other is working fine rtdev1 RT: [Mason] Cannot resolve file to component: /apps/rt_rtsrv1_dev/share/html/index.html (is file outside component root?) at /usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm line 852. (/usr/lib/perl5/site_perl/5.8.8/HTML/Mason/ApacheHandler.pm:852) [r...@rtdev1 log]# ls -l /apps/rt_rtsrv1_dev/share/html/index.html -rw-r--r-- 1 root bin 5188 Mar 23 13:39 /apps/rt_rtsrv1_dev/share/html/index.html [r...@rtdev1 log]# Listen xx.xx.9.85:443 NameVirtualHost xx.xx.9.85:443 VirtualHost xx.xx.9.85:443 # Copied whole config and altered path/port from working # instance! ServerName rtdev1.our.org:443 # ... SSL options here ... DocumentRoot /apps/rt_rtsrv1_dev/share/html AddDefaultCharset UTF-8 PerlRequire /apps/rt_rtsrv1_dev/bin/webmux.pl Location /NoAuth/images SetHandler default /Location Location / SetHandler perl-script PerlResponseHandler RT::Mason /Location /VirtualHost Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com Discover RT's hidden secrets with RT Essentials from O'Reilly Media. Buy a copy at http://rtbook.bestpractical.com