473,602 Members | 2,774 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

open of /usr/lib/pgsql/data/pg_clog/0F3E failed

Hi:

I'm running a large database on PostgreSQL 7.1.3. 20 days ago the
database failed with a threatening and not too descriptive error like:

pg_exec() query failed: server closed the connection unexpectedlyThi s
probably means the server terminated abnormally before or while
processing the request.

I lost some data and had to recreate a table, without knowing the reason
for the error, now I got this error:

FATAL 2: open of /usr/lib/pgsql/data/pg_clog/0F3E failed: No existe el
fichero o el directorio
server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.

When I VACUUM the affected table I get:

FATAL 2: open of /usr/lib/pgsql/data/pg_clog/0F5C failed: No existe el
fichero o el directorio
server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.
The connection to the server was lost. Attempting reset: NOTICE:
Message from PostgreSQL backend:
The Postmaster has informed me that some other backend
died abnormally and possibly corrupted shared memory.
I have rolled back the current transaction and am
going to terminate your database system connection and exit.
Please reconnect to the database system and repeat your query.
Failed.

I guess I have lost again some data in one table.

Someone can help with the origin of these errors? How can I avoid them?

Thanks in advance.

---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

Nov 23 '05 #1
6 2673
ruben <ru*****@superg uai.com> writes:
I lost some data and had to recreate a table, without knowing the reason
for the error, now I got this error: FATAL 2: open of /usr/lib/pgsql/data/pg_clog/0F3E failed: No existe el
fichero o el directorio


This looks like one of the common symptoms of corrupted data
(specifically, you have a trashed transaction number in some row header,
which causes the code to try to look up the transaction status in a
portion of clog that doesn't exist yet).

The most likely bet is that you are having intermittent hardware
problems causing data corruption. I'd suggest testing the hardware as
best you can. memtest86 and badblocks are a couple of widely-used test
programs for RAM and disk respectively.

As for trying to recover your data, you can look in the mailing list
archives for prior discussions of coping with data corruption. The
particular rows or pages that are corrupt are probably unrecoverable,
but you can zero them out and at least make the rest of the table
readable. First you need to stabilize the hardware, though.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Nov 23 '05 #2
Hi:

Lately I run into some problems with postmaster fatal errors, corrupted
data and indexes, lost tuples, etc. I was advised to check hardware,
I'll do so.

Today, one of the processes running daily took 4 hours when it takes
about 5 minutes. After a VACCUM ANALYZE of the affected tables it took
the same to finish, then I recreated (drop and create) the index of the
affected table and the process when again fast. My question is, isn't
enough to run a VACCUM to optimize a table and its indexes? Is it
advisable to recreate indexes from time to time?

Thanks in advance.

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Nov 23 '05 #3
In article <41************ **@superguai.co m>,
ruben <ru*****@superg uai.com> writes:
Today, one of the processes running daily took 4 hours when it takes
about 5 minutes. After a VACCUM ANALYZE of the affected tables it took
the same to finish, then I recreated (drop and create) the index of
the affected table and the process when again fast. My question is,
isn't enough to run a VACCUM to optimize a table and its indexes? Is
it advisable to recreate indexes from time to time?


This was necessary in PostgreSQL up to 7.3.x, but 7.4.x is supposed to
fix that. What version are you running?
---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

Nov 23 '05 #4
Thanks Harald, i'm running PostgreSQL 7.1.3.

Harald Fuchs wrote:
In article <41************ **@superguai.co m>,
ruben <ru*****@superg uai.com> writes:

Today, one of the processes running daily took 4 hours when it takes
about 5 minutes. After a VACCUM ANALYZE of the affected tables it took
the same to finish, then I recreated (drop and create) the index of
the affected table and the process when again fast. My question is,
isn't enough to run a VACCUM to optimize a table and its indexes? Is
it advisable to recreate indexes from time to time?

This was necessary in PostgreSQL up to 7.3.x, but 7.4.x is supposed to
fix that. What version are you running?
---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings


---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faqs/FAQ.html

Nov 23 '05 #5
Unfortunately, the administrative overhead in 7.1.3 is noticeably higher
than it is in 7.4. The overhead should be lowered even more in 8.0 with
the integration of the autovacuum daemon into the backend process.

On Fri, 2004-08-06 at 10:24, ruben wrote:
Thanks Harald, i'm running PostgreSQL 7.1.3.

Harald Fuchs wrote:
In article <41************ **@superguai.co m>,
ruben <ru*****@superg uai.com> writes:

Today, one of the processes running daily took 4 hours when it takes
about 5 minutes. After a VACCUM ANALYZE of the affected tables it took
the same to finish, then I recreated (drop and create) the index of
the affected table and the process when again fast. My question is,
isn't enough to run a VACCUM to optimize a table and its indexes? Is
it advisable to recreate indexes from time to time?

This was necessary in PostgreSQL up to 7.3.x, but 7.4.x is supposed to
fix that. What version are you running?
---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings


---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faqs/FAQ.html

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

Nov 23 '05 #6
Scott Marlowe wrote:
Unfortunately, the administrative overhead in 7.1.3 is noticeably higher
than it is in 7.4. The overhead should be lowered even more in 8.0 with
the integration of the autovacuum daemon into the backend process.


May be the autovacuum will be integrated in the version 8.1 and not in the
version 8.0. However the pg_autovacuum is not enough, I suggest at least
once a day perform a vacuum full and a reindex for tables eavily updated.
Regards
Gaetano Mendola
Nov 23 '05 #7

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

Similar topics

0
1674
by: news.paradise.net.nz | last post by:
My database appears to be a little corrupted, so far it's running along 99% ok, but i am getting some strange results. Primarily i can't back it up because of the following error. Similar errors occur when I try to drop a table. boo:/var/backups# su postgres pg_dump rj > /var/backups/rj.dump pg_dump: FATAL 2: open of /var/lib/postgres/data/pg_clog/0004 failed: No such file or directory pg_dump: lost synchronization with server,...
1
1775
by: Hema Sekhar | last post by:
Hi I am Hemasekhar K.P I am trying to replicae pgsql on REDHATLinux 8, but the site http://gborg.postgresql.org/genpage?replication_72install. is giving instructions on REDHATLinux 7, is there any site which gives instructions on how to replicate on REDHATLinux 8, Actually in postgresql.conf which is under /usr/local/pgsql/data/postgresql.conf, I added the following lines
1
5680
by: Phil Campaigne | last post by:
Hi All, Took a break from developing on pgsql 7.3 to set up network printing where I added another host(localhost 193.168.1.2) in red hat network settings. Later, I could start postmaster but when I started psql I got the following error when I issue this command: psql -h localhost -U postgres nba -bash-2.05b$ psql -h localhost -U postgres nba psql: error while loading shared libraries: libpq.so.3: cannot open
2
5470
by: Adam Haberlach | last post by:
We had one of our databases suddenly try to reference a pg_clog file that didn't exist whenever we attempted to select from a certain table. Anyone know of a way to recover from this? Is there a way to reset the transaction logs and just use whatever data is actually stored in the system? -- Adam Haberlach | "We spent the 90's all trying to figure out adam@mediariffic.com | how to get email and the 00's trying to...
1
1546
by: NTPT | last post by:
Hi I try to upgrade postgresql 7.3.3 to 7.4.3 on my machine running Apache 2.0.49 and PHP 4.3.7 Because i use another path for postgres 7.4 there (luckily) stay a old libpg So while i compile php with --with-pgsql=shared an old, 7.3.3 libpg is used by PHP. Everything fine, run and works.
3
8979
by: Glen Parker | last post by:
First things first: Postgresql 8.4.2 on Fedora Core 2 X86. Something seems to have happened to my pg_xlog and pg_clog directories after (I believe) a power outage. In the course of trying to figure out why the server wouldn't start, I cleaned out pg_clog and pg_xlog, in an obviously vain attempt to reset things. I was under the impression that the server could start without those files. Now I seem to be stuck. So now what?
9
5000
by: Matthew T. O'Connor | last post by:
Hello, pg_dump started failing for one of my databases, so I looked in to it and it appears that I have some corrupted data or something. I assume this is related to a failed hard disk that was part of the linux software raid mirror. I backed up the entire data directory, and did a pg_resetxlog, but that didn't help. I found the specific row that seems to be the problem, but I can't delete it. Anyway, I don't know how to fix this,...
2
2872
by: dennist685 | last post by:
Can't open Northwind I remembered doing walkthrough using Northwind. However it wasn't an http project but a file project using the development server. Northwind allowed me to add, edit and insert, and the web page looked fine. I opened a simple project just to see whether I could get my sqlserver on the internet. (vs studio 2005, sqlserver 2005)
6
14608
by: Frieder Bürzele | last post by:
Hi, Im trying to integrate a rss feed into my page but struggle to fetch the dynamic generation of the rss feed If I type this into the browser as a result the xml file is shown as expected http://svnweb.tuxfamily.org/rss.php?repname=proaudio+%28ckpp%29&path=%2F&rev=0&sc=0&isdir=1 If I use it with a php-script which opens the url with fopen etc.
0
8404
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8054
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
6730
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
5867
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5440
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
3944
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2418
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1510
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1254
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.