Обсуждение: Incomplete dump?
When trying to dump a database for upgrading to the current PSQL version using pg_dump I observed the following: The process seems to have finished without problems, but the resulting dump file does not end in -- -- PostgreSQL database dump complete -- but rather with a command line (complete, not truncated as might be the case when running out of disk space, which was plenty anyway) Is this an indication of an incomplete dump? If so how could one proceed? The dump file size is 5046664027 bytes and I can not easily test a restore on another machine .... Any help would be appreciated Benno -- Benno Pütz Statistische Genetik Max-Planck-Institut f. Psychiatrie Tel.: +49-89-30622-222 Kraepelinstr. 10 Fax : +49-89-30622-601 80804 München, Germany
=?ISO-8859-1?Q?Benno_P=FCtz?= <puetz@mpipsykl.mpg.de> writes: > When trying to dump a database for upgrading to the current PSQL version > using pg_dump I observed the following: Which version of pg_dump were you using, exactly? > The process seems to have finished without problems, but the resulting > dump file does not end in > -- > -- PostgreSQL database dump complete > -- > but rather with a command line (complete, not truncated as might be the > case when running out of disk space, which was plenty anyway) > Is this an indication of an incomplete dump? If so how could one proceed? I don't remember which version of pg_dump started adding that trailer. If it's an old copy then maybe you're OK. If it should have a trailer and doesn't then you're right to be suspicious. Could pg_dump have been operating under a file-size ulimit that stopped it early? regards, tom lane
Tom Lane wrote: >=?ISO-8859-1?Q?Benno_P=FCtz?= <puetz@mpipsykl.mpg.de> writes: > > >>When trying to dump a database for upgrading to the current PSQL version >>using pg_dump I observed the following: >> >> > >Which version of pg_dump were you using, exactly? > > > >>The process seems to have finished without problems, but the resulting >>dump file does not end in >> >> > > > >>-- >>-- PostgreSQL database dump complete >>-- >> >> > > > >>but rather with a command line (complete, not truncated as might be the >>case when running out of disk space, which was plenty anyway) >> >> > > > >>Is this an indication of an incomplete dump? If so how could one proceed? >> >> > >I don't remember which version of pg_dump started adding that trailer. >If it's an old copy then maybe you're OK. If it should have a trailer >and doesn't then you're right to be suspicious. > This may well be the reason, The version in question is 7.4.8 (hence my wish to upgrade) while my backup script worked with a newer (8.0) DB and was copied over ... Does anybody know when the trailer was added? >Could pg_dump have been >operating under a file-size ulimit that stopped it early? > > regards, tom lane > > > > > "ulimit -a"reports: core file size (blocks, -c) 0 data seg size (kbytes, -d) unlimited file size (blocks, -f) unlimited max locked memory (kbytes, -l) 32 max memory size (kbytes, -m) unlimited open files (-n) 1024 pipe size (512 bytes, -p) 8 stack size (kbytes, -s) unlimited cpu time (seconds, -t) unlimited max user processes (-u) 8192 virtual memory (kbytes, -v) unlimited so I don't think this to be the problem. Thanks Benno -- Benno Pütz Statistische Genetik Max-Planck-Institut f. Psychiatrie Tel.: +49-89-30622-222 Kraepelinstr. 10 Fax : +49-89-30622-601 80804 München, Germany
=?ISO-8859-1?Q?Benno_P=FCtz?= <puetz@mpipsykl.mpg.de> writes: > Does anybody know when the trailer was added? Try dumping an empty database (eg template1) with that same copy of pg_dump and see what it does. regards, tom lane
am 26.05.2006, um 14:33:37 +0200 mailte Benno Pütz folgendes: > >I don't remember which version of pg_dump started adding that trailer. > >If it's an old copy then maybe you're OK. If it should have a trailer > >and doesn't then you're right to be suspicious. > This may well be the reason, The version in question is 7.4.8 (hence my > wish to upgrade) while my backup script worked with a newer (8.0) DB and > was copied over ... In this case, you should better use the pg_dump from the 8.0-Version. Btw.: 8.0 is 'out of date', we have 8.1.4... Andreas -- Andreas Kretschmer (Kontakt: siehe Header) Heynitz: 035242/47215, D1: 0160/7141639 GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net === Schollglas Unternehmensgruppe ===
Tom Lane wrote: >=?ISO-8859-1?Q?Benno_P=FCtz?= <puetz@mpipsykl.mpg.de> writes: > > >>Does anybody know when the trailer was added? >> >> > >Try dumping an empty database (eg template1) with that same copy of >pg_dump and see what it does. > > > Indeed, it does not include the trailer ... I'll try getting a newer pg_dump running on that machine and then proceed with the upgrade ... Thanks a lot Benno -- Benno Pütz Statistische Genetik Max-Planck-Institut f. Psychiatrie Tel.: +49-89-30622-222 Kraepelinstr. 10 Fax : +49-89-30622-601 80804 München, Germany
=?ISO-8859-1?Q?Benno_P=FCtz?= <puetz@mpipsykl.mpg.de> writes: > I'll try getting a newer pg_dump running on that machine and then > proceed with the upgrade ... Don't forget pg_dump can work across the network; you don't necessarily have to have a newer one on the same machine. regards, tom lane