From: David Friend <dfriend@atlsci.atlsci.com>

Here are the latest changes to the INSTALL instructions.

The main changes are:
  - Step 5, on flex
  - Steps 18 and 19, on regression tests
  - Step 22 c) on starting postmaster on bootup on FreeBSD
  - Added porting notes for SPARC/Linux at end.

If there is time, Thomas should review step 19.
This commit is contained in:
Marc G. Fournier 1997-05-17 03:00:24 +00:00
parent 51e0fe5c88
commit ab5910a766

96
INSTALL
View File

@ -90,6 +90,12 @@ To upgrade to PostgreSQL v6.1 do the following:
is 2.5.3 or before 2.5.2 then you will have to upgrade flex. You may is 2.5.3 or before 2.5.2 then you will have to upgrade flex. You may
get it at ftp://prep.ai.mit.edu/pub/gnu/flex-2.5.4.tar.gz. get it at ftp://prep.ai.mit.edu/pub/gnu/flex-2.5.4.tar.gz.
If you need flex and don't have it or have the wrong version, then
you will be told so when you attempt to compile the program. Feel
free to skip this step if you aren't sure you need it. If you do
need it then you will be told to install/upgrade flex when you try to
compile.
To install it, type the following: To install it, type the following:
cd cd
gunzip -c flex-2.5.4.tar.gz | tar xvf - gunzip -c flex-2.5.4.tar.gz | tar xvf -
@ -106,10 +112,6 @@ To upgrade to PostgreSQL v6.1 do the following:
/usr/lib/libfl.a, /usr/include/FlexLexer.h and will add link /usr/lib/libfl.a, /usr/include/FlexLexer.h and will add link
/usr/bin/flex++ which points to flex. /usr/bin/flex++ which points to flex.
If you have flex v2.5.3 and do not have handy access to the
internet, you can apply the patch in /usr/src/pgsql/doc/README.flex
instead.
6) If you are upgrading an existing system from any version before 6) If you are upgrading an existing system from any version before
version 6.1 beta release 970512 then back up the current version 6.1 beta release 970512 then back up the current
database. Type database. Type
@ -162,12 +164,10 @@ To upgrade to PostgreSQL v6.1 do the following:
su su
cd /usr/src cd /usr/src
mkdir pgsql mkdir pgsql
chown postgres pgsql chown postgres:postgres pgsql
chgrp postgres pgsql
cd /usr/local cd /usr/local
mkdir pgsql mkdir pgsql
chown postgres pgsql chown postgres:postgres pgsql
chgrp postgres pgsql
exit exit
10) Unzip and untar the new source file. Type 10) Unzip and untar the new source file. Type
@ -316,7 +316,10 @@ To upgrade to PostgreSQL v6.1 do the following:
your old database on top of the one in your new database, rather than your old database on top of the one in your new database, rather than
redoing this from scratch. redoing this from scratch.
18) Start the postmaster in preparation for the regression tests. First, 18) If you wish to skip the regression tests then skip to step 21.
However, we think skipping the tests is a BAD idea!
Start the postmaster in preparation for the regression tests. First,
set the timezone for Berkley, California. On some systems you may do set the timezone for Berkley, California. On some systems you may do
this by setting environment variable TZ. I.e., using bash, type this by setting environment variable TZ. I.e., using bash, type
export TZ=PST8PDT7,M04.01.0,M10.0503 export TZ=PST8PDT7,M04.01.0,M10.0503
@ -338,11 +341,30 @@ To upgrade to PostgreSQL v6.1 do the following:
You should get on the screen (and also written to file ./regress.out) You should get on the screen (and also written to file ./regress.out)
a series of statements stating which tests passed and which tests a series of statements stating which tests passed and which tests
failed. Please note that it is normal for some of the tests to failed. Please note that it is normal for some of the tests to
"fail". For the failed tests, use diff to compare the files in "fail".
directories ./results and ./expected. "Failed" tests may have
failed due to slightly different error messages, output formatting, For the tests that failed, i.e. if float8 failed, type something like:
failure to set the timezone correctly for your platform, etc. cd /usr/src/pgsql/src/test/regress
"Failures" of this type do not indicate a problem with PostgreSQL. diff -w expected/float8.out results
Now do some intelligent interpretation of what you see before
deciding if you have detected a bug in PostgreSQL as it compiled on
you platform.
For example. On a SPARC/Linux-elf platform using the 970516 beta
version of PostgreSQL v6.1 the following tests "failed". float8
and geometry "failed" due to minor precision differences in floating
point numbers. timespan and horology had different values from the
expected "14 secs ago". (This may be a real bug. It may simply be
problems with convincing the back end what timezone and time to
use.) datetime, abstime and tinterval failed because it used GMT
where it should have used PST and PDT. (Same comment.) select_views
failed for unknown reasons. Conclusion? There may be some real
bugs exhibited here but will they effect what you intend to use
PostgreSQL for? (Note: Most of these bugs also occur on the
i86/Linux platform. Also note that there will be significant
changes made to the date and time types immediately after the
v6.1 release so if you do need these functions, monitor the HACKERS
and PORTS mailing lists to see what is going on.)
After running the tests, type After running the tests, type
cd /usr/src/pgsql/src/test/regress cd /usr/src/pgsql/src/test/regress
@ -387,13 +409,21 @@ To upgrade to PostgreSQL v6.1 do the following:
postmaster if it dies, but he doesn't know if there are other side postmaster if it dies, but he doesn't know if there are other side
effects.) effects.)
c) In FreeBSD edit /usr/local/etc/rc.d/pgsql.sh to contain the c) In FreeBSD 2.2-RELEASE edit /usr/local/etc/rc.d/pgsql.sh to
following two lines, and make it 755 root:bin : contain the following lines and make it chmod 755 and chown
root:bin.
#!/bin/sh #!/bin/sh
[ -x /usr/local/pgsql/bin/postmaster ] && [ -x /usr/local/pgsql/bin/postmaster ] && {
su -l pgsql -c '/usr/local/pgsql/bin/postmaster su -l pgsql -c 'exec /usr/local/pgsql/bin/postmaster
-D/usr/local/pgsql/data -o -F > /usr/local/pgsql/errlog -D/usr/local/pgsql/data
&' && echo -n ' pgsql' -S -o -F > /usr/local/pgsql/errlog' &
echo -n ' pgsql'
}
You may put the line breaks as shown above. The shell is smart
enough to keep parsing beyond end-of-line if there is an
expression unfinished. The exec saves one layer of shell under
the postmaster process so the parent is init. Note: Unlike the
other examples, this one has been tested.
d) In RedHat v4.0 Linux create file /etc/rc.d/init.d/postgres.init to d) In RedHat v4.0 Linux create file /etc/rc.d/init.d/postgres.init to
contain the following single line: contain the following single line:
@ -551,3 +581,29 @@ NeXT:
binary releases of PostgreSQL for NEXTSTEP will be made available to binary releases of PostgreSQL for NEXTSTEP will be made available to
the general public. Contact Info@RnA.nl for information. the general public. Contact Info@RnA.nl for information.
SPARC Linux-elf:
There was not time to finish adding support for this in the v6.1
release. However, if you are running RedHat Linux v4.0 on a
SPARC platform then install flex v2.5.4 and tell configure you
have a Linux-elf platform. Between configuring and compiling
PostgreSQL, edit the following files:
1) Edit src/GNUmakefile to comment out the call to lexflex and
the if-then-else test that follows it. (This may not be
necessary by the time v6.1 gets released.)
2) Edit src/Makefile.global to change "-O2" to "-O".
3) Edit src/backend/libpq/pqcomprim.c, near the start to replace
#ifdef HAVE_ENDIAN_H
# include <endian.h>
#endif
with
/*
#ifdef HAVE_ENDIAN_H
# include <endian.h>
#endif
*/
#define BYTE_ORDER LITTLE_ENDIAN
If you want to know the reasonilng behind the above instructions
then look in ftp://ftp.postgresql.org/pub/majordomo/ports for a
May 16, 1997 mail message called "regression tests on a
SPARC/Linux platform".