[08254fc] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[08254fc] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[904f4c45] | 7 | <!ENTITY postgresql-download-http "http://gd.tuwien.ac.at/db/postgresql/source/v&postgresql-version;/postgresql-&postgresql-version;.tar.bz2">
|
---|
| 8 | <!ENTITY postgresql-download-ftp "ftp://ftp5.us.postgresql.org/pub/PostgreSQL/source/v&postgresql-version;/postgresql-&postgresql-version;.tar.bz2">
|
---|
| 9 | <!-- <!ENTITY postgresql-download-http "&sources-anduin-http;/p/postgresql-&postgresql-version;.tar.bz2">
|
---|
| 10 | <!ENTITY postgresql-download-ftp "&sources-anduin-ftp;/p/postgresql-&postgresql-version;.tar.bz2"> -->
|
---|
| 11 | <!ENTITY postgresql-md5sum "315118130e1800a87f0effe69b947810">
|
---|
| 12 | <!ENTITY postgresql-size "14.1 MB">
|
---|
| 13 | <!ENTITY postgresql-buildsize "180 MB (additional 125 MB to run the testsuite)">
|
---|
| 14 | <!ENTITY postgresql-time "2.1 SBU">
|
---|
[08254fc] | 15 | ]>
|
---|
| 16 |
|
---|
[458342f] | 17 | <sect1 id="postgresql" xreflabel="PostgreSQL-&postgresql-version;">
|
---|
[4ab91cd] | 18 | <?dbhtml filename="postgresql.html"?>
|
---|
| 19 |
|
---|
| 20 | <sect1info>
|
---|
| 21 | <othername>$LastChangedBy$</othername>
|
---|
| 22 | <date>$Date$</date>
|
---|
| 23 | </sect1info>
|
---|
| 24 |
|
---|
| 25 | <title>PostgreSQL-&postgresql-version;</title>
|
---|
| 26 |
|
---|
| 27 | <indexterm zone="postgresql">
|
---|
| 28 | <primary sortas="a-PostgreSQL">PostgreSQL</primary>
|
---|
| 29 | </indexterm>
|
---|
| 30 |
|
---|
| 31 | <sect2 role="package">
|
---|
| 32 | <title>Introduction to PostgreSQL</title>
|
---|
| 33 |
|
---|
| 34 | <para><application>PostgreSQL</application> is an advanced
|
---|
| 35 | object-relational database management system (ORDBMS), derived
|
---|
| 36 | from the Berkeley Postgres database management system.</para>
|
---|
| 37 |
|
---|
[d0151ee] | 38 | <para>There may be a more recent release available from the
|
---|
| 39 | <application>PostgreSQL</application> home page. You can check
|
---|
| 40 | <ulink url="http://www.postgresql.org/"/> and probably use the
|
---|
| 41 | existing BLFS instructions. Note that versions other than the one shown
|
---|
| 42 | in the download URLs have not been tested in a BLFS environment.</para>
|
---|
| 43 |
|
---|
[a1813d08] | 44 | <!-- FIXME -->
|
---|
| 45 | <para>If you intend to link this application to <xref linkend="openssl"/>
|
---|
| 46 | you will need to move to a newer version of <application>PostgreSQL</application>,
|
---|
| 47 | 1.9.0.1 is known to build.</para>
|
---|
| 48 |
|
---|
[4ab91cd] | 49 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 50 | <itemizedlist spacing="compact">
|
---|
| 51 | <listitem>
|
---|
| 52 | <para>Download (HTTP): <ulink url="&postgresql-download-http;"/></para>
|
---|
| 53 | </listitem>
|
---|
| 54 | <listitem>
|
---|
| 55 | <para>Download (FTP): <ulink url="&postgresql-download-ftp;"/></para>
|
---|
| 56 | </listitem>
|
---|
| 57 | <listitem>
|
---|
| 58 | <para>Download MD5 sum: &postgresql-md5sum;</para>
|
---|
| 59 | </listitem>
|
---|
| 60 | <listitem>
|
---|
| 61 | <para>Download size: &postgresql-size;</para>
|
---|
| 62 | </listitem>
|
---|
| 63 | <listitem>
|
---|
| 64 | <para>Estimated disk space required: &postgresql-buildsize;</para>
|
---|
| 65 | </listitem>
|
---|
| 66 | <listitem>
|
---|
| 67 | <para>Estimated build time: &postgresql-time;</para>
|
---|
| 68 | </listitem>
|
---|
| 69 | </itemizedlist>
|
---|
| 70 |
|
---|
| 71 | <bridgehead renderas="sect3">PostgreSQL Dependencies</bridgehead>
|
---|
| 72 |
|
---|
| 73 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[a6ac43b] | 74 | <para role="optional"><xref linkend="python"/>,
|
---|
[4ab91cd] | 75 | <xref linkend="tcl"/>,
|
---|
| 76 | <xref linkend="openssl"/>,
|
---|
[904f4c45] | 77 | <xref linkend="libxml2"/>,
|
---|
| 78 | <xref linkend="libxslt"/>,
|
---|
[5230b40] | 79 | <xref linkend="openldap"/>,
|
---|
[6603f8b] | 80 | <xref linkend="linux-pam"/>,
|
---|
[4ab91cd] | 81 | <ulink url="http://www.pdc.kth.se/kth-krb/">krb4</ulink>,
|
---|
| 82 | <xref linkend="mitkrb"/> or <xref linkend="heimdal"/>, and
|
---|
[5aa1d3dd] | 83 | <ulink url="http://developer.apple.com/networking/bonjour/">Bonjour</ulink></para>
|
---|
| 84 |
|
---|
| 85 | <bridgehead renderas="sect4">Optional (To Regenerate Documentation)</bridgehead>
|
---|
| 86 | <para role="optional"><xref linkend="sgml-dtd"/>,
|
---|
| 87 | <xref linkend="docbook-dsssl"/>,
|
---|
| 88 | <xref linkend="openjade"/>, and
|
---|
| 89 | <xref linkend="perl-sgmlspm"/></para>
|
---|
[4ab91cd] | 90 |
|
---|
[3cb0c57] | 91 | <para condition="html" role="usernotes">User Notes:
|
---|
| 92 | <ulink url="&blfs-wiki;/postgresql"/></para>
|
---|
| 93 |
|
---|
[4ab91cd] | 94 | </sect2>
|
---|
| 95 |
|
---|
| 96 | <sect2 role="installation">
|
---|
| 97 | <title>Installation of PostgreSQL</title>
|
---|
| 98 |
|
---|
| 99 | <para>Install <application>PostgreSQL</application> with the
|
---|
| 100 | following commands: </para>
|
---|
[08254fc] | 101 |
|
---|
[5aa1d3dd] | 102 | <screen><userinput>sed -i "s|dsssl-stylesheets|& \\\\\n sgml/docbook/&-&docbook-dsssl-version;|" \
|
---|
[44e4099] | 103 | configure &&
|
---|
[9aeb405d] | 104 | ./configure --prefix=/usr --enable-thread-safety &&
|
---|
[4ab91cd] | 105 | make</userinput></screen>
|
---|
[44e4099] | 106 |
|
---|
[acbce59] | 107 | <para>To test the results, issue: <command>make check</command>.</para>
|
---|
| 108 |
|
---|
[4ab91cd] | 109 | <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
---|
[44e4099] | 110 |
|
---|
[7de21f4] | 111 | <screen role="root"><userinput>make install &&
|
---|
[5aa1d3dd] | 112 | chown -v root:root /usr/share/doc/postgresql/html/* &&
|
---|
[904f4c45] | 113 |
|
---|
[5aa1d3dd] | 114 | install -v -m755 -d /usr/share/doc/postgresql/{FAQ/html,TODO.detail} &&
|
---|
[904f4c45] | 115 | install -v -m644 doc/TODO \
|
---|
| 116 | /usr/share/doc/postgresql &&
|
---|
| 117 | install -v -m644 doc/FAQ* \
|
---|
| 118 | /usr/share/doc/postgresql/FAQ &&
|
---|
| 119 | install -v -m644 doc/src/FAQ/* \
|
---|
| 120 | /usr/share/doc/postgresql/FAQ/html &&
|
---|
| 121 | install -v -m644 doc/TODO.detail/* \
|
---|
| 122 | /usr/share/doc/postgresql/TODO.detail</userinput></screen>
|
---|
[11404f5] | 123 |
|
---|
[4ab91cd] | 124 | <note>
|
---|
| 125 | <para>If you are upgrading an existing system and are going to install
|
---|
| 126 | the new files over the old ones, then you should back up your data, shut
|
---|
| 127 | down the old server and follow the instructions in <ulink
|
---|
[5aa1d3dd] | 128 | url="http://www.postgresql.org/docs/8.1/static/install-upgrading.html">the
|
---|
[4ab91cd] | 129 | official <application>PostgreSQL</application> documentation</ulink>.</para>
|
---|
| 130 | </note>
|
---|
[08254fc] | 131 |
|
---|
[4ab91cd] | 132 | <para>Initialize a database cluster with the following commands issued by the
|
---|
| 133 | <systemitem class="username">root</systemitem> user:</para>
|
---|
[08254fc] | 134 |
|
---|
[aaeca54] | 135 | <screen role="root"><userinput>install -v -m700 -d /srv/pgsql/data &&
|
---|
[5aa1d3dd] | 136 | groupadd -g 41 postgres &&
|
---|
| 137 | useradd -c "PostgreSQL Server" -g postgres -d /srv/pgsql/data \
|
---|
[b785ab29] | 138 | -u 41 postgres &&
|
---|
[44e4099] | 139 | chown -v postgres /srv/pgsql/data &&
|
---|
[4ab91cd] | 140 | su - postgres -c '/usr/bin/initdb -D /srv/pgsql/data'</userinput></screen>
|
---|
[08254fc] | 141 |
|
---|
[4ab91cd] | 142 | <para>As the <systemitem class="username">root</systemitem> user, start the
|
---|
| 143 | database server with the following command:</para>
|
---|
[08254fc] | 144 |
|
---|
[4ab91cd] | 145 | <screen role="root"><userinput>su - postgres -c '/usr/bin/postmaster -D /srv/pgsql/data > \
|
---|
| 146 | /srv/pgsql/data/logfile 2>&1 &'</userinput></screen>
|
---|
[08254fc] | 147 |
|
---|
[4ab91cd] | 148 | <para>Still as user <systemitem class="username">root</systemitem>, create
|
---|
| 149 | a database and verify the installation:</para>
|
---|
[08254fc] | 150 |
|
---|
[4ab91cd] | 151 | <screen role="root"><userinput>su - postgres -c '/usr/bin/createdb test' &&
|
---|
[08254fc] | 152 | echo "create table t1 ( name varchar(20), state_province varchar(20) );" \
|
---|
| 153 | | (su - postgres -c '/usr/bin/psql test ') &&
|
---|
| 154 | echo "insert into t1 values ('Billy', 'NewYork');" \
|
---|
| 155 | | (su - postgres -c '/usr/bin/psql test ') &&
|
---|
| 156 | echo "insert into t1 values ('Evanidus', 'Quebec');" \
|
---|
| 157 | | (su - postgres -c '/usr/bin/psql test ') &&
|
---|
| 158 | echo "insert into t1 values ('Jesse', 'Ontario');" \
|
---|
| 159 | | (su - postgres -c '/usr/bin/psql test ') &&
|
---|
[4ab91cd] | 160 | echo "select * from t1;" | (su - postgres -c '/usr/bin/psql test')</userinput></screen>
|
---|
| 161 |
|
---|
| 162 | </sect2>
|
---|
| 163 |
|
---|
| 164 | <sect2 role="commands">
|
---|
| 165 | <title>Command Explanations</title>
|
---|
| 166 |
|
---|
[5aa1d3dd] | 167 | <para><command>sed -i "s|dsssl-stylesheets|..."</command>: This command
|
---|
[4ab91cd] | 168 | puts an extra line in the <command>configure</command> script so that the
|
---|
[5aa1d3dd] | 169 | BLFS installed version of the DSSSL stylesheets are discovered.</para>
|
---|
[08254fc] | 170 |
|
---|
[4ab91cd] | 171 | <para><parameter>--enable-thread-safety</parameter>: This switch makes the
|
---|
| 172 | client libraries thread-safe by allowing concurrent threads in
|
---|
| 173 | <filename class='libraryfile'>libpq</filename> and ECPG programs to safely
|
---|
| 174 | control their private connection handles.</para>
|
---|
| 175 |
|
---|
[5aa1d3dd] | 176 | <para><command>chown -R root:root /usr/share/doc/postgresql/html/*</command>:
|
---|
| 177 | This command corrects the improper ownership of documentation files.</para>
|
---|
[4ab91cd] | 178 |
|
---|
[5aa1d3dd] | 179 | <para><command>groupadd ...</command>; <command>useradd ...</command>:
|
---|
| 180 | These commands add an unprivileged user and group to run the database
|
---|
| 181 | server.</para>
|
---|
[4ab91cd] | 182 |
|
---|
| 183 | <para><command>createdb test; create table t1; insert into t1 values...;
|
---|
| 184 | select * from t1</command>: Create a database, add a table to it, insert
|
---|
| 185 | some rows into the table and select them to verify that the installation
|
---|
| 186 | is working properly.</para>
|
---|
| 187 |
|
---|
| 188 | </sect2>
|
---|
| 189 |
|
---|
| 190 | <sect2 role="configuration">
|
---|
| 191 | <title>Configuring PostgreSQL</title>
|
---|
| 192 |
|
---|
| 193 | <sect3 id="postgresql-config">
|
---|
| 194 | <title>Config Files</title>
|
---|
| 195 |
|
---|
| 196 | <para><filename>$PGDATA/pg_ident.con</filename>,
|
---|
| 197 | <filename>$PGDATA/pg_hba.conf</filename> and
|
---|
| 198 | <filename>$PGDATA/postgresql.conf</filename></para>
|
---|
| 199 |
|
---|
| 200 | <indexterm zone="postgresql postgresql-config">
|
---|
| 201 | <primary sortas="e-A.PGDATA-pg_ident.con">$PGDATA/pg_indent.con</primary>
|
---|
| 202 | </indexterm>
|
---|
| 203 |
|
---|
| 204 | <indexterm zone="postgresql postgresql-config">
|
---|
| 205 | <primary sortas="e-A.PGDATA-pg_hba.conf">$PGDATA/pg_hba_conf</primary>
|
---|
| 206 | </indexterm>
|
---|
| 207 |
|
---|
| 208 | <indexterm zone="postgresql postgresql-config">
|
---|
| 209 | <primary sortas="e-A.PGDATA-postgresql.conf">$PGDATA/postgresql.conf</primary>
|
---|
| 210 | </indexterm>
|
---|
| 211 |
|
---|
| 212 | <para>The <envar>PGDATA</envar> environment variable is used to
|
---|
| 213 | distinguish database clusters from one another by setting it to
|
---|
| 214 | the value of the directory which contains the cluster desired.
|
---|
| 215 | The three configuration files exist in every <filename
|
---|
| 216 | class="directory">PGDATA/</filename> directory. Details on the
|
---|
| 217 | format of the files and the options that can be set in each can
|
---|
| 218 | be found in <ulink
|
---|
| 219 | url="file:///usr/share/doc/postgresql/html/index.html"/>.</para>
|
---|
| 220 |
|
---|
| 221 | </sect3>
|
---|
| 222 |
|
---|
| 223 | <sect3 id="postgresql-init">
|
---|
| 224 | <title>Boot Script</title>
|
---|
| 225 |
|
---|
| 226 | <para>Install the <filename>/etc/rc.d/init.d/postgresql</filename>
|
---|
| 227 | init script included in the
|
---|
[5254d12] | 228 | <xref linkend="bootscripts"/> package.</para>
|
---|
[4ab91cd] | 229 |
|
---|
| 230 | <indexterm zone="postgresql postgresql-init">
|
---|
| 231 | <primary sortas="f-postgresql">postgresql</primary>
|
---|
| 232 | </indexterm>
|
---|
| 233 |
|
---|
| 234 | <screen role="root"><userinput>make install-postgresql</userinput></screen>
|
---|
| 235 |
|
---|
| 236 | </sect3>
|
---|
| 237 |
|
---|
| 238 | </sect2>
|
---|
| 239 |
|
---|
| 240 | <sect2 role="content">
|
---|
| 241 | <title>Contents</title>
|
---|
| 242 |
|
---|
| 243 | <segmentedlist>
|
---|
| 244 | <segtitle>Installed Programs</segtitle>
|
---|
| 245 | <segtitle>Installed Libraries</segtitle>
|
---|
| 246 | <segtitle>Installed Directories</segtitle>
|
---|
| 247 |
|
---|
| 248 | <seglistitem>
|
---|
| 249 | <seg>clusterdb, createdb, createlang, createuser, dropdb, droplang,
|
---|
| 250 | dropuser, ecpg, initdb, ipcclean, pg_config, pg_controldata, pg_ctl,
|
---|
| 251 | pg_dump, pg_dumpall, pg_resetxlog, pg_restore, pltcl_delmod,
|
---|
[aaeca54] | 252 | pltcl_listmod, pltcl_loadmod, postgres, postmaster, psql,
|
---|
| 253 | reindexdb, and vacuumdb</seg>
|
---|
[3cb0c57] | 254 | <seg>libecpg.{so,a}, libecpg_compat.{so,a}, libpgport.a, libpgtypes.{so,a},
|
---|
| 255 | libpq.{so,a}, and various charset modules.</seg>
|
---|
[4ab91cd] | 256 | <seg>/srv/pgsql, /usr/include/libpq, /usr/include/postgresql,
|
---|
| 257 | /usr/lib/postgresql, /usr/share/doc/postgresql, and
|
---|
| 258 | /usr/share/postgresql</seg>
|
---|
| 259 | </seglistitem>
|
---|
| 260 | </segmentedlist>
|
---|
| 261 |
|
---|
| 262 | <variablelist>
|
---|
| 263 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 264 | <?dbfo list-presentation="list"?>
|
---|
| 265 | <?dbhtml list-presentation="table"?>
|
---|
| 266 |
|
---|
| 267 | <varlistentry id="clusterdb">
|
---|
| 268 | <term><command>clusterdb</command></term>
|
---|
| 269 | <listitem>
|
---|
| 270 | <para>is a utility for reclustering tables in a
|
---|
| 271 | <application>PostgreSQL</application> database.</para>
|
---|
| 272 | <indexterm zone="postgresql clusterdb">
|
---|
| 273 | <primary sortas="b-clusterdb">clusterdb</primary>
|
---|
| 274 | </indexterm>
|
---|
| 275 | </listitem>
|
---|
| 276 | </varlistentry>
|
---|
| 277 |
|
---|
| 278 | <varlistentry id="createdb">
|
---|
| 279 | <term><command>createdb</command></term>
|
---|
| 280 | <listitem>
|
---|
| 281 | <para> creates a new <application>PostgreSQL</application>
|
---|
| 282 | database.</para>
|
---|
| 283 | <indexterm zone="postgresql createdb">
|
---|
| 284 | <primary sortas="b-createdb">createdb</primary>
|
---|
| 285 | </indexterm>
|
---|
| 286 | </listitem>
|
---|
| 287 | </varlistentry>
|
---|
| 288 |
|
---|
| 289 | <varlistentry id="createlang">
|
---|
| 290 | <term><command>createlang</command></term>
|
---|
| 291 | <listitem>
|
---|
| 292 | <para>defines a new <application>PostgreSQL</application> procedural
|
---|
| 293 | language.</para>
|
---|
| 294 | <indexterm zone="postgresql createlang">
|
---|
| 295 | <primary sortas="b-createlang">createlang</primary>
|
---|
| 296 | </indexterm>
|
---|
| 297 | </listitem>
|
---|
| 298 | </varlistentry>
|
---|
| 299 |
|
---|
| 300 | <varlistentry id="createuser">
|
---|
| 301 | <term><command>createuser</command></term>
|
---|
| 302 | <listitem>
|
---|
| 303 | <para>defines a new <application>PostgreSQL</application>
|
---|
| 304 | user account.</para>
|
---|
| 305 | <indexterm zone="postgresql createuser">
|
---|
| 306 | <primary sortas="b-createuser">createuser</primary>
|
---|
| 307 | </indexterm>
|
---|
| 308 | </listitem>
|
---|
| 309 | </varlistentry>
|
---|
| 310 |
|
---|
| 311 | <varlistentry id="dropdb">
|
---|
| 312 | <term><command>dropdb</command></term>
|
---|
| 313 | <listitem>
|
---|
| 314 | <para>removes a <application>PostgreSQL</application> database.</para>
|
---|
| 315 | <indexterm zone="postgresql dropdb">
|
---|
| 316 | <primary sortas="b-dropdb">dropdb</primary>
|
---|
| 317 | </indexterm>
|
---|
| 318 | </listitem>
|
---|
| 319 | </varlistentry>
|
---|
| 320 |
|
---|
| 321 | <varlistentry id="droplang">
|
---|
| 322 | <term><command>droplang</command></term>
|
---|
| 323 | <listitem>
|
---|
| 324 | <para>removes a <application>PostgreSQL</application> procedural
|
---|
| 325 | language.</para>
|
---|
| 326 | <indexterm zone="postgresql droplang">
|
---|
| 327 | <primary sortas="b-droplang">droplang</primary>
|
---|
| 328 | </indexterm>
|
---|
| 329 | </listitem>
|
---|
| 330 | </varlistentry>
|
---|
| 331 |
|
---|
| 332 | <varlistentry id="dropuser">
|
---|
| 333 | <term><command>dropuser</command></term>
|
---|
| 334 | <listitem>
|
---|
| 335 | <para>removes a <application>PostgreSQL</application>
|
---|
| 336 | user account.</para>
|
---|
| 337 | <indexterm zone="postgresql dropuser">
|
---|
| 338 | <primary sortas="b-dropuser">dropuser</primary>
|
---|
| 339 | </indexterm>
|
---|
| 340 | </listitem>
|
---|
| 341 | </varlistentry>
|
---|
| 342 |
|
---|
| 343 | <varlistentry id="ecpg">
|
---|
| 344 | <term><command>ecpg</command></term>
|
---|
| 345 | <listitem>
|
---|
| 346 | <para>is the embedded SQL preprocessor.</para>
|
---|
| 347 | <indexterm zone="postgresql ecpg">
|
---|
| 348 | <primary sortas="b-ecpg">ecpg</primary>
|
---|
| 349 | </indexterm>
|
---|
| 350 | </listitem>
|
---|
| 351 | </varlistentry>
|
---|
| 352 |
|
---|
| 353 | <varlistentry id="initdb">
|
---|
| 354 | <term><command>initdb</command></term>
|
---|
| 355 | <listitem>
|
---|
| 356 | <para>creates a new database cluster.</para>
|
---|
| 357 | <indexterm zone="postgresql initdb">
|
---|
| 358 | <primary sortas="b-initdb">initdb</primary>
|
---|
| 359 | </indexterm>
|
---|
| 360 | </listitem>
|
---|
| 361 | </varlistentry>
|
---|
| 362 |
|
---|
| 363 | <varlistentry id="ipcclean">
|
---|
| 364 | <term><command>ipcclean</command></term>
|
---|
| 365 | <listitem>
|
---|
| 366 | <para>removes shared memory and semaphores left over by an aborted
|
---|
| 367 | database server.</para>
|
---|
| 368 | <indexterm zone="postgresql ipcclean">
|
---|
| 369 | <primary sortas="b-ipcclean">ipcclean</primary>
|
---|
| 370 | </indexterm>
|
---|
| 371 | </listitem>
|
---|
| 372 | </varlistentry>
|
---|
| 373 |
|
---|
| 374 | <varlistentry id="pg_config">
|
---|
| 375 | <term><command>pg_config</command></term>
|
---|
| 376 | <listitem>
|
---|
| 377 | <para>retrieves <application>PostgreSQL</application> version
|
---|
| 378 | information.</para>
|
---|
| 379 | <indexterm zone="postgresql pg_config">
|
---|
| 380 | <primary sortas="b-pg_config">pg_config</primary>
|
---|
| 381 | </indexterm>
|
---|
| 382 | </listitem>
|
---|
| 383 | </varlistentry>
|
---|
| 384 |
|
---|
| 385 | <varlistentry id="pg_controldata">
|
---|
| 386 | <term><command>pg_controldata</command></term>
|
---|
| 387 | <listitem>
|
---|
| 388 | <para>returns information initialized during
|
---|
| 389 | <command>initdb</command>, such as the catalog version and server
|
---|
| 390 | locale.</para>
|
---|
| 391 | <indexterm zone="postgresql pg_controldata">
|
---|
| 392 | <primary sortas="b-pg_controldata">pg_controldata</primary>
|
---|
| 393 | </indexterm>
|
---|
| 394 | </listitem>
|
---|
| 395 | </varlistentry>
|
---|
| 396 |
|
---|
| 397 | <varlistentry id="pg_ctl">
|
---|
| 398 | <term><command>pg_ctl</command></term>
|
---|
| 399 | <listitem>
|
---|
| 400 | <para>controls stopping and starting the database server.</para>
|
---|
| 401 | <indexterm zone="postgresql pg_ctl">
|
---|
| 402 | <primary sortas="b-pg_ctl">pg_ctl</primary>
|
---|
| 403 | </indexterm>
|
---|
| 404 | </listitem>
|
---|
| 405 | </varlistentry>
|
---|
| 406 |
|
---|
| 407 | <varlistentry id="pg_dump">
|
---|
| 408 | <term><command>pg_dump</command></term>
|
---|
| 409 | <listitem>
|
---|
| 410 | <para>dumps database data and metadata into scripts which are used
|
---|
| 411 | to recreate the database.</para>
|
---|
| 412 | <indexterm zone="postgresql pg_dump">
|
---|
| 413 | <primary sortas="b-pg_dump">pg_dump</primary>
|
---|
| 414 | </indexterm>
|
---|
| 415 | </listitem>
|
---|
| 416 | </varlistentry>
|
---|
| 417 |
|
---|
| 418 | <varlistentry id="pg_dumpall">
|
---|
| 419 | <term><command>pg_dumpall</command></term>
|
---|
| 420 | <listitem>
|
---|
| 421 | <para>recursively calls <command>pg_dump</command> for each
|
---|
| 422 | database in a cluster.</para>
|
---|
| 423 | <indexterm zone="postgresql pg_dumpall">
|
---|
| 424 | <primary sortas="b-pg_dumpall">pg_dumpall</primary>
|
---|
| 425 | </indexterm>
|
---|
| 426 | </listitem>
|
---|
| 427 | </varlistentry>
|
---|
| 428 |
|
---|
| 429 | <varlistentry id="pg_resetxlog">
|
---|
| 430 | <term><command>pg_resetxlog</command></term>
|
---|
| 431 | <listitem>
|
---|
| 432 | <para>clears the write-ahead log and optionally resets some
|
---|
| 433 | fields in the <filename>pg_control</filename> file.</para>
|
---|
| 434 | <indexterm zone="postgresql pg_resetxlog">
|
---|
| 435 | <primary sortas="b-pg_resetxlog">pg_resetxlog</primary>
|
---|
| 436 | </indexterm>
|
---|
| 437 | </listitem>
|
---|
| 438 | </varlistentry>
|
---|
| 439 |
|
---|
| 440 | <varlistentry id="pg_restore">
|
---|
| 441 | <term><command>pg_restore</command></term>
|
---|
| 442 | <listitem>
|
---|
| 443 | <para>creates databases from dump files created by
|
---|
| 444 | <command>pg_dump</command>.</para>
|
---|
| 445 | <indexterm zone="postgresql pg_restore">
|
---|
| 446 | <primary sortas="b-pg_restore">pg_restore</primary>
|
---|
| 447 | </indexterm>
|
---|
| 448 | </listitem>
|
---|
| 449 | </varlistentry>
|
---|
| 450 |
|
---|
| 451 | <varlistentry id="pltcl_delmod">
|
---|
| 452 | <term><command>pltcl_delmod</command></term>
|
---|
| 453 | <listitem>
|
---|
| 454 | <para>is a support script used to delete a module from a
|
---|
| 455 | PL/<application>Tcl</application> table. The command
|
---|
| 456 | requires the <ulink
|
---|
| 457 | url="http://gborg.postgresql.org/project/pgtcl/">Pgtcl</ulink>
|
---|
| 458 | package to be installed also.</para>
|
---|
| 459 | <indexterm zone="postgresql pltcl_delmod">
|
---|
| 460 | <primary sortas="b-pltcl_delmod">pltcl_delmod</primary>
|
---|
| 461 | </indexterm>
|
---|
| 462 | </listitem>
|
---|
| 463 | </varlistentry>
|
---|
| 464 |
|
---|
| 465 | <varlistentry id="pltcl_listmod">
|
---|
| 466 | <term><command>pltcl_listmod</command></term>
|
---|
| 467 | <listitem>
|
---|
| 468 | <para>is a support script used to list the modules in a
|
---|
| 469 | PL/<application>Tcl</application> table. The command
|
---|
| 470 | requires the <ulink
|
---|
| 471 | url="http://gborg.postgresql.org/project/pgtcl/">Pgtcl</ulink>
|
---|
| 472 | package to be installed also.</para>
|
---|
| 473 | <indexterm zone="postgresql pltcl_listmod">
|
---|
| 474 | <primary sortas="b-pltcl_listmod">pltcl_listmod</primary>
|
---|
| 475 | </indexterm>
|
---|
| 476 | </listitem>
|
---|
| 477 | </varlistentry>
|
---|
| 478 |
|
---|
| 479 | <varlistentry id="pltcl_loadmod">
|
---|
| 480 | <term><command>pltcl_loadmod</command></term>
|
---|
| 481 | <listitem>
|
---|
| 482 | <para>is a support script used to load a module into a
|
---|
| 483 | PL/<application>Tcl</application> table. The command
|
---|
| 484 | requires the <ulink
|
---|
| 485 | url="http://gborg.postgresql.org/project/pgtcl/">Pgtcl</ulink>
|
---|
| 486 | package to be installed also.</para>
|
---|
| 487 | <indexterm zone="postgresql pltcl_loadmod">
|
---|
| 488 | <primary sortas="b-pltcl_loadmod">pltcl_loadmod</primary>
|
---|
| 489 | </indexterm>
|
---|
| 490 | </listitem>
|
---|
| 491 | </varlistentry>
|
---|
| 492 |
|
---|
| 493 | <varlistentry id="postgres">
|
---|
| 494 | <term><command>postgres</command></term>
|
---|
| 495 | <listitem>
|
---|
| 496 | <para>is a single user database server, generally used for
|
---|
| 497 | debugging.</para>
|
---|
| 498 | <indexterm zone="postgresql postgres">
|
---|
| 499 | <primary sortas="b-postgres">postgres</primary>
|
---|
| 500 | </indexterm>
|
---|
| 501 | </listitem>
|
---|
| 502 | </varlistentry>
|
---|
| 503 |
|
---|
| 504 | <varlistentry id="postmaster">
|
---|
| 505 | <term><command>postmaster</command></term>
|
---|
| 506 | <listitem>
|
---|
| 507 | <para>is a multi-user database daemon.</para>
|
---|
| 508 | <indexterm zone="postgresql postmaster">
|
---|
| 509 | <primary sortas="b-postmaster">postmaster</primary>
|
---|
| 510 | </indexterm>
|
---|
| 511 | </listitem>
|
---|
| 512 | </varlistentry>
|
---|
| 513 |
|
---|
| 514 | <varlistentry id="psql">
|
---|
| 515 | <term><command>psql</command></term>
|
---|
| 516 | <listitem>
|
---|
| 517 | <para>is a console based database shell.</para>
|
---|
| 518 | <indexterm zone="postgresql psql">
|
---|
| 519 | <primary sortas="b-psql">psql</primary>
|
---|
| 520 | </indexterm>
|
---|
| 521 | </listitem>
|
---|
| 522 | </varlistentry>
|
---|
| 523 |
|
---|
[aaeca54] | 524 | <varlistentry id="reindexdb">
|
---|
| 525 | <term><command>reindexdb</command></term>
|
---|
| 526 | <listitem>
|
---|
| 527 | <para>is a utility for rebuilding indexes in a database.</para>
|
---|
[621a551] | 528 | <indexterm zone="postgresql reindexdb">
|
---|
| 529 | <primary sortas="b-reindexdb">reindexdb</primary>
|
---|
[aaeca54] | 530 | </indexterm>
|
---|
| 531 | </listitem>
|
---|
| 532 | </varlistentry>
|
---|
| 533 |
|
---|
[4ab91cd] | 534 | <varlistentry id="vacuumdb">
|
---|
| 535 | <term><command>vacuumdb</command></term>
|
---|
| 536 | <listitem>
|
---|
| 537 | <para>compacts databases and generates statistics for the query
|
---|
| 538 | analyzer.</para>
|
---|
| 539 | <indexterm zone="postgresql vacuumdb">
|
---|
| 540 | <primary sortas="b-vacuumdb">vacuumdb</primary>
|
---|
| 541 | </indexterm>
|
---|
| 542 | </listitem>
|
---|
| 543 | </varlistentry>
|
---|
| 544 |
|
---|
| 545 | </variablelist>
|
---|
| 546 |
|
---|
| 547 | </sect2>
|
---|
[458342f] | 548 |
|
---|
| 549 | </sect1>
|
---|