×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Installation

Installation

Installation

(OP)
BIG!!! problems getting started with PostgreSQL. Sorry I'm not an MIT Super-Intellectual but a below average intelligence ICT-ler in Uganda with a bad intrenet-connection.

I'm trying to get PostgreSQL up and running using Debian. I have downloaded nearly all the documentation available.

I have installed PostgreSQL using apt-get install postgres (this worked !!!)
I know where the files are (thanks to Gerhard Mourani (http://www.opencontent.org/openpub/):-
 Simply run the following command before installing the software:
[root@deep /root]# find /* > PostgreSQL1
 And the following one after you install the software:
[root@deep /root]# find /* > PostgreSQL2
 Then use the following command to get a list of what changed:
[root@deep /root]# diff PostgreSQL1 PostgreSQL2 > PostgreSQL-Installed

PostgreSQL starts on reboot (starting postgresql 8.3.0 database server main)... what does this mean ??? The database server is starting in an uninitialised state and this is not the postmaster deamon - or is it ???
ps shows that ps is running
I have created a user for Postgres (adduser pgadmin - this worked!!!)

I realise that the default user for the postmaster deamon is postgres but that this user name can be freely choosen - if you know how !!!

Now everything gets difficult. The Postgres manuel tells me (page 274) the following...

16.1. The PostgreSQL User Account
       As with any other server daemon that is accessible to the outside world, it is advisable to run PostgreSQL under a separate user account. This user account should only own the data that is managed by the server, and should not be shared with other daemons. (For example, using the user nobody is a bad idea.) It is not advisable to install executables owned by this user because compromised systems could then modify their own binaries. To add a Unix user account to your system, look for a command useradd or adduser. The user name postgres is often used, and is assumed throughout this book, but you can use another name if you like.

But I cannot find a config-file or command that tells postgres who the su (pgadmin) is for the database and besides postmaster starts at boot, presumably without a su-user - can't find documentation.

And getting ahead of myself - there is talk of initialising the database with a folder for data

The Postgres manuel tells me the following...

In file system terms, a database cluster will be a single directory under which all data will be stored. We call this the data directory or data area. It is completely up to you where you choose to store your data. There is no default, although locations such as /usr/local/pgsql/data or /var/lib/pgsql/data are popular. To initialize a database cluster, use the command initdb, which is installed with PostgreSQL. The desired file system location of your database cluster is indicated by the -D option, for example
     $ initdb -D /usr/local/pgsql/data
Note that you must execute this command while logged into the PostgreSQL user account, which is described in the previous section (which as I have already said I have not been able to do).

But I would expect something like ...
/data
/data/project1
/data/project2
/data/project3
.
.
.

But there is no mention of this and how to do it (of course I know how to create directories but dont know how to supply this infomation to postgreSQL for separate projects) - am totally confused !!!

Appreciate help aimed at a low grade moron or DAA (German = Dummster Anzunehmender Anwender) - thanks
 Dragonfish

----------------------------------------------------------
Meddle not in the affarirs of Dragons
for you are chrunchy and good with Mustard
----------------------------------------------------------

RE: Installation

Hi

Quote (Dragonfish):

But I cannot find a config-file or command that tells postgres who the su (pgadmin) is for the database and besides postmaster starts at boot, presumably without a su-user - can't find documentation.
You have to edit the /etc/init.d/postgresql init script to have the daemon run as user pgadmin. At a moment you will probably have to edit the pg_hba.conf and/or pg_ident.conf files too, but not sure when. ( Both can found in the data directory, either as symlink or as copy of their originals from /etc/postgresql/ . ) I am not aware of more places to change, however, I never tried such wizardry.

Quote (Dragonfish):

But I would expect something like ...
/data
/data/project1
/data/project2
/data/project3
No way. What and how is inside the data directory is none of your business. PostgreSQL organizes the files according to his needs, not your or your project's.

Quote (Dragonfish):

But there is no mention of this and how to do it (of course I know how to create directories but dont know how to supply this infomation to postgreSQL for separate projects)
Both pg_ctl and initdb expect a single data directory specified with -D , so you can not specify more.

Feherke.
http://free.rootshell.be/~feherke/

RE: Installation

(OP)
Thanks Feherke.

am working on it.

Dragonfish

----------------------------------------------------------
Meddle not in the affarirs of Dragons
for you are chrunchy and good with Mustard
----------------------------------------------------------

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close