Database Journal
MS SQL Oracle DB2 Access MySQL PostgreSQL Sybase PHP SQL Etc SQL Scripts & Samples Links Database Forum

» Database Journal Home
» Database Articles
» Database Tutorials
MS SQL
Oracle
DB2
MS Access
MySQL
» RESOURCES
Database Tools
SQL Scripts & Samples
Links
» Database Forum
» Sitemap
Free Newsletters:
DatabaseDaily  
News Via RSS Feed


follow us on Twitter
Database Journal |DBA Support |SQLCourse |SQLCourse2
 

Featured Database Articles

PostgreSQL

Posted Aug 21, 2003

PostgreSQL Software Installation - Page 2

By James Koopmann

Initialization of the Cygwin Setup GUI


Click for larger image

You may choose from where you want to install the Cygwin packages. You can install from the internet, which will run the install procedures across the net. You may choose also to download the packages and then install them from a local directory. Depending on your internet connection speed, you may wish to choose the second option of downloading the packages first and then installing them from a local directory. Since my connection is relatively fast, I will be installing from the internet.

The choice of where to have the root directory is up to you. I have always used C:\cygwin and have never any trouble with this selection. Once you get comfortable with Cygwin you will end up mounting directory paths anyway and it really doesn't matter where you put this. Since you are installing on a Windows environment and may have multiple users, Cygwin gives you the option to install for all users to use. I have not yet tried this option but have run in environments that do without failure.

The Cygwin setup procedure also allows you to check back periodically for updates to the packages. This option lets you choose where you want the packages to be stored for installation. You might want to choose somewhere else to maintain multiple copies but I personally have always just used the default and written over the source.

Choose the type of internet connection you wish to maintain for the download and installation of Cygwin. I use the direct connection.

Cygwin can be downloaded from many different download sites. Pick one that appeals to you.

Now comes the trickiest part of the whole process. This screen allows you to choose which packages you want to download and install. I have only shown the database section. As you can see, I have currently installed the PostgreSQL version 7.3.3-1 and there is a new version 7.3.4-1. I have selected to just download and install the binary executables. The main purpose here is to just scroll through the different options and install what you like. The Cygwin base distribution will be installed by default and you need to choose anything else you want. I would make sure you get Perl and PostgreSQL at a minimal. If you feel daring, download and install Xfree86. This is the best free X Server and Client I have come across. After clicking on the next button, the download and installation will begin until complete.

Windows Command Line Installation Steps

After having installed through the Cygwin GUI you have the option of rebuilding PostgreSQL through the Cygwin command shell. The only problem I had when attempting this was that it could not find cygpcre.dll. Cygwin has a nice facility on their website for searching the package list for whatever it is you are looking for. I just went to http://cygwin.com/packages/ for the package search, entered the cygpcre.dll, hit search and found the library I needed. I then started up the setup installation procedures, went to the libraries, clicked to reinstall libcpre as was told from the search where this dll was, ran the install, and was back in business. 

Following are the steps for re-installing with the perl option.

Step

Command

Description

1

cd /usr/src/postgresql-7.3.4-2

Change to the root node of the PostgreSQL source tree where Cygwin put the source

2

./configure --with-perl

Run the configure command to set up the source tree for the options you want to install. Here I am configuring with the perl option. See documentation for other options. If you want to run multiple configure commands make sure you use the 'gmake clean' command before issuing the configure command.

3

make check

Runs regression checks on your configuration to verify the configuration.

4

make

Runs the build procedures and compiles for what you have configured

5

make install

Install your configuration

6
psql --version

Test to make sure you can find the binaries. Should get something like: psql (PostgreSQL) 7.3.4

No matter what operating system you are on, the installation of the PostgreSQL source is surely a snap. Within a few steps for a UNIX environment and a few clicks in a wiz-bang GUI for windows will have you up and running in no time.

» See All Articles by Columnist James Koopmann



PostgreSQL Archives

Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 




Latest Forum Threads
Postgresql Forum
Topic By Replies Updated
Creating a Table Where Date has to be Now OR Future Shadowayara 1 June 6th, 03:56 PM
Streaming Replication on a Single Database lbergeson 0 January 30th, 03:19 PM
Error - SQL state: 22P02 raj_db 1 December 20th, 08:30 AM
Searching in multi-dimensional array fields hdany 0 December 1st, 06:46 AM