I am trying to connect to my OSX installed version of PG from Windows XP SP3
running in Parallels on my mac.

When I try to connect, i get an error about no entry in the pg_hba.conf for the
ip i am trying to connect to.
I used pgAdmin3 to try to edit the file. postgresql.conf first to enable to the
pg_hba.conf dir and then the pg_hba.conf file.

Neither allows me to edit and save these files due to permissions.

I also tried to edit them through the terminal, that didnt work and also added
my user to the people allowed to read/write those two files.
Then through a text editor, it seemed to work (as well as doing it again through
pgAdmin) and then when saved, PG would not start back up.

So what is the correct process to edit these files and allow pg to be connected
to by remote host.

Thanks.
Bill

(tried posting this on the forums and got the same errors not allowing me to do
so)

Search Discussions

  • Andreas Kretschmer at Jan 4, 2011 at 5:32 pm

    Bill P. wrote:

    I am trying to connect to my OSX installed version of PG from Windows XP SP3
    running in Parallels on my mac.

    When I try to connect, i get an error about no entry in the pg_hba.conf for the
    ip i am trying to connect to.
    I used pgAdmin3 to try to edit the file. postgresql.conf first to enable to the
    pg_hba.conf dir and then the pg_hba.conf file.
    You have to edit the pg_hba.conf file on the server. I don't know if it
    is possible with pgadmin, but i doubt ...

    And i don't know what you mean with "edit the file. postgresql.conf
    first to enable to the pg_hba.conf dir".



    Andreas
    --
    Really, I'm not out to destroy Microsoft. That will just be a completely
    unintentional side effect. (Linus Torvalds)
    "If I was god, I would recompile penguin with --enable-fly." (unknown)
    Kaufbach, Saxony, Germany, Europe. N 51.05082°, E 13.56889°
  • Bill P. at Jan 4, 2011 at 7:30 pm
    In pgAdmin 3, there are choices under the file menu to edit (open) the .pgpass,
    pg_hba.conf and postgresql.conf files. That is one of the utilities I tried to
    edit these files.

    As far as the : "edit the file. postgresql.conf first to enable to the
    pg_hba.conf dir" comment.
    I was referring to the fact that the error I was getting when trying to connect
    from Windows to OSX, that stated that I didn't have a record in the pg_hda.conf
    file. In order for this file to be read and used, there is a path and attribute
    that needs to be enabled in the 'postgresql.conf' file to use the pg_hba.conf
    dir/file. I wasnt sure if there was a certain order that this all needs to be
    done in or using which method to edit these files.

    The pg_hba.conf file I am editing is on the 'server', the OSX installed version
    of PG.





    ________________________________
    From: Andreas Kretschmer <akretschmer@spamfence.net>
    To: pgsql-novice@postgresql.org
    Sent: Tue, January 4, 2011 12:32:18 PM
    Subject: Re: [NOVICE] OSX: Allow connection from remote host (actually from
    windows running in parallels)

    Bill P. wrote:
    I am trying to connect to my OSX installed version of PG from Windows XP SP3
    running in Parallels on my mac.

    When I try to connect, i get an error about no entry in the pg_hba.conf for the
    ip i am trying to connect to.
    I used pgAdmin3 to try to edit the file. postgresql.conf first to enable to the
    pg_hba.conf dir and then the pg_hba.conf file.
    You have to edit the pg_hba.conf file on the server. I don't know if it
    is possible with pgadmin, but i doubt ...

    And i don't know what you mean with "edit the file. postgresql.conf
    first to enable to the pg_hba.conf dir".



    Andreas
    --
    Really, I'm not out to destroy Microsoft. That will just be a completely
    unintentional side effect. (Linus Torvalds)
    "If I was god, I would recompile penguin with --enable-fly." (unknown)
    Kaufbach, Saxony, Germany, Europe. N 51.05082°, E 13.56889°

    --
    Sent via pgsql-novice mailing list (pgsql-novice@postgresql.org)
    To make changes to your subscription:
    http://www.postgresql.org/mailpref/pgsql-novice
  • Jan Eden at Jan 4, 2011 at 5:44 pm

    On 04.01.2011, at 17:51, Bill P. wrote:

    I am trying to connect to my OSX installed version of PG from Windows XP SP3 running in Parallels on my mac.

    When I try to connect, i get an error about no entry in the pg_hba.conf for the ip i am trying to connect to.
    I used pgAdmin3 to try to edit the file. postgresql.conf first to enable to the pg_hba.conf dir and then the pg_hba.conf file.

    Neither allows me to edit and save these files due to permissions.

    I also tried to edit them through the terminal, that didnt work and also added my user to the people allowed to read/write those two files.
    Then through a text editor, it seemed to work (as well as doing it again through pgAdmin) and then when saved, PG would not start back up.
    You could check the most recent log file in /Library/PostgreSQL/9.0/data/pg_log – it will tell you why the server restart failed.
    So what is the correct process to edit these files and allow pg to be connected to by remote host.
    AFAIK, Parallels creates some virtual network adapter, so the virtualized Windows environment would have to go through this adapter to the "physical" localhost (127.0.0.1). I have not tried to do this before, so I cannot help you here.

    Kind regards,
    Jan

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppgsql-novice @
categoriespostgresql
postedJan 4, '11 at 4:51p
activeJan 4, '11 at 7:30p
posts4
users3
websitepostgresql.org
irc#postgresql

People

Translate

site design / logo © 2021 Grokbase