473,396 Members | 1,900 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Connecting to PostgreSQL over UNIX domain sockets

Hi,

I seem to be unable to connect to my PostgreSQL database over UNIX
domain sockets, i.e. pg_connect("dbname=mydb");

No matter what I do to the pg_hba.conf file, or anything else, PHP
always returns things like, "Are you sure the server is running
locally?", etc. What's the magic chant to connect to PostgreSQL over
UNIX domain sockets? I know it's working because I can connect via
psql. In case it matters, I'm using all this on Fedora C3.

Andy

NOTE* E-mail address in header is no longer valid.

Jul 17 '05 #1
1 3592
On Thu, 17 Mar 2005 07:47:26 -0800, afalanga wrote:
Hi,

I seem to be unable to connect to my PostgreSQL database over UNIX
domain sockets, i.e. pg_connect("dbname=mydb");

No matter what I do to the pg_hba.conf file, or anything else, PHP
always returns things like, "Are you sure the server is running
locally?", etc. What's the magic chant to connect to PostgreSQL over
UNIX domain sockets? I know it's working because I can connect via
psql. In case it matters, I'm using all this on Fedora C3.


Did you connect to the Postgres server as the web server user?

Jul 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Fossie | last post by:
Hi folks, I am unable to solve the following problem, which should not be new, but I cannot find an appropriate solution anywhere: One python process ("daemon") waits for messages. Another...
5
by: Virgil Green | last post by:
An associate has asked me to take a look a problem he's having with starting mysql. I thought I'd give it a shot to learn some more about mySQL before having him turn it over to someone more...
26
by: jini us | last post by:
Hi, I am starting a new project where I intend to use embedded database server in my win32 application. I intend to use VC++ microsoft studio 6.0 as my development environment. The...
11
by: B. van Ouwerkerk | last post by:
New to PostgreSQL.. not to databases.. or Linux in general.. Let's asume I got convinced by your advocacy and decided to install and play a bit with PostgreSQL to discover it's features and how I...
3
by: John P | last post by:
Hi, I know that some older Unix programs that compile with GCC use socket.h to connect to and execute other programs. However, I am using Visual C++ 6.0 and it doesn't seem to have socket.h...
6
by: Alexander Cohen | last post by:
Im trying to connect locally to a database on a running postgres cluster. If i connect with psql, everything is fine and i can transact. I i try and connect in my own app, i get this error: ...
2
by: Steve Gollery | last post by:
I installed Postgres 8 beta 3 on an XP box, with Postgres running as a service. TaskManager tells me that postgres and postmaster are both running. Using pgAdmin III, I can connect to the server...
0
by: Suresh | last post by:
Hi Guys I have Db2 server installed on remote server. i am connecting to that remote server by using VPN. I want to connect that remote DB2 server instance using my local machine DB2...
1
by: Chris | last post by:
Hi, I am using PHP persistent sockets and have a problem with them. The problem is that PHP only sends the data when the socket is closed. In the code example below the counterparty process...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.