Difference between revisions of "Zheng's installation notes"

From GMOD
Jump to: navigation, search
(install [http://www.postgresql.org/ postgresql])
(install [http://www.postgresql.org/ postgresql])
Line 15: Line 15:
 
==install prerequisites==
 
==install prerequisites==
 
===install [http://www.postgresql.org/ postgresql]===
 
===install [http://www.postgresql.org/ postgresql]===
**install both client and server by yum
+
*install both client and server by yum
 
  [zha@localhost ~] sudo yum install postgresql
 
  [zha@localhost ~] sudo yum install postgresql
 
  [zha@localhost ~] sudo yum install postgresql-server
 
  [zha@localhost ~] sudo yum install postgresql-server
 
right now the version is 8.1.8 (in yum package pool)
 
right now the version is 8.1.8 (in yum package pool)
**make server run
+
*make server run
 
  [zha@localhost ~] sudo /sbin/service postgres start
 
  [zha@localhost ~] sudo /sbin/service postgres start
 
to make it run at boot
 
to make it run at boot
 
  [zha@localhost ~] sudo /sbin/chkconfig postgres on
 
  [zha@localhost ~] sudo /sbin/chkconfig postgres on
**in .bash_profile add line
+
*in .bash_profile add line
 
  export PGDATA="/var/lib/pgsql/data/"
 
  export PGDATA="/var/lib/pgsql/data/"
 
But I still can't get rid of the -D /var/lib/pgsql/data/ '''why???'''
 
But I still can't get rid of the -D /var/lib/pgsql/data/ '''why???'''
Line 32: Line 32:
 
  FATAL:  lock file "postmaster.pid" already exists
 
  FATAL:  lock file "postmaster.pid" already exists
 
  HINT:  Is another postmaster (PID 2785) running in data directory "/var/lib/pgsql/data"?
 
  HINT:  Is another postmaster (PID 2785) running in data directory "/var/lib/pgsql/data"?
**create PL language, template, several roles
+
*create PL language, template, several roles
 
  [zha@localhost ~] sudo -u postgres creatlang plpgsql template1
 
  [zha@localhost ~] sudo -u postgres creatlang plpgsql template1
 
  [zha@localhost ~] sudo -u postgres createuser zha
 
  [zha@localhost ~] sudo -u postgres createuser zha
Line 38: Line 38:
 
  [zha@localhost ~] sudo -u postgres createuser root
 
  [zha@localhost ~] sudo -u postgres createuser root
 
this must be a superuser of postgresql (same privilege as postgres)  
 
this must be a superuser of postgresql (same privilege as postgres)  
**edit the pg_hba.conf
+
*edit the pg_hba.conf
 
the pg_hba.conf is in /var/lib/pgsql/data/pg_hba.conf, you probably need to chown to postgres.
 
the pg_hba.conf is in /var/lib/pgsql/data/pg_hba.conf, you probably need to chown to postgres.
 
  # TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD
 
  # TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD

Revision as of 16:20, 20 March 2007

Back to Chado New Users

general information

There suppose to be an easy way and a hard way to install Chado database on Fedora:

  • the easy way: use an existing rpm package. I have not tried it. but you can find information at installation using an RPM
  • the hard way: install by source. But yum makes it easier. The following is my note on installation of Chado on Fedora 6.

before you start

get chado schema from cvs

see Chado From CVS, issue cvs command at my home directory.

install prerequisites

install postgresql

  • install both client and server by yum
[zha@localhost ~] sudo yum install postgresql
[zha@localhost ~] sudo yum install postgresql-server

right now the version is 8.1.8 (in yum package pool)

  • make server run
[zha@localhost ~] sudo /sbin/service postgres start

to make it run at boot

[zha@localhost ~] sudo /sbin/chkconfig postgres on
  • in .bash_profile add line
export PGDATA="/var/lib/pgsql/data/"

But I still can't get rid of the -D /var/lib/pgsql/data/ why???

[zha@localhost gff3]$ sudo -u postgres postgres
postgres does not know where to find the server configuration file.
You must specify the --config-file or -D invocation option or set the PGDATA environment variable.
[zha@localhost gff3]$ sudo -u postgres postgres -D /var/lib/pgsql/data
FATAL:  lock file "postmaster.pid" already exists
HINT:  Is another postmaster (PID 2785) running in data directory "/var/lib/pgsql/data"?
  • create PL language, template, several roles
[zha@localhost ~] sudo -u postgres creatlang plpgsql template1
[zha@localhost ~] sudo -u postgres createuser zha

replace zha with your own account name at your home directory. this must be a user with privilege to create and drop database.

[zha@localhost ~] sudo -u postgres createuser root

this must be a superuser of postgresql (same privilege as postgres)

  • edit the pg_hba.conf

the pg_hba.conf is in /var/lib/pgsql/data/pg_hba.conf, you probably need to chown to postgres.

# TYPE  DATABASE    USER        CIDR-ADDRESS          METHOD
local   all         all                               trust
host    all         all         127.0.0.1/32          trust
host    all         all         ::1/128               trust

need revisit for local access and access method (MD5)

  • tune the server

install several general perl modules

use sudo cpan to do it. install CGI Graph

install bioperl live

[zha@localhost ~]$ sudo cpan
Password:
cpan[1]> install S/SE/SENDU/bioperl-1.5.2_102

this is the live bioperl right now

install go-dev

download and unpack the go-dev package since need to set the GO_ROOT environment variable. Although right now only a perl parser module for GO is needed.

  • in .bash_profile add line
export GO_ROOT="$HOME/go-dev"
  • install GO::Parser
[zha@localhost ~]$ sudo cpan
Password:
cpan[1]> install GO::Parser