Jump to content
Bicrypto - Crypto Trading Platform v5.6 + All Addons + Mobile APP = 99 euro! ×

PostgreSQL ERROR: could not access status of transaction


Guy Fawkes

Recommended Posts

Posted

Давича на версии 8.2.23 получили мы такую вот хрень:
 
postgres@cn:~> psql
psql (9.2.4, сервер 8.2.23)
ПРЕДУПРЕЖДЕНИЕ: psql имеет версию 9.2, а сервер - 8.2.
                Часть функций psql может не работать.
Введите "help", чтобы получить справку.
 
postgres=# \c cndata
psql (9.2.4, сервер 8.2.23)
ПРЕДУПРЕЖДЕНИЕ: psql имеет версию 9.2, а сервер - 8.2.
                Часть функций psql может не работать.
Вы подключены к базе данных "cndata" как пользователь "postgres".
cndata=# vacuum analyze pp_movement;
ERROR:  relation "pp_movement" does not exist
cndata=# vacuum analyze cn.pp_movement;
ERROR:  could not access status of transaction 655427477
ПОДРОБНОСТИ:  Could not open file "pg_clog/0271": Нет такого файла или каталога.
cndata=# reindex table cn.pp_movement;
ERROR:  could not access status of transaction 655427477
ПОДРОБНОСТИ:  Could not open file "pg_clog/0271": Нет такого файла или каталога.
 
 
Предпосылок к возникновению такой фигни на сервере не нашли. Поэтому побродив по просторам интернета полечили таким вот способом:
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0271 bs=256K count=1
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000657219 s, 399 MB/s
cn:/opt/pgsql-8.2/data/pg_clog # chown postgres:postgres 0271
 
cndata=# select count(*) from cn.pp_movement;
ERROR:  could not access status of transaction 3332701758
ПОДРОБНОСТИ:  Could not open file "pg_clog/0C6A": Нет такого файла или каталога.
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0C6A bs=256K count=1; chown postgres:postgres *
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000499456 s, 525 MB/s
 
cndata=# select count(*) from cn.pp_movement;
ERROR:  could not access status of transaction 57351653
ПОДРОБНОСТИ:  Could not open file "pg_clog/0036": Нет такого файла или каталога.
 
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0036 bs=256K count=1; chown postgres:postgres *
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000472071 s, 555 MB/s
 
 
cndata=# select count(*) from cn.pp_movement;                                                                       
ERROR:  could not access status of transaction 1653895707                                                           
ПОДРОБНОСТИ:  Could not open file "pg_clog/0629": Нет такого файла или каталога.
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0629 bs=256K count=1; chown postgres:postgres *
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000490669 s, 534 MB/s
 
cndata=# select count(*) from cn.pp_movement;                                                                       
ERROR:  could not access status of transaction 4102869982                                                           
ПОДРОБНОСТИ:  Could not open file "pg_clog/0F48": Нет такого файла или каталога.
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0F48 bs=256K count=1; chown postgres:postgres *
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000469307 s, 559 MB/s
 
cndata=# select count(*) from cn.pp_movement;                                                                      
ERROR:  could not access status of transaction 3931397121                                                          
ПОДРОБНОСТИ:  Could not open file "pg_clog/0EA5": Нет такого файла или каталога.
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0EA5 bs=256K count=1; chown postgres:postgres *
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000490203 s, 535 MB/s
 
cndata=# select count(*) from cn.pp_movement;
ERROR:  could not access status of transaction 309829755
ПОДРОБНОСТИ:  Could not open file "pg_clog/0127": Нет такого файла или каталога.
 
cn:/opt/pgsql-8.2/data/pg_clog # dd if=/dev/zero of=0127 bs=256K count=1; chown postgres:postgres *
1+0 records in
1+0 records out
262144 bytes (262 kB) copied, 0.000480744 s, 545 MB/s
 
 
cndata=# select count(*) from cn.pp_movement;
  count 
---------
 1308439
(1 строка)
 
Походу потеряли часть транзакций, но все заработало.

 

Vi Veri Veniversum Vivus Vici

If you need help installing any software from this site or any other - write to @Guy Fawkes - we will agree for a modest reward!

guinness

 

 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...
Visa  MasterCard  Maestro  American Express  PayPal  NOWPayments СБП  МИР