pg_resetxlog says file system is read only? - Mailing list pgsql-hackers
From | April Lorenzen |
---|---|
Subject | pg_resetxlog says file system is read only? |
Date | |
Msg-id | [email protected] Whole thread Raw |
List | pgsql-hackers |
#postgresql freenode channel directed me to write the hackers list I have backup files. Version I believe is 7.4. pg server stopped - short log file is pasted at end of this email PANIC re checkpoint record seems to indicate running pg_resetxlog Ran pg_restxlog with -n successfully and it appeared to have numbers to work with. Then su postgres crunch-a:/var/log/postgresql$ /usr/lib/postgresql/bin/pg_resetxlog /mnt/pgdata/postgres/data The database server was not shut down cleanly. Resetting the transaction log may cause data to be lost. If you want to proceed anyway, use -f to force reset. crunch-a:/var/log/postgresql$ /usr/lib/postgresql/bin/pg_resetxlog -f /mnt/pgdata/postgres/data pg_resetxlog: could not open file "/mnt/pgdata/postgres/data/pg_xlog/000000AF00000003": Read-only file system crunch-a:/var/log/postgresql$ ls -l /mnt/pgdata/postgres/data/pg_xlog/000000AF00000003 ls: /mnt/pgdata/postgres/data/pg_xlog/000000AF00000003: No such file or directory Here is the output of pg_resetxlog -n: pg_control values: pg_control version number: 72 Catalog version number: 200310211 Current log file ID: 175 Next log file segment: 2 Latest checkpoint's StartUpID: 60 Latest checkpoint's NextXID: 193187533 Latest checkpoint's NextOID: 17127133 Database block size: 8192 Blocks per segment of large relation: 131072 Maximum length of identifiers: 64 Maximum number of function arguments: 32 Date/time type storage: 64-bit integers Maximum length of locale name: 128 LC_COLLATE: C LC_CTYPE: C Disk does not appear to be full: df -k Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda1 35001508 4130476 29093040 13% / tmpfs 518252 0 518252 0% /dev/shm /dev/sdb1 70557052 17567256 49405700 27% /mnt/pgdata /dev/sdc1 8744304 393792 7906320 5% /mnt/pglogs 65.221.104.253:/bak 344620624 264253272 80022736 77% /mnt/bak Complete log (its very short) from time where pg server quit running: 2005-08-03 08:38:27 [32119] LOG: could not create IPv6 socket: Address family not supported by protocol 2005-08-03 08:38:27 [32127] LOG: database system was interrupted at 2005-08-03 03:56:54 EDT 2005-08-03 08:38:27 [32127] LOG: could not open file "/var/lib/postgres/data/pg_xlog/000000AF00000001" (log file 175, segment 1): No such file or directory 2005-08-03 08:38:27 [32127] LOG: invalid primary checkpoint record 2005-08-03 08:38:27 [32127] LOG: could not open file "/var/lib/postgres/data/pg_xlog/000000AF00000001" (log file 175, segment 1): No such file or directory 2005-08-03 08:38:27 [32127] LOG: invalid secondary checkpoint record 2005-08-03 08:38:27 [32127] PANIC: could not locate a valid checkpoint record 2005-08-03 08:38:27 [32119] LOG: startup process (PID 32127) was terminated by signal 6 2005-08-03 08:38:27 [32119] LOG: aborting startup due to startup process failure 2005-08-03 10:08:50 [10168] LOG: could not create IPv6 socket: Address family not supported by protocol 2005-08-03 10:08:50 [10173] LOG: database system was shut down at 2005-08-03 10:05:42 EDT 2005-08-03 10:08:50 [10173] LOG: could not open file "/var/lib/postgres/data/pg_xlog/000000AF00000003" (log file 175, segment 3): No such file or directory 2005-08-03 10:08:50 [10173] LOG: invalid primary checkpoint record 2005-08-03 10:08:50 [10173] LOG: invalid secondary checkpoint link in control file 2005-08-03 10:08:50 [10173] PANIC: could not locate a valid checkpoint record 2005-08-03 10:08:50 [10168] LOG: startup process (PID 10173) was terminated by signal 6 2005-08-03 10:08:50 [10168] LOG: aborting startup due to startup process failure
pgsql-hackers by date: