Hi everyone

I would search archives for this but I honestly can't think what to
search for in this case :(

I have 1 server, with 2 practically identical sites on it. And calls to
databases are getting mixed up (Using MySQL and DBI)

I have an ensim server running:
Apache/1.3.27  
mod_perl/1.24_01
(Red-Hat/Linux)

I'm using PerlAuthenHandler Apache::AuthDBI::authen

I'm calling it like so:
PerlSetVar Auth_DBI_data_source DBI:mysql:angie_mydomain_net

I have my own handler calling my Perl Script for all .html pages:

Action add-vertmod /perl/onefile.pl
AddHandler add-vertmod .html

onfile.pl calls a load of my modules like so:

use lib "/home/virtual/site17/fst/var/www/perl/vert";
use SiteMap;
use Event;

inside my modules I have the following DBI Code

my ($dbname, $host, $user, $password, $tablename) = 
    qw(angie_mydomain_net localhost username password Event);

my $dbh = DBI->connect("DBI:mysql:$dbname:$host",$user,$password)
    or die "can't connect user $user to to database $host:$dbname";
    
OK that's the setup:

I set up another subdomain on the server, which lives in folder 
"/home/virtual/site29"

I changed all references to site17 to site29, and all references to the
database and it's username and password. I've double checked this twice
in BBedit now. I didn't miss any.


So I have one set of modules in
/home/virtual/site17/fst/var/www/perl/vert

and another in 
/home/virtual/site29/fst/var/www/perl/vert

And those modules have different database information (but tables inside
are the same).

As you've probably guessed I'm trying to get a mirror site up so I can
work on it while people use the other one safely.

However it seems the database calls are getting mixed up. Sometimes
actions get set to one instead of the other, it's hard to actually say
what is happening, It looks like a var is being overwritten, but I've
used "my" everywhere so I can't work it out.

A bit stuck... Any ideas?

Thanks 

Angie

-- 
Reporting bugs: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html

Reply via email to