Hi Syed,

I installed a new copies of apache and mod_perl under the /home/biomart directory, as you suggested. Now I have
    /home/biomart/apache/bin/apxs -q LIBEXECDIR
returning
    /home/biomart/apache/modules
which is where mod_perl is found, so configureBioMart.pl now finds mod_perl, and martview works OK :-)    . (I have now configured my registry file to point to the PRIDE biomart, and I can display their data in my martview web interface).

I didn't realise that configureBioMart.pl installs some perl code into httpd.conf after loading mod_perl:

        LoadModule perl_module /home/biomart/apache/modules/mod_perl.so
       
        <Perl>
            use lib '/home/biomart/biomart-perl/lib';
            require "BioMart/AttributeTable.pm";
            require "BioMart/Configuration/Attribute.pm";
            ...
            eval { my $init = BioMart::Initializer->new(registryFile => '/home/biomart/biomart-perl/conf/prideURLLocation.xml');
            $main::BIOMART_REGISTRY = $init->getRegistry() || die "Can't get registry from initializer";
            };
        </Perl>


now it's clear to me why I was getting the problems with registries.

When I copied the above lines into /etc/httpd/conf.d/perl.conf (where mod_perl is loaded in my original apache installation), and startup the original apache with
    /etc/sbin/httpd
martview again works, but with the original apache and mod_perl installation.

One other point that tripped me up: there is advice in the Biomart Documentation 0.6, section 2.4.5.2 Couldn't determine Username (in console) to add a User directive to httpd.conf. I also needed to do this, although I didn't get any error message (like the helpful '
Couldn't determine Username') in the console or log file.

I would make these suggestions to anyone trying to install biomart-perl with an existing apache + mod_perl installation:

(1) You can copy/paste sections from the generated httpd.conf into your original httpd.conf, but make sure you get the 'LoadModule perl_module ...' and the perl code shown above in the generated httpd.conf.

(2) If you don't see this, check that
apxs -q LIBEXECDIR or apxs2 -q LIBEXECDIR gives the directory where your mod_perl.so is to be found.

(3) If all else fails, install a new copy of apache and mod_perl as described in 2.4.1.2 Apache and ModPerl quick setup (the documentation suggests this only for the case that you don't already have them installed). This quick setup should probably not be used for a production server, as it omits the recommended 'make test', but is a useful way to get something working, iron out problems such as permissions on directories, etc.
Finally, you can merge the newly generated httpd.conf into your original httpd.conf (or included .conf files), including the above
'LoadModule perl_module ...' and perl code, even if (2) didn't work.

(4) If the newly installed copy of apache fails to start up with no error message (ps -Af doesn't show your httpd running), follow the advice in 2.4.5.2 even if you didn't get the error message 'Couldn't determine Username'.

Thanks for all your help and suggestions. I'm very impressed with the rapid response from the biomart support team, often within hours rather than the days or even weeks that I have experienced from some other organisations. Now I can get back to my original aim, to test out customising the biomart web interface (but I'm afraid there might be more questions :-( ).

Regards,
Roger


Syed Haider wrote:
Hi Roger,
the httpd.conf you are referring is a default one which contains every
possible directive apache web server supports. I dont see a point
loading all the possible modules with httpd with out having a need to do
so. This httpd.conf, is for help and for copy paste so you can create
your own appropriate httpd.conf. Thats precisely why we generate our own
httpd.conf which is short and concise, loading very modules. As far as
your mod_perl and apxs/2 is concerned, I am pretty sure BioMart doesnt
work with out mod_perl. And if apxs/2 from configureBioMart.pl cannot
find mod_perl, then BioMart's independent installation would not have
worked in the first place. I would recommend you to get the independent
installation to work first. The configure script should be able to find
the right directory of apache modules through apxs/2 -q LIBEXECDIR
command. Please try reinstalling your apxs/2 and it should point to the
module directory which you believe is correct. Just a hint about
mod_perl, when you install it, you can supply a switch which points to
the location of apxs/2
e.g
perl Makefile.PL \
     PREFIX=/home/biomart/apache \
     MP_APXS=/home/biomart/apache/bin/apxs


hope this helps
syed


  

Reply via email to