diff options
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/backup.sgml | 25 | ||||
-rw-r--r-- | doc/src/sgml/ref/pg_dump.sgml | 22 | ||||
-rw-r--r-- | doc/src/sgml/ref/pg_dumpall.sgml | 32 | ||||
-rw-r--r-- | doc/src/sgml/ref/pg_restore.sgml | 19 |
4 files changed, 61 insertions, 37 deletions
diff --git a/doc/src/sgml/backup.sgml b/doc/src/sgml/backup.sgml index 160cb0bba1b..ba1b6c9b21c 100644 --- a/doc/src/sgml/backup.sgml +++ b/doc/src/sgml/backup.sgml @@ -1,4 +1,4 @@ -<!-- $Header: /cvsroot/pgsql/doc/src/sgml/backup.sgml,v 2.7 2001/03/19 16:19:26 petere Exp $ --> +<!-- $Header: /cvsroot/pgsql/doc/src/sgml/backup.sgml,v 2.8 2001/05/17 21:12:48 petere Exp $ --> <chapter id="backup"> <title>Backup and Restore</title> @@ -61,11 +61,10 @@ pg_dump <replaceable class="parameter">dbname</replaceable> > <replaceable cl As any other <productname>Postgres</> client application, <application>pg_dump</> will by default connect with the database user name that is equal to the current Unix user name. To override - this, either specify the <option>-u</option> option to force a prompt for - the user name, or set the environment variable - <envar>PGUSER</envar>. Remember that <application>pg_dump</> - connections are subject to the normal client authentication - mechanisms (which are described in <xref + this, either specify the <option>-U</option> option or set the + environment variable <envar>PGUSER</envar>. Remember that + <application>pg_dump</> connections are subject to the normal + client authentication mechanisms (which are described in <xref linkend="client-authentication">). </para> @@ -163,20 +162,6 @@ pg_dumpall > <replaceable>outfile</> you have database superuser access, as that is required to restore the user and group information. </para> - - <para> - <application>pg_dumpall</application> has one little flaw: It is - not prepared for interactively authenticating to each database it - dumps. If you are using password authentication then you need to - set it the environment variable <envar>PGPASSWORD</envar> to - communicate the password the the underlying calls to - <application>pg_dump</>. More severely, if you have different - passwords set up for each database, then - <application>pg_dumpall</> will fail. You can either choose a - different authentication mechanism for the purposes of backup or - adjust the <filename>pg_dumpall</filename> shell script to your - needs. - </para> </sect2> <sect2 id="backup-dump-large"> diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml index ddcf5db63f8..be2afefc8f2 100644 --- a/doc/src/sgml/ref/pg_dump.sgml +++ b/doc/src/sgml/ref/pg_dump.sgml @@ -1,5 +1,5 @@ <!-- -$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.31 2001/03/17 16:27:31 petere Exp $ +$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.32 2001/05/17 21:12:48 petere Exp $ Postgres documentation --> @@ -46,7 +46,8 @@ Postgres documentation <arg>-Z <replaceable>0...9</replaceable></arg> <arg>-h <replaceable>host</replaceable></arg> <arg>-p <replaceable>port</replaceable></arg> - <arg>-u</arg> + <arg>-U <replaceable>username</replaceable></arg> + <arg>-W</arg> <arg choice="plain"><replaceable>dbname</replaceable></arg> </cmdsynopsis> </refsynopsisdiv> @@ -412,13 +413,20 @@ Postgres documentation </varlistentry> <varlistentry> - <term>-u</term> + <term>-U <replaceable>username</replaceable></term> <listitem> <para> - Use password authentication. - Prompts for - <replaceable class="parameter">username</replaceable> - and <replaceable class="parameter">password</replaceable>. + Connect as the given user. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term>-W</term> + <listitem> + <para> + Force a password prompt. This should happen automatically if + the server requires password authentication. </para> </listitem> </varlistentry> diff --git a/doc/src/sgml/ref/pg_dumpall.sgml b/doc/src/sgml/ref/pg_dumpall.sgml index aa2c2a88276..bf35106c67a 100644 --- a/doc/src/sgml/ref/pg_dumpall.sgml +++ b/doc/src/sgml/ref/pg_dumpall.sgml @@ -1,5 +1,5 @@ <!-- -$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dumpall.sgml,v 1.21 2001/03/05 18:42:57 momjian Exp $ +$Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_dumpall.sgml,v 1.22 2001/05/17 21:12:48 petere Exp $ Postgres documentation --> @@ -23,9 +23,11 @@ Postgres documentation <cmdsynopsis> <command>pg_dumpall</command> <group><arg>-c</arg><arg>--clean</arg></group> + <group><arg>-g</arg><arg>--globals-only</arg></group> <arg>-h <replaceable>host</replaceable></arg> <arg>-p <replaceable>port</replaceable></arg> - <group><arg>-g</arg><arg>--globals-only</arg></group> + <arg>-U <replaceable>username</replaceable></arg> + <arg>-W</arg> </cmdsynopsis> </refsynopsisdiv> @@ -82,6 +84,15 @@ Postgres documentation </varlistentry> <varlistentry> + <term>-g, --globals-only</term> + <listitem> + <para> + Only dump global objects (users and groups), no databases. + </para> + </listitem> + </varlistentry> + + <varlistentry> <term>-h <replaceable>host</replaceable></term> <listitem> <para> @@ -106,14 +117,23 @@ Postgres documentation </varlistentry> <varlistentry> - <term>-g, --globals-only</term> + <term>-U <replaceable>username</replaceable></term> <listitem> <para> - Only dump global objects (users and groups), no databases. + Connect as the given user. </para> </listitem> </varlistentry> + <varlistentry> + <term>-W</term> + <listitem> + <para> + Force a password prompt. This should happen automatically if + the server requires password authentication. + </para> + </listitem> + </varlistentry> </variablelist> </para> @@ -128,8 +148,8 @@ Postgres documentation </refsect2> </refsect1> - <refsect1 id="app-pg-dumpall-usage"> - <title>Usage</title> + <refsect1 id="app-pg-dumpall-ex"> + <title>Examples</title> <para> To dump all databases: diff --git a/doc/src/sgml/ref/pg_restore.sgml b/doc/src/sgml/ref/pg_restore.sgml index 246154a8df2..5ab98fc0b3a 100644 --- a/doc/src/sgml/ref/pg_restore.sgml +++ b/doc/src/sgml/ref/pg_restore.sgml @@ -1,4 +1,4 @@ -<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_restore.sgml,v 1.10 2001/03/17 16:27:31 petere Exp $ --> +<!-- $Header: /cvsroot/pgsql/doc/src/sgml/ref/pg_restore.sgml,v 1.11 2001/05/17 21:12:48 petere Exp $ --> <refentry id="APP-PGRESTORE"> <docinfo> @@ -46,7 +46,8 @@ <arg> -x </arg> <arg> -h <replaceable class="parameter">host</replaceable> </arg> <arg> -p <replaceable class="parameter">port</replaceable> </arg> - <arg> -u </arg> + <arg> -U <replaceable>username</replaceable> </arg> + <arg> -W </arg> <arg> <replaceable class="parameter">archive-file</replaceable> </arg> </cmdsynopsis> </refsynopsisdiv> @@ -448,10 +449,20 @@ </varlistentry> <varlistentry> - <term>-u</term> + <term>-U <replaceable>username</replaceable></term> <listitem> <para> - Use password authentication. Prompts for user name and password. + Connect as the given user. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term>-W</term> + <listitem> + <para> + Force a password prompt. This should happen automatically if + the server requires password authentication. </para> </listitem> </varlistentry> |