Re: Postgres client/server parameters?

Поиск
Список
Период
Сортировка
От Jimmie H. Apsey
Тема Re: Postgres client/server parameters?
Дата
Msg-id 3EB6914F.2080606@futuredental.com
обсуждение исходный текст
Ответ на Postgres client/server parameters?  ("Jimmie H. Apsey" <japsey@futuredental.com>)
Список pgsql-general
Thank you elein,

It's so helpful to meet an ex-Illustrite.

How did you know to call the once MI_PARAMS "pgenv"?  Also, what program
knows about this "pgenv" file or the environmental variables, PGHOST,
PGUSER, PGPORT?

This is, however, just exactly what I'm looking for.

Jim Apsey
-------------------------------------------------------------------------------------------------------------------
elein wrote:

>As an ex-illustrite, I create a file similar to the MI_PARAMS
>file for Illustra only I call it pgenv.
>In it I put the values for
>PGHOST
>PGUSER
>PGPORT
>You can also have PGDATABASE and neglect PGUSER if
>you use your own login. source or "dot" the file before
>calling your client program to define the variables in your
>current environment.
>
>Many people define these variables in their profiles or .logins.
>That is good too.  You just want to set these values in the
>client environment and then use the default connection
>settings.  On a windowsy client you are on your own.
>
>elein
>
>On Monday 28 April 2003 12:21, Jimmie H. Apsey wrote:
>
>
>>Hello again mallah,
>>Fair enough.  I am porting an application (which I wrote) comprised of
>>10 modules (i.e. stand-alone applications) which are written in C.
>> These C programs call database library functions and X Windows library
>>functions.
>>Currently, these ported C programs run just fine on the database server,
>>our only workstation and development station.  I am now trying to get
>>these same programs to work on a client workstation.  So, I need to know
>>what environment parameters are needed to be set, etc.  On the SGI
>>system I wrote and has been in production for five years, there is an
>>Illustra (which came after Postgres and INGRES in Michael Stonebraker
>>products) parameter file which contains certain directories, buffer and
>>cache sizes, password and the hostname of the database server.
>>
>>Also, I have a command line prompt for issuing commands directly to the
>>database.  For example, I have on my current Postgres server the ability
>>to type at the command prompt,
>>
>>     "/usr/bin/psql database_name"
>>
>>and I am put into the database server prompt of #.
>>
>>How do I do this on another workstation?
>>
>>Next, how do I run the C programs which access the Postgres database
>>from another workstation?
>>
>>I suspect the answer for both is similar.
>>
>>Also, I looked into the postgres.conf file you mentioned below but there
>>was no line in it which reads, "#tcp_connections=false".
>>
>>I am trying to port the SGI system to Red Hat Advanced Server 2.1 which
>>contains Postgres 7.1.3 if I read the rpm -qa results correctly.
>>
>>Thank you so much for your help and the help of others.  I am sure there
>>will be the right help out here among the Postgres Users.
>>
>>Regards to all and especially mallah@trade-india.com,
>>Jim Apsey
>>mallah@trade-india.com wrote:
>>
>>
>>
>>>>Thank you Mallah, I think I understand now how to setup the host system  with changes to GUC
>>>>and pg_hba.conf files.  But what do I need to do on  the client side as far as letting
>>>>application know which database and  where it is located?
>>>>
>>>>
>>>>
>>>>
>>>Dear Jim
>>>
>>>your application must be having some method of specifying
>>>the datasource , typically hostname,username,password and database name
>>>are asked for .
>>>
>>>In case the application is expecting an ODBC datasource you will have
>>>to download pgsqlodbc.
>>>
>>>Unless you tell us more details abt what app it is its difficult to
>>>tell
>>>regds
>>>mallah.
>>>
>>>
>>>
>>>
>>>
>>>
>>>>Thank you,
>>>>Jim Apsey
>>>>--------------------------------------------------------------------------------------------------------------->
mallah@trade-india.comwrote: 
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>>Yes you may run postmaster with -i option but its simpler to modify postgresql.conf file (also
>>>>>known as GUC)
>>>>>
>>>>>uncomment the line
>>>>>#tcp_connections=false
>>>>>
>>>>>and change false to true.
>>>>>
>>>>>then change pg_hba.conf file  to allow access from the client ip address. that file is
>>>>>exemplified .
>>>>>
>>>>>if you still face problem revert back
>>>>>
>>>>>regds
>>>>>mallah
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>>Please refer me to a source which explains in some detail how to access  a database residing
>>>>>>on a server.  I've already setup the server database  and have applications running on the
>>>>>>server which successfullly use the  Postgres database.  Now I want/need to access this
>>>>>>database from a
>>>>>>client workstation.  Please help me set needed parameters on a host and  client in order to
>>>>>>access pgsql from that client workstation.  I think I  also need to run postmaster with the
>>>>>>"-i" parameter and perhaps I need  to modify the HOST:$PGDATA/usr/local/pgsql/data/pg_hba.conf
>>>>>>file.  I  have been reading:
>>>>>>
>>>>>>http://www.ca.postgresql.org/docs/faq-english.html but I still don't  know how to do it.
>>>>>>
>>>>>>Red Hat gives no support on this simple question.  I just need a little  help or a suggestion
>>>>>>or two.
>>>>>>
>>>>>>Thank you,
>>>>>>
>>>>>>Jim Apsey
>>>>>>
>>>>>>
>>>>>>---------------------------(end of broadcast)--------------------------- TIP 6: Have you
>>>>>>searched our list archives?
>>>>>>
>>>>>>http://archives.postgresql.org
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>-----------------------------------------
>>>>>Get your free web based email at trade-india.com.
>>>>> "India's Leading B2B eMarketplace.!"
>>>>>http://www.trade-india.com/
>>>>>
>>>>>
>>>>>---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and
>>>>>unsubscribe commands go to majordomo@postgresql.org
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>
>>>-----------------------------------------
>>>Get your free web based email at trade-india.com.
>>>  "India's Leading B2B eMarketplace.!"
>>>http://www.trade-india.com/
>>>
>>>
>>>---------------------------(end of broadcast)---------------------------
>>>TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>>>
>>>
>>>
>>>
>>>
>>---------------------------(end of broadcast)---------------------------
>>TIP 6: Have you searched our list archives?
>>
>>http://archives.postgresql.org
>>
>>
>>
>>
>
>
>


В списке pgsql-general по дате отправления:

Предыдущее
От: "Bob Krus"
Дата:
Сообщение: GENERAL: PosgreSQL Inquiry
Следующее
От: Dennis Gearon
Дата:
Сообщение: Re: GENERAL: PosgreSQL Inquiry