File: environ.html

package info (click to toggle)
mpsql 2.1-2
  • links: PTS
  • area: non-free
  • in suites: potato
  • size: 3,528 kB
  • ctags: 4,886
  • sloc: ansic: 35,184; makefile: 3,761; sh: 44
file content (236 lines) | stat: -rw-r--r-- 4,703 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML
><HEAD
><TITLE
>Setting Up Your Environment</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet version 1.19"><LINK
REL="HOME"
TITLE="PostgreSQL User's Guide"
HREF="user.html"><LINK
REL="PREVIOUS"
TITLE="Copyrights and Trademarks"
HREF="intro317.html"><LINK
REL="NEXT"
TITLE="Managing a Database"
HREF="manage.html"></HEAD
><BODY
BGCOLOR="#FFFFFF"
TEXT="#000000"
><DIV
CLASS="NAVHEADER"
><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TH
COLSPAN="3"
ALIGN="center"
>PostgreSQL User's Guide</TH
></TR
><TR
><TD
WIDTH="10%"
ALIGN="left"
VALIGN="bottom"
><A
HREF="intro317.html"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
></TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="manage.html"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><H1
><A
NAME="ENVIRON"
>Chapter 2. Setting Up Your Environment</A
></H1
><P
>     This section discusses how to set up
     your own environment  so  that  you  can  use  frontend
     applications.  We assume <SPAN
CLASS="PRODUCTNAME"
>Postgres</SPAN
> has already been 
     successfully installed and started; refer to the Administrator's Guide
and the installation  notes
     for how to install Postgres.</P
><P
><SPAN
CLASS="PRODUCTNAME"
>Postgres</SPAN
> is a client/server application. As a user,
you only need access to the client portions of the installation (an example
of a client application is the interactive monitor <SPAN
CLASS="APPLICATION"
>psql</SPAN
>).
     For simplicity,
     we will assume that <SPAN
CLASS="PRODUCTNAME"
>Postgres</SPAN
> has been installed in  the
     directory  <TT
CLASS="FILENAME"
>/usr/local/pgsql</TT
>.   Therefore, wherever
     you see the directory <TT
CLASS="FILENAME"
>/usr/local/pgsql</TT
> you  should
     substitute  the name of the directory where <SPAN
CLASS="PRODUCTNAME"
>Postgres</SPAN
> is
     actually installed.
     All <SPAN
CLASS="PRODUCTNAME"
>Postgres</SPAN
> commands are installed  in  the  directory
     <TT
CLASS="FILENAME"
>/usr/local/pgsql/bin</TT
>.   Therefore,  you should add
     this directory to your shell command path.  If you  use
     a variant of the Berkeley C shell, such as <SPAN
CLASS="APPLICATION"
>csh</SPAN
> or <SPAN
CLASS="APPLICATION"
>tcsh</SPAN
>,
     you would add
<PRE
CLASS="PROGRAMLISTING"
>set path = ( /usr/local/pgsql/bin path )</PRE
>
     in the <TT
CLASS="FILENAME"
>.login</TT
> file in your home directory.  If you  use
     a  variant  of  the  Bourne  shell, such as <SPAN
CLASS="APPLICATION"
>sh</SPAN
>, <SPAN
CLASS="APPLICATION"
>ksh</SPAN
>, or
     <SPAN
CLASS="APPLICATION"
>bash</SPAN
>, then you would add
<PRE
CLASS="PROGRAMLISTING"
>PATH=/usr/local/pgsql/bin PATH
export PATH</PRE
>
     to the <TT
CLASS="FILENAME"
>.profile</TT
> file in your home directory.
     From now on, we will assume that  you  have  added  the
     <SPAN
CLASS="PRODUCTNAME"
>Postgres</SPAN
>  bin  directory to your path.  In addition, we
     will make frequent reference to &#8220;setting a shell  
     variable&#8221;  or  &#8220;setting an environment variable&#8221; throughout
     this document.  If you did  not  fully  understand  the
     last  paragraph  on  modifying  your  search  path, you
     should consult the UNIX manual pages that describe your
     shell before going any further.</P
><P
>If your site administrator has not set things up in the
default  way,  you may have some more work to do.  For example, if the database
 server machine is a remote machine, you
will need to set the <SPAN
CLASS="ACRONYM"
>PGHOST</SPAN
> environment variable to the name
of the database server machine.   The  environment  variable
<SPAN
CLASS="ACRONYM"
>PGPORT</SPAN
> may also have to be set.  The bottom line is this: if
you try to start an application  program  and  it  complains
that it cannot connect to the <SPAN
CLASS="APPLICATION"
>postmaster</SPAN
>,
 you should immediately consult your site administrator to make sure that your
environment is properly set up.</P
><DIV
CLASS="NAVFOOTER"
><HR
ALIGN="LEFT"
WIDTH="100%"><TABLE
WIDTH="100%"
BORDER="0"
CELLPADDING="0"
CELLSPACING="0"
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
><A
HREF="intro317.html"
>Prev</A
></TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="user.html"
>Home</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
><A
HREF="manage.html"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>Copyrights and Trademarks</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
>;</TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Managing a Database</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>