.\" XXX standard disclaimer belongs here....
.\" $Header: /private/postgres/ref/unix/RCS/postgres,v 1.12 1992/07/14 05:54:17 ptong Exp $
.SP POSTGRES UNIX 6/14/90
.XA 1 "The \*(PP Backend"
.uh NAME
.lp
postgres \*- run the Postgres backend directly
.uh SYNOPSIS
.lp
.(l
\fBpostgres\fR [\fB-Q\fR] [databasename] [\fB-d\fR debug_level]
.)l
.uh DESCRIPTION
.lp
This command executes the \*(PP backend directly.  
This should be done only while debugging by the DBA, and should not be
done while other \*(PP backends are being managed by a postmaster
on this set of databases.
.sp
.uh "COMMAND OPTIONS"
.lp
\fI-Q\fR indicates "Quiet" mode.  By default, the \*(PP backend
prints the parse tree generated by the parser, the plan generated by
the planner and many debugging message.  Specifying this flag eliminates
much of this.
.sp
\fIdatabasename\fR is the name of the database to be used.  If this
is not specified, databasename defaults to the value of the environment
variable USER.
.sp
.uh "UNDOCUMENTED COMMAND OPTIONS"
.lp
There are several other options that may be specified, used mainly
for debugging purposes.  These are listed here only for the use of
\*(PP system developers.
.lp
\fI-O\fR indicates that the backend should not use the transaction
system.  All commands run in the same transaction and all commands can
see the results of prior commands.
.sp
.lp
\fI-M nnn\fR indicates that the backend should fork \fInnn\fR slave
backend processes and then execute queries in parallel.  This is only
useful on shared-memory multiprocessor systems (e.g. Sequent) and is still in
experimental and research stage.  It is especially unreliable for
large joins.  Full support for intra-query as well inter-query parallelism
have been planned for Version 4.
.sp
.lp
\fI-S\fR indicates that the transaction system can run with the assumption
of stable main memory thus avoiding the necessary flushing of data and log
pages to disk at the end of each transaction system.  This is only used
for performance comparisons for stable vs. non-stable storage.  Do not
use this in other cases, as recovery after a system crash may be impossible
when -S is specified in the absence of stable main memory.
.sp
.lp
\fI-s\fR indicates that time information and other statistics are to be
displayed at the end of each query.  This is useful for benchmarking or
for use in tuning the number of buffers.
.sp
.lp
\fI-B nnn\fR indicates the number of shared buffers to use.  The default
number of buffers is 64.
.sp
.lp
\fI-s\fR \*(PP will report execution statistics such as elapse time,
buffer hit rate, etc for each query execution.
.sp
.lp
\fI-L\fR this flag will turn off locking.
.lp
.sp
.uh "DIAGNOSTICS"
.lp
\fBsemget: No space left on device\fR
.lp
If you see this message, you should run the \fIipcclean\fR command.
After doing this, try running \*(PP again.  If this still doesn't
work, you will need to configure your kernel for shared memory and
semaphores as described in the installation notes.
.sp
.uh "SEE ALSO"
.lp
monitor(unix), postmaster(unix), ipcclean(unix).
