Q:

Regarding Perl DBD::Oracle installation in local directory

I want to connect with the oracle database from a perl script in solaris servier.  Able to see DBI is installed but not DBD::Oracle in the current perl version 5.8.4.  I dont have root acess and working on my home user id.  Download the DBD-Oracle-1.50 and unzipped in the local directory where my perl script exists. I want to copy the DBD Oracle library files into a custom directory and run the script since i dont have root acess.  When i read the install script in the DBD-Oracle-1.50  it's says for manuall install i need to run the below scripts .  Since i dont have root access i want to copy the library modules into the local directory. Not sure how to tell these scripts to install it in the local directory where my perl script exists.      
Does installing DBI and DBD in a custom directory under my user id makes it work properly. Do those modules require root access to work properly? To use DBD::Oracle does oracle needs to be installed in server. My Understanding Oracle driver DBD::Oracle should take care of it.

 perl Makefile.PL
 make && make test
 make install 

>  ls -tlr /usr/perl5/vendor_perl/5.8.4/sun4-solaris-64int total 956
> -rwxr-xr-x   1 root     bin        15161 Mar 26  2005 Roadmap.pod
> -rwxr-xr-x   1 root     bin         1048 Sep  5  2006 TASKS.pod
> -rwxr-xr-x   1 root     bin       289343 Jun 26  2007 DBI.pm
> -rwxr-xr-x   1 root     bin         4608 Jun 12  2008 goferperf.pl
> -rwxr-xr-x   1 root     bin         1356 Jun 12  2008 dbixs_rev.pl
> -rwxr-xr-x   1 root     bin        58386 Apr  3  2010 SNMP.pm drwxr-xr-x   3 root     bin            7 Oct 13  2010 NetSNMP
> drwxr-xr-x   2 root     bin            3 Oct 13  2010 Win32 drwxr-xr-x
> 8 root     bin           19 Oct 13  2010 DBI drwxr-xr-x   2 root    
> bin            4 Oct 13  2010 Bundle drwxr-xr-x   6 root     other    
> 6 Oct 13  2010 auto drwxr-xr-x   3 root     bin           11 Oct 13 
> 2010 DBD
> 
> ls -ltr  /usr/perl5/vendor_perl/5.8.4/sun4-solaris-64int/DBD total 543
> -rwxr-xr-x   1 root     bin       111586 May  6  2006 Pg.pm
> -rwxr-xr-x   1 root     bin        28785 Sep 27  2006 Proxy.pm
> -rwxr-xr-x   1 root     bin         7937 Jan 25  2007 Sponge.pm
> -rwxr-xr-x   1 root     bin        42836 Feb  6  2007 DBM.pm
> -rwxr-xr-x   1 root     bin        19882 Mar 28  2007 File.pm
> -rwxr-xr-x   1 root     bin        12051 May 10  2007 ExampleP.pm
> -rwxr-xr-x   1 root     bin        43586 May 14  2007 Gofer.pm
> -rwxr-xr-x   1 root     bin         3761 Jun 15  2007 NullP.pm drwxr-xr-x   4 root     bin            4 Oct 13  2010 Gofer

A:

If DBI is already installed, you should only need to install DBD::Oracle, though you might want to install a later version of DBI. You can install DBD::Oracle under your home directory, then set the PERL5LIB environment variable to that directory (or to include that directory). The long way to install is:
perl Makefile.PL PREFIX=~/perl #Or whatever sub-directory you like
make
make test
make install

Then include at least "~/perl/lib;~/perl/lib/site_perl" in PERL5LIB before running your programs (or include a 'use lib" in your programs).
You can also set certain environment variables like PERL_MM_OPT and PERL_MB_OPT so that you don't have to specify the PREFIX= on the command line (see docs for ExtUtils::MakeMaker and Module::Build). I also recommend cpanm and setting PERL_CPANM_HOME to something under your home directory.

