[ADMIN] Retrieving data from the data files.

2008-02-26 Thread Darren Reed
For whatever reason, I seem to be plagued with issues... Whether they're hardware or operating system or a bad combinationI'm not sure yetand I find myself needing to recover from postgres not wanting to play all too often. In looking at the database data files, I notice that in (for exam

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Darren Reed
Shoaib Mir wrote: On Tue, Feb 26, 2008 at 5:13 PM, Darren Reed <[EMAIL PROTECTED] > wrote: Inserts into my table started generating an error message (see below), and there was a log message that suggested I reindex. postgres seems to start and stop ok, bu

Re: [ADMIN] Latest postgres stable version

2008-02-26 Thread Ron Mayer
Tom Lane wrote: On Tue, Feb 26, 2008 at 12:08 AM, Suresh Gupta VG <[EMAIL PROTECTED]> wrote: May I know what is the stable pgsql release and latest? This topic has been addressed very recently, see this thread: http://archives.postgresql.org/pgsql-admin/2008-02/msg00238.php Yeah - and from t

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Tom Lane
Darren Reed <[EMAIL PROTECTED]> writes: > Hmmm, from the logfile, signal 11, so it core dumped... > Of course the default built binary is -O2... > (gdb) where > #0 0x082114b8 in RelationCacheInitializePhase2 () > #1 0x0821fa67 in InitPostgres () > #2 0x081a7d8b in PostgresMain () > #3 0x0818488

[ADMIN] Retrieving data from the data files.

2008-02-26 Thread Darren Reed
For whatever reason, I seem to be plagued with issues... Whether they're hardware or operating system or a bad combinationI'm not sure yetand I find myself needing to recover from postgres not wanting to play all too often. In looking at the database data files, I notice that in (for exam

[ADMIN] encoding???

2008-02-26 Thread Carol Walter
Greetings... I'm really confused about something. I hope you'll help. I have a client who wants to use Asian Character data. The database he wants to use is set to SQL_ASCII, the default. I thought there might be an ALTER DATABASE command that would change this, but I've been through

Re: [ADMIN] encoding???

2008-02-26 Thread Hannes Dorbath
Carol Walter wrote: I'm really confused about something. I hope you'll help. I have a client who wants to use Asian Character data. The database he wants to use is set to SQL_ASCII, the default. I thought there might be an ALTER DATABASE command that would change this, but I've been through

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Phillip Smith
On Sun, Feb 24, 2008 at 9:20 PM, Phillip Smith <[EMAIL PROTECTED]> wrote: >> PostgreSQL 8.2.4 >> RedHat ES4 >> >> I have a nightly cron job that is (supposed) to dump a specific >> database to magnetic tape: >> /usr/local/bin/pg_dump dbname > /dev/st0 >> >> This runs, and doesn't throw

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Tom Lane
"Phillip Smith" <[EMAIL PROTECTED]> writes: > On Sun, Feb 24, 2008 at 9:20 PM, Phillip Smith > <[EMAIL PROTECTED]> wrote: >> A couple of possible things to try; pg_dump to a text file and try > cat'ting that to the tape drive, or pipe it through tar and then to the > tape. > What would the correct

Re: [ADMIN] encoding???

2008-02-26 Thread Ivo Rossacher
SQL_ASCII is not really an encoding, it is more the lack of any encoding support from the server. With this setting the encoding is fully the responsibility of the client application. This is very comfortable for special cases but for most regular cases it is only asking for troubles. Therfore f

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Geoffrey
Tom Lane wrote: "Phillip Smith" <[EMAIL PROTECTED]> writes: On Sun, Feb 24, 2008 at 9:20 PM, Phillip Smith <[EMAIL PROTECTED]> wrote: A couple of possible things to try; pg_dump to a text file and try cat'ting that to the tape drive, or pipe it through tar and then to the tape. What would t

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Phillip Smith
> Coming in the middle of this thread, so slap me if I'm off base here. > tar will accept standard in as: > > tar -cf - > > the '-f -' says take input. That would be to write to stdout :) I can't figure out how to accept from stdin :( -f is where the send the output, either a file, a device (s

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Phillip Smith
>> What would the correct syntax be for that - I can't figure out how to >> make tar accept stdin: > I don't think it can. Instead, maybe dd with blocksize set equal to the tape drive's required blocksize would do? You'd have to check what options your > dd version has for padding out the last

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Steve Holdoway
On Wed, 27 Feb 2008 13:48:38 +1100 "Phillip Smith" <[EMAIL PROTECTED]> wrote: > > Coming in the middle of this thread, so slap me if I'm off base here. > > tar will accept standard in as: > > > > tar -cf - > > > > the '-f -' says take input. > > That would be to write to stdout :) I can't figu

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Phillip Smith
Sorry Steve, I missed the "reply all" by 3 pixels :) > > > tar -cf - > > > > > > the '-f -' says take input. > > > > That would be to write to stdout :) I can't figure out how to accept > > from stdin :( > > > > -f is where the send the output, either a file, a device (such as > > tape) or stdo

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Scott Marlowe
On Tue, Feb 26, 2008 at 9:38 PM, Phillip Smith <[EMAIL PROTECTED]> wrote: > > Do we think this is a Postgres problem, a Linux problem or a problem > specific to my hardware setup? Was I wrong to think that I should be able to > stream directly from pg_dump to /dev/st0? I would have thought it *s

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Phillip Smith
> > Do we think this is a Postgres problem, a Linux problem or a problem > > specific to my hardware setup? Was I wrong to think that I should be > > able to stream directly from pg_dump to /dev/st0? I would have > > thought it *should* work, but maybe I was wrong in the first place > > wit

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Darren Reed
Tom Lane wrote: Darren Reed <[EMAIL PROTECTED]> writes: > Hmmm, from the logfile, signal 11, so it core dumped... > Of course the default built binary is -O2... > (gdb) where > #0 0x082114b8 in RelationCacheInitializePhase2 () > #1 0x0821fa67 in InitPostgres () > #2 0x081a7d8b in PostgresMain

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Tom Lane
Darren Reed <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Hm, if you are really lucky, this is because of a corrupt >> pg_internal.init file. > How do I know which files those are? find $PGDATA -name pg_internal.init regards, tom lane ---(end o

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Darren Reed
Tom Lane wrote: Darren Reed <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Hm, if you are really lucky, this is because of a corrupt >> pg_internal.init file. > How do I know which files those are? find $PGDATA -name pg_internal.init Doesn't exist. Darren ---(e

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Scott Marlowe
On Tue, Feb 26, 2008 at 10:20 PM, Phillip Smith <[EMAIL PROTECTED]> wrote: > > > > Do we think this is a Postgres problem, a Linux problem or a problem > > > specific to my hardware setup? Was I wrong to think that I should be > > > able to stream directly from pg_dump to /dev/st0? I would have

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Phillip Smith
> > > > Do we think this is a Postgres problem, a Linux problem or a > > > > problem specific to my hardware setup? Was I wrong to think > > > > that I should be able to stream directly from pg_dump to > > > > /dev/st0? I would have thought it *should* work, but maybe > > > > I was wrong in

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Tom Lane
Darren Reed <[EMAIL PROTECTED]> writes: >>> How do I know which files those are? >> >> find $PGDATA -name pg_internal.init > Doesn't exist. Sucks to be you, then :-( I'm curious though exactly where the failure is, because there's not much in RelationCacheInitializePhase2 that looks like it cou

Re: [ADMIN] Backup to Tape Incomplete

2008-02-26 Thread Tom Lane
"Scott Marlowe" <[EMAIL PROTECTED]> writes: > I wonder what it's meaning by invalid arg? On my Fedora machine, "man write" explains EINVAL thusly: EINVAL fd is attached to an object which is unsuitable for writing; or the file was opened with the O_DIRECT flag, and eith

Re: [ADMIN] How to reindex when unable to open relation?

2008-02-26 Thread Darren Reed
Tom Lane wrote: Darren Reed <[EMAIL PROTECTED]> writes: >>> How do I know which files those are? >> >> find $PGDATA -name pg_internal.init > Doesn't exist. Sucks to be you, then :-( I'm curious though exactly where the failure is, because there's not much in RelationCacheInitializePhase2 tha