Re: Cannot get a backup using a script

From: JORGE MALDONADO <jorgemal1960(at)gmail(dot)com>
To: Ken Benson <Ken(at)infowerks(dot)com>
Cc: Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>, "pgsql-novice(at)postgresql(dot)org" <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Cannot get a backup using a script
Date: 2015-11-26 17:25:27
Message-ID: CAAY=A78QbqeU=OiMxfY=cxQLYjN3hsK5eOpY2GePY-5Ag1KLVg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Yes, I did it already.

Thank you.

On Thu, Nov 26, 2015 at 10:32 AM, Ken Benson <Ken(at)infowerks(dot)com> wrote:

> Be certain you change APPDATA back like it was – that’s a HUGE problem in
> a windows server.
>
>
>
>
>
> Writes,
>
>
>
> *Ken Benson* | Director, Development | InfoWerks Data Services, Inc. |
> 817.253.7867 (direct) | infowerks.com
>
>
>
> *From:* pgsql-novice-owner(at)postgresql(dot)org [mailto:
> pgsql-novice-owner(at)postgresql(dot)org] *On Behalf Of *JORGE MALDONADO
> *Sent:* Thursday, November 26, 2015 8:30 AM
> *To:* Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
> *Cc:* pgsql-novice(at)postgresql(dot)org
> *Subject:* Re: [NOVICE] Cannot get a backup using a script
>
>
>
> My BIG mistake !!!
>
> Yes, the content of "pgpass.conf" file was "localhot" instead of
> "localhost". The script has run successfully.
>
>
>
> I appreciate the effort of all of you who kindly invested your valuable
> time helping me.
>
>
>
> Respectfully,
>
> Jorge Maldonado
>
>
>
>
>
> On Thu, Nov 26, 2015 at 10:24 AM, Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
> wrote:
>
> JORGE MALDONADO wrote:
> >>> I have been trying to get automated backups of a PostgreSQL database
> using a script without success.
> >>> The error I get is "fe_sendauth: no password supplied".
> >>>
> >>> I have a pgpass.conf in
> "C:\Users\Username\AppData\Roaming\postgresql\pgpass.conf" with the correct
> >>> information: localhot:5432:dbname:postgres:mypassword
> >>
> >> Is this "Username" literally?
> >>
> >> What do you get for "echo %APPDATA%"?
> >>
> >> The path should be %APPDATA%\postgresql\pgpass.conf
>
> > I wrote "Username" only to show that a user name must be provided. It is
> actually the administrator of
> > the domain.
> >
> > If I issue the "echo %APPDATA%" command I get
> "c:\Users\Administrator\AppData\Roaming".
> >
> > I tested issuing the following command:
> > SET
> PGPASSFILE="C:\Users\Administrator\AppData\Roaming\postgresql\pgpass.conf"
> >
> > And then "echo %APPDATA%" again, and I still get
> "c:\Users\Administrator\AppData\Roaming"
> >
> > Is there any relation between these 2 commands?
> >
> > Another test I did was to SET
> APPDATA="C:\Users\Adminstrator\AppData\Roaming\postgresql\pgpass.conf"
> > After this, I did "echo %APPDATA%" and I get the correct path. Then I
> issue pg_dump but I still get
> > the same error message.
>
> You should not change APPDATA; this is set by the Windows operating system.
>
> This environment variable changes depending on who is logged on.
>
> Does PostgreSQL run as "Administrator" user? I hope not.
>
> You will have to find out the value of APPDATA for the PostgreSQL user and
> place pgpass.conf in %APPDATA%\postgresql of that user.
>
> If you are confused, ask a Windows system administrator.
>
> Yours,
> Laurenz Albe
>
>
>

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Shmagi Kavtaradze 2015-11-30 17:00:40 Parallel Execution of Query
Previous Message Ken Benson 2015-11-26 16:32:02 Re: Cannot get a backup using a script