Обсуждение: suggestion for improving TMPDIR and "--format" docs for pg_dump

Поиск
Список
Период
Сортировка

suggestion for improving TMPDIR and "--format" docs for pg_dump

От
Mark Stosberg
Дата:
A suggested addition to the pg_dump docs:

This would be an extension to the documentation for the "tar" format:

The tar format needs some space to create temporary files. By default
"/tmp" is used. On systems with small "/tmp" partitions, set the
"TMPDIR" environment variable to a location with more space, such as
"/usr/tmp".

Also, I would like it if the pg_dump docs more assertively recommended
one of the "tar" or "custom" formats. They seem very similiar.

It woud also be nice to document that the full names "custom" and "tar" are
supported. Longer names can be nice for clarity.

( Unfortunately, wrong formats like "txx" also work instead of throwing
an error. )

    Mark

Re: suggestion for improving TMPDIR and "--format" docs for pg_dump

От
Peter Eisentraut
Дата:
Am Freitag, 9. März 2007 03:30 schrieb Mark Stosberg:
> The tar format needs some space to create temporary files. By default
> "/tmp" is used. On systems with small "/tmp" partitions, set the
> "TMPDIR" environment variable to a location with more space, such as
> "/usr/tmp".

That is really standard operating system behavior.  We don't need to duplicate
that information.

> It woud also be nice to document that the full names "custom" and "tar" are
> supported. Longer names can be nice for clarity.

They are.  You must be looking at an older version.

> ( Unfortunately, wrong formats like "txx" also work instead of throwing
> an error. )

Send a patch.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

Re: suggestion for improving TMPDIR and "--format" docs for pg_dump

От
Mark Stosberg
Дата:
Peter Eisentraut wrote:
> Am Freitag, 9. März 2007 03:30 schrieb Mark Stosberg:
>> The tar format needs some space to create temporary files. By default
>> "/tmp" is used. On systems with small "/tmp" partitions, set the
>> "TMPDIR" environment variable to a location with more space, such as
>> "/usr/tmp".
>
> That is really standard operating system behavior.  We don't need to duplicate
> that information.

So is

 ./configure
 make
 make install

These are all external, standard programs, but they are common and
useful to document with applications. I think a small amount of
redundancy is documentation is a good thing.

When I wanted to use a different tmp dir, I searched the PostgreSQL docs
for how to do that, because I was using a PostgreSQL tool. I had no why
of knowing whether PostgreSQL was even using standard conventions of
tmpdir handling, of if it did it's own thing. Also, after several years
of being professional involved with Unix system maintenance, I was not
aware that this was a standard feature. Surely then, less advanced users
would benefit from the documentation.

>> It woud also be nice to document that the full names "custom" and "tar" are
>> supported. Longer names can be nice for clarity.
>
> They are.  You must be looking at an older version.

You are correct. Sorry about that.

>> ( Unfortunately, wrong formats like "txx" also work instead of throwing
>> an error. )
>
> Send a patch.

I appreciate the sentiment, by my C skills are weak.

       Mark

Re: suggestion for improving TMPDIR and "--format" docs for pg_dump

От
Bruce Momjian
Дата:
Mark Stosberg wrote:
> It woud also be nice to document that the full names "custom" and "tar" are
> supported. Longer names can be nice for clarity.
>
> ( Unfortunately, wrong formats like "txx" also work instead of throwing
> an error. )

I don't see that with current CVS:

    $ pg_dump --format=x test
    pg_dump: invalid output format "x" specified

--
  Bruce Momjian  <bruce@momjian.us>          http://momjian.us
  EnterpriseDB                               http://www.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

Re: suggestion for improving TMPDIR and "--format" docs for pg_dump

От
Mark Stosberg
Дата:
Bruce Momjian wrote:
> Mark Stosberg wrote:
>> It woud also be nice to document that the full names "custom" and "tar" are
>> supported. Longer names can be nice for clarity.
>>
>> ( Unfortunately, wrong formats like "txx" also work instead of throwing
>> an error. )
>
> I don't see that with current CVS:
>
>     $ pg_dump --format=x test
>     pg_dump: invalid output format "x" specified

Bruce,

I think the specific test case would have to start with a valid letter,
like "t", and then include invalid characters. Try this instead:

 pg_dump --format=tx test

     Mark