From: | Jeff Frost <jeff(at)frostconsultingllc(dot)com> |
---|---|
To: | Gaetano Mendola <mendola(at)bigfoot(dot)com> |
Cc: | pgsql-admin(at)postgresql(dot)org |
Subject: | Re: archive_command |
Date: | 2005-10-15 17:28:03 |
Message-ID: | Pine.LNX.4.64.0510151021130.31923@discord.dyndns.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Looks like using that FILE= expression, I ended up with a bad file choice last
night immediately after the base backup:
Copying 0000000100000015000000F8.0088A490.backup to
/mnt/pgbackup/pitr/0000000100000015000000F8.0088A490.backup
Also, I noticed that rsync had a file disappear out from under it during the
base backup:
file has vanished: "/usr/local/pgsql/data/pg_subtrans/0743"
So, I have modified my FILE= expression to the following:
FILE=`ls -tp /pg_xlog/ | grep -v "backup\|/" | head -1`
Which gives me this file: 00000001000000160000002A
Given these in the pg_xlog dir.
00000001000000160000002A
00000001000000160000002B
00000001000000160000002C
00000001000000160000002D
00000001000000160000002E
00000001000000160000002F
000000010000001600000030
000000010000001600000031
Removing the -t takes yields the same result as long as I grep out the .backup
files.
On Tue, 4 Oct 2005, Gaetano Mendola wrote:
> This was the function I used to find the WAL in use:
>
> function copy_last_wal
> {
> FILE=$( ls -t1p $PGXLOG | grep -v / | head -1 )
>
> echo "Last Wal> " $FILE
>
> cp ${PGXLOG}/${FILE} ${PARTIAL}/${FILE}.tmp
> mv ${PARTIAL}/${FILE}.tmp ${PARTIAL}/${FILE}.partial
> find ${PARTIAL} -name *.partial | grep -v ${FILE} | xargs -i rm -fr {}
> }
>
--
Jeff Frost, Owner <jeff(at)frostconsultingllc(dot)com>
Frost Consulting, LLC http://www.frostconsultingllc.com/
Phone: 650-780-7908 FAX: 650-649-1954
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2005-10-15 21:03:50 | Re: scripts and ~/.psqlrc |
Previous Message | teknet | 2005-10-15 16:08:12 | scripts and ~/.psqlrc |