pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: alien@spaceship.com
Cc: pgsql-admin@postgresql.org
Subject: Re: Capturing output of vacuumdb and pg_dump
Date: Sat, 12 Apr 2003 13:25:57 -0400
Message-ID: <18873.1050168357@sss.pgh.pa.us> (raw)
In-Reply-To: <39047.24.243.214.140.1050167917.squirrel@earth.spaceship.com>
References: <39047.24.243.214.140.1050167917.squirrel@earth.spaceship.com>

"Matt Mello" <alien@spaceship.com> writes:
> I am a linux shell [bash/sh] newbie.  I want to capture the output of the
> vacuumdb and pg_dump commands to a log file.  I want all of the lines that
> are normally displayed on the screen to be *appended* to a single log file
> that I can inspect offline at my convenience.  I have discovered that
> ">>logfile" won't get all of the data.  Can someone point me to an example
> of how to do that?

You're missing stderr.  On sh/bash type shells you want

	foo >>logfile 2>&1

There is some other locution on csh and its descendants, but I forget
what.

			regards, tom lane




view thread (2+ messages)

Message-ID: <18873.1050168357@sss.pgh.pa.us>
Permalink:  ../18873.1050168357@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/18873.1050168357@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: tgl@sss.pgh.pa.us, alien@spaceship.com
  Subject: Re: Capturing output of vacuumdb and pg_dump
  In-Reply-To: <18873.1050168357@sss.pgh.pa.us>
  References: <39047.24.243.214.140.1050167917.squirrel@earth.spaceship.com> <18873.1050168357@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox