Database Recovery Help...

Started by John Clark Naldoza y Lopezalmost 25 years ago6 messagesgeneral
Jump to latest
#1John Clark Naldoza y Lopez
njclark@ntsp.nec.co.jp

Hi,

I recently came across a problem wherein I am not able to start my
postgreSQL 7.0.3 server.

Here's what happens..;-(

postgres@kahoy /root$ postmaster -D /var/lib/pgsql/data
FATAL: StreamServerPort: bind() failed: Permission denied
Is another postmaster already running on that port?
If not, remove socket node (/tmp/.s.PGSQL.5432) and retry.
/usr/bin/postmaster: cannot create UNIX stream port

There is no one binding the 5432 port, and no one is trying to connect
to that port. I may be left with no other alternative and restart from
scratch...;-(

There are some pretty important data currently in the database that I'd
like to recover...

Is there any way wherein I could recover or reconstruct the data?

Cheers,

John Clark

P.S. I'm using Trustix 1.4.80..;-)

--
/) John Clark Naldoza y Lopez (\
/ ) Software Design Engineer II ( \
_( (_ _ Web-Application Development _) )_
(((\ \> /_> Cable Modem Network Management System <_\ </ /)))
(\\\\ \_/ / NEC Telecom Software Phils., Inc. \ \_/ ////)
\ / \ /
\ _/ phone: (+63 32) 233-9142 loc. 3112 \_ /
/ / cellphone: (+63 919) 399-4742 \ \
/ / email: njclark@ntsp.nec.co.jp \ \

#2Poul L. Christiansen
poulc@cs.auc.dk
In reply to: John Clark Naldoza y Lopez (#1)
Re: Database Recovery Help...

If you are sure that no other postmaster is running, try deleting the file
/tmp/.s.PGSQL.5432, as the error message suggests. When you've done that,
you should be able to start the postmaster.

Poul L. Christiansen

On Tue, 8 May 2001, John Clark L. Naldoza wrote:

Show quoted text

Hi,

I recently came across a problem wherein I am not able to start my
postgreSQL 7.0.3 server.

Here's what happens..;-(

postgres@kahoy /root$ postmaster -D /var/lib/pgsql/data
FATAL: StreamServerPort: bind() failed: Permission denied
Is another postmaster already running on that port?
If not, remove socket node (/tmp/.s.PGSQL.5432) and retry.
/usr/bin/postmaster: cannot create UNIX stream port

There is no one binding the 5432 port, and no one is trying to connect
to that port. I may be left with no other alternative and restart from
scratch...;-(

There are some pretty important data currently in the database that I'd
like to recover...

Is there any way wherein I could recover or reconstruct the data?

Cheers,

John Clark

P.S. I'm using Trustix 1.4.80..;-)

--
/) John Clark Naldoza y Lopez (\
/ ) Software Design Engineer II ( \
_( (_ _ Web-Application Development _) )_
(((\ \> /_> Cable Modem Network Management System <_\ </ /)))
(\\\\ \_/ / NEC Telecom Software Phils., Inc. \ \_/ ////)
\ / \ /
\ _/ phone: (+63 32) 233-9142 loc. 3112 \_ /
/ / cellphone: (+63 919) 399-4742 \ \
/ / email: njclark@ntsp.nec.co.jp \ \

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://www.postgresql.org/search.mpl

#3Chris
csmith@squiz.net
In reply to: John Clark Naldoza y Lopez (#1)
Re: Database Recovery Help...

Hi,

Did you try what it suggests?

If you're sure PostgreSQL isn't already running, remove the
"/tmp/.s.PGSQL.5432" file, and try again.

I recently came across a problem wherein I am not able to start my
postgreSQL 7.0.3 server.

Here's what happens..;-(

postgres@kahoy /root$ postmaster -D /var/lib/pgsql/data
FATAL: StreamServerPort: bind() failed: Permission denied
Is another postmaster already running on that port?
If not, remove socket node (/tmp/.s.PGSQL.5432) and retry.
/usr/bin/postmaster: cannot create UNIX stream port

There is no one binding the 5432 port, and no one is trying to connect
to that port. I may be left with no other alternative and restart from
scratch...;-(

There are some pretty important data currently in the database that I'd
like to recover...

Is there any way wherein I could recover or reconstruct the data?

--------------
Chris Smith
http://www.squiz.net

#4John Clark Naldoza y Lopez
njclark@ntsp.nec.co.jp
In reply to: John Clark Naldoza y Lopez (#1)
Re: Database Recovery Help...

Hi,

Chris Smith wrote:

Hi,

Did you try what it suggests?

If you're sure PostgreSQL isn't already running, remove the
"/tmp/.s.PGSQL.5432" file, and try again.

That file didn't exist...;-)

--
/) John Clark Naldoza y Lopez (\
/ ) Software Design Engineer II ( \
_( (_ _ Web-Application Development _) )_
(((\ \> /_> Cable Modem Network Management System <_\ </ /)))
(\\\\ \_/ / NEC Telecom Software Phils., Inc. \ \_/ ////)
\ / \ /
\ _/ phone: (+63 32) 233-9142 loc. 3112 \_ /
/ / cellphone: (+63 919) 399-4742 \ \
/ / email: njclark@ntsp.nec.co.jp \ \

#5Justin Clift
justin@postgresql.org
In reply to: John Clark Naldoza y Lopez (#1)
Re: Re: Database Recovery Help...

Hi John,

What OS are you running it on?

For example, I've been told that Debian Linux puts its socket files in
/var/run/postgresql instead of /tmp/.

The idea here, is to find that socket file and remove it. For most
OS's, it's in /tmp/ but for yours it might not be, especially if you've
installed from a package (rpm, deb, etc).

It's something to look into.

:-)

Regards and best wishes,

Justin Clift

"John Clark L. Naldoza" wrote:

Hi,

Chris Smith wrote:

Hi,

Did you try what it suggests?

If you're sure PostgreSQL isn't already running, remove the
"/tmp/.s.PGSQL.5432" file, and try again.

That file didn't exist...;-)

--
/) John Clark Naldoza y Lopez (\
/ ) Software Design Engineer II ( \
_( (_ _ Web-Application Development _) )_
(((\ \> /_> Cable Modem Network Management System <_\ </ /)))
(\\\\ \_/ / NEC Telecom Software Phils., Inc. \ \_/ ////)
\ / \ /
\ _/ phone: (+63 32) 233-9142 loc. 3112 \_ /
/ / cellphone: (+63 919) 399-4742 \ \
/ / email: njclark@ntsp.nec.co.jp \ \

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
- Indira Gandhi

#6Tom Lane
tgl@sss.pgh.pa.us
In reply to: John Clark Naldoza y Lopez (#4)
Re: Re: Database Recovery Help...

"John Clark L. Naldoza" <njclark@ntsp.nec.co.jp> writes:

Chris Smith wrote:

Did you try what it suggests?

If you're sure PostgreSQL isn't already running, remove the
"/tmp/.s.PGSQL.5432" file, and try again.

That file didn't exist...;-)

In that case, are you sure you have write permission in /tmp ?
A "permission denied" failure on a socket is not magic, it's
just a file permissions problem ...

regards, tom lane