DBANotes 1. Minimal AminimalPostgres system must have the following subdirectories in one directory: bin data files These directories contain the following files: bin: backend createdb destroydb ipcclean initdb monitor pg_id pg_version postgres postmaster vacuumd vcontrol data: files: global1.bki local1_template1.bki 2. Relocating Thefollowing files in the "bin" subdirectory can be relocated to another directory without problems: createdb destroydb ipcclean monitor vcontrol The other two directories and their contents must remain in the same directory as the "bin" directory, or at least have symbolic links to them with the same names. 3. Requirements o It must be owned by one user. By convention, although not by necessity, the "postgres" user usually owns the home directory and the Postgres executables. The installer must be a registered Postgres user. To become a registered Postgres user (before initdb is run) you should do the following: 1. Edit the file ./files/global1.bki 2. Find the section that initializes the "pg_user" class. 3. Using one of the entries already there, add yourself to that section, making sure your username and userid are correct and unique. NOTE:Thisprocedure only works and is only necessary BEFORE the first database is created. Once any database has been created, the procedure discussed in "Adding and Deleting Users" should be used to register new Postgres users. o The installation procedure will make the files setuid (see chmod (1) for details) to the person doing the installation. For numerous reasons, not the least of which will be that Postgres will not work, the installation should NOT be done as superuser (userid 0). NOTE:Ifthesefilesare not setuid, nobody other than the installer can use Postgres. 4. Heterogenous o Postgres databases are machine-dependent, and rely on "native" byte-ordering and such for performance reasons. Therefore, one machine must be designated as the Postgres server and the "postmaster" program should be run there. (see the manual for details on running the postmaster) o DoNOTtrytomountthefilesystemcontainingthe"data" directory on the network and use it from another machine while the server is able to access it - this defeats the Postgres locking scheme and will lead to corrupt databases. o If users on different architectures are using the same databases, they may compile the "monitor" program (or any other LIBPQ application) locally and use it to access their databases on the server. This applies to any application program written using the "libpq" library. (see the manual for details on running the monitor and using libpq)