plainblack.com
Username Password
search
Bookmark and Share

    

Install sanity check

User bradcan
Date 12/10/2009 8:41 am
Views 985
Rating -1    Rate [
|
]
Previous · Next
User Message
bradcan

Hi

I'm installing on a Ubuntu 6 test system and I don't understand what I'm doing!

After much installing of perl modules to satisfy many 'Can't locate' compile errors in my Apatche2/log/error.log I have arrived at an error I can't solve.

Here is my configuration: (I'll try to be breif:)

My virtual host config:

<VirtualHost *:80>
        ServerName www.test.com
        ServerAlias test.com
        DocumentRoot /data/domains/test/public
        Alias /extras /data/WebGUI/www/extras
        SetHandler perl-script
        PerlRequire /data/WebGUI/lib/WebGUI.pm
        PerlInitHandler WebGUI
        PerlSetVar WebguiRoot /data/WebGUI
        PerlSetVar WebguiConfig /etc/test.conf
#        PerlCleanupHandler Apache2::SizeLimit  #this only works fo a non thread apache
        PerlRequire /data/WebGUI/sbin/preload.perl
</VirtualHost>

and I have /data/WebGUI/etc/test.conf

I start spectre and do an apache2ctl start and see:

Starting WebGUI 7.7.28
    Loading test.conf

So far so good. However when I point my browser (Firefox) at http://test.com (which I have in /etc/hosts) I get an Internal Server error 500. My /var/log/apache2/error.log now has:

Use of uninitialized value $pathToFile in open at /usr/local/share/perl/5.10.0/Config/JSON.pm line 170.
Use of uninitialized value $pathToFile in concatenation (.) or string at /usr/local/share/perl/5.10.0/Config/JSON.pm line 195.
[Thu Dec 10 13:53:40 2009] [error] [client 127.0.1.1] Cannot read config file:  at /data/WebGUI/lib/WebGUI.pm line 169\n

A quick poke at WebGUI.pm, WebGUI/Config.pm and JSON.pm tells me I completely insane!!

I think this is because I have done my perl installs from CPAN and NOT used /data/wre/prereqs/lib/perl5/site_perl/5.10.0 from the install! I tried inserting a use lib in WebGUI.pm but that gave me Dynaload conflicts!

Obviously theCPAN version of JSON.pm is completely incompatible (it is totally different in respect of coding around $pathToFile) with WebGUI. Why?

I seem to be in a total gotcha here. Do I assume that the only to way do a clean install is to start from scratch and do a source install?

I really don't want to do that because ultimately I need to install WebGUI on a production Fedora server. Given that the source build recompiles every dependency including Apache and ssl, I certainly can't entertain the prospect on a perfectly stable production machine.

Do I need a separate server? Given the slow down as my test install got nearer to success I presume a mere 1GHz and a GB of memory is not enough in any case?

Disappointed

--- (Edited on 12/10/2009 8:41 am [GMT-0600] by bradcan) ---



Back to Top
Rate [
|
]
 
 
perlDreamer

There are two kinds of "source" installs:

  1. Compile the WRE from scratch and use it.  Since there really isn't a compiled Fedora WRE, if the CentOS WRE won't work, that's your next best bet.
  2. Use native packages.  This works very well, I've done it for years, and all it really requires is hand installing lots of modules from CPAN.  The downside is that it won't perform as well as the WRE.

As to the amount of memory and the speed of your processor, that all depends on how busy you think the server is going to be.  Obviously, regardless of the package used to serve the website, you're not going to build anything really big on a server like that.  You can limit the number of processes that mysql and httpd will create to handle that.

For the config problem, is the file in /etc/test.conf readable by the Apache user?

--- (Edited on 12/10/2009 8:09 am [GMT-0800] by perlDreamer) ---



Back to Top
Rate [
|
]
 
 
bradcan

Hi

Thanks for the tip.

I have finaly got my test site up. Oh yes!

As I observed some of the CPAN modules don't seem to be compatible so I found the right way to make my apache2 use the the wre-9.0.3-debian5 install. Like so:

I place:

use lib '/data/wre/prereqs/lib/perl5/5.10.0';
use lib '/data/wre/prereqs/lib/perl5/site_perl/5.10.0';
use lib '/data/WebGUI/lib';

in WebGUI.pm and

use lib '/data/wre/prereqs/lib/perl5/5.10.0';
use lib '/data/wre/prereqs/lib/perl5/site_perl/5.10.0';

in /data/WebGUI/sbin/preload.perl That fixes the perl installation problems.

I still get some complaints in my error.log that /etc/test.conf can't be loaded by JSON. This is because there are verious places where dir_config is called somethin like this:

    my $session = WebGUI::Session->open($server->dir_config('WebguiRoot'),$config->getFilename, $request, $server, $sessionId);

Well for some reasion $server->dir_config returns nothing on my install, but hapily  $request->dir_config('WebguiRoot') does. I can't spot any clues anywhere but perhaps some mod_perl guru does?

Any how I just hacked a couple of places and hay presto I'm up and working.

Hope this helps somebody.

--- (Edited on 12/10/2009 4:55 pm [GMT-0600] by bradcan) ---



Back to Top
Rate [
|
]
 
 
    



© 2012 Plain Black Corporation | All Rights Reserved