DBI and mod_perl for Oracle 10g HTTP Server
dmann — Fri, 04/25/2008 - 22:36
Looks like Oracle has finally come around and made it easier to incorporate the DBI module into the Oracle HTTP Server. The 10gR2 HTTP Server Administrators guide also has a laundry list of other modules that are enabled by default or easily turned on.
Here is the mod_perl section of the 10gR2 HTTP Server Admininistrators Guide: click here
Yes, I can't believe it, but Oracle made something easy for once. Uncomment a line in the http.conf, restart the httpd server, customize your perl script, and you should be mod_perling with DBI.
A couple of notes:
Shebang #!:
To keep things simple it is best to use the Perl in the Oracle Home the http server is running out of, not the generic /usr/bin/perl that is available on most machines.
So yes your Shebang will look ugly, but it will cut down on confusion. Mine looks something like this:
#!/u01/app/oracle/product/10.2.0.3/perl/bin/perl -wJust remember that you'll have to modify scripts before they are run. If you have any weirdness (like I did) it may be because the scripts had the default #!/usr/bin/perl which was missing DBI. Port: To find the port your server is running on, locate the "Port" configuration item in your $ORACLE_HOME/Apache/Apache/conf/httpd.conf file.
http://machinename:port/cgi-bin/test.pl-- Dave

Post new comment