Solved

Apache/PHP/PostgreSQL Installation Help

Posted on 2002-07-28
7
377 Views
Last Modified: 2013-12-15
I'm building a box to do develpment using Apache/PHP/and PostgreSQL. I have a Windows background, and am floundering some with my first Linux installation (although I'm confident I'm educable :-) )

I'm using Slackware 8.1, Apache 1.3.26, php 4.2.2, and postgres 7.2.1. I have the web server up, and php seems to be working. The problem is that all of the postgres functions seem not to be available to php. (I get message from PHP saying "Fatal Error: Call to undefined function: pg_connect()")

I'm more than happy to lavish points on an answer that gets this up and running!
0
Comment
Question by:rickpaul
  • 3
  • 3
7 Comments
 

Expert Comment

by:housetier
ID: 7186910
Hi!

My first guess is that you need to install the postgresql module for php. On my system the package is called "php4-pgsql" for php4 and "php3-pgsql" for php3.

hope it helps...
---Lasse
0
 

Author Comment

by:rickpaul
ID: 7188651
When I installed PHP, I used the --with-pgsql=shared configuration setting. I also see pgsql.so, which I understand is the shared file.

Is there something I can do to confirm that things are where they're supposed to be?
0
 

Accepted Solution

by:
housetier earned 200 total points
ID: 7188761
what is your distribution? Red Hat, Debian, slackware etc?

and does the output of following script say something about pgsql?

===cut===
<?php
     phpinfo();
?>
===cut==

It should give you lots of information about PHP, your webserver, the environment setting, and modules.

If you're quick you might try this URL

http://217.83.9.207/~housetier/info.php

which is excactly the script from above. (you have to be quick because I use a dial-up internet connection with dynamic IPs and I don't know how long I will have this IP)


Do have ICQ or AIM; so when both of us are online, I can give you the URL...
---Lasse
0
Get up to 2TB FREE CLOUD per backup license!

An exclusive Black Friday offer just for Expert Exchange audience! Buy any of our top-rated backup solutions & get up to 2TB free cloud per system! Perform local & cloud backup in the same step, and restore instantly—anytime, anywhere. Grab this deal now before it disappears!

 

Author Comment

by:rickpaul
ID: 7189085
distribution and versions of programs are in my initial question.

I was able to see your phpinfo, and my
phpinfo(); shows that I configured with pgsql

If we can chat with icq, that would be great!
0
 

Expert Comment

by:housetier
ID: 7190132
Well, my php has bin configured '--without-pgsql' but still there's output that reads:

PostgreSQL Support enabled




I must say that I've never built PHP from scratch. I always used binary packages for my distribution. That's what I recommend you to do, also. That way you have someone elso going through the hassle of configuring PHP and its modules :-)

Here's my ICQ# 117362350
and my AIM screenname realhousetier

---Lasse
0
 

Expert Comment

by:CleanupPing
ID: 9086589
rickpaul:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 

Author Comment

by:rickpaul
ID: 9090963
Sorry to have taken so long to get back on this one.

While the answers provided were helpful and generous, they didn't really solve my problem.

While Lasse didn't directly answer my question he/she kept me plugging away on it until I finally tracked down the solution. (I don't remember clearly, but I think the problem had to do with multiple configuration files, and failing to edit the one that was being read by apache on httpd start.)



0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Daily system administration tasks often require administrators to connect remote systems. But allowing these remote systems to accept passwords makes these systems vulnerable to the risk of brute-force password guessing attacks. Furthermore there ar…
If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now