Difference between revisions of "Fedora Arm Secondary Architecture/Koji Database"

From CDOT Wiki
Jump to: navigation, search
Line 1: Line 1:
[[Category:Fedora ARM Secondary Architecture]]
+
[[Category:Fedora ARM Secondary Architecture]][[Category:SBR600]]
 
 
  
 
The link below was very helpful in the setup of the PostgreSQL database.
 
The link below was very helpful in the setup of the PostgreSQL database.
Line 7: Line 6:
  
 
My team members and I were able for create the database as required. Below is the commands executed to create that database.
 
My team members and I were able for create the database as required. Below is the commands executed to create that database.
 
+
yum install postgresql-server
root@hongkong# yum install postgresql-server
 
  
 
Once installed you will then need to initialize the Database with the following command:
 
Once installed you will then need to initialize the Database with the following command:
 
+
service postgresql initdb
 
 
root@hongkong# service postgresql initdb
 
  
 
Then start the Postgresql service with:
 
Then start the Postgresql service with:
 
+
service postgresql start
 
 
root@hongkong# service postgresql start
 
  
 
At this point the Postgresql server is installed and operational provided no errors were reported with the database initialized. The next steps is to create a user named “koji”, set up Postgresql and populate the schema:
 
At this point the Postgresql server is installed and operational provided no errors were reported with the database initialized. The next steps is to create a user named “koji”, set up Postgresql and populate the schema:
 +
useradd koji
 +
passwd -d koji
 +
su - postgres
 +
createuser koji
 +
    Shall the new role be a superuser? (y/n) n
 +
    Shall the new role be allowed to create databases? (y/n) n
 +
    Shall the new role be allowed to create more new roles?(y/n) n
  
root@hongkong# useradd koji
+
createdb -O koji koji
 
+
logout
root@hongkong# passwd -d koji
+
 
+
su - koji
root@hongkong# su - postgres
+
psql koji koji < /usr/share/doc/koji*/docs/schema.sql
 
+
exit
postgres@hongkong# createuser koji
 
 
 
Shall the new role be a superuser? (y/n) n
 
 
 
Shall the new role be allowed to create databases? (y/n) n
 
 
 
Shall the new role be allowed to create more new roles?(y/n) n
 
 
 
postgres@hongkong# createdb -O koji koji
 
 
 
postgres@hongkong# logout
 
 
 
root@hongkong# su - koji
 
 
 
koji@hongkong$ psql koji koji < /usr/share/doc/koji*/docs/schema.sql
 
 
 
koji@hongkong$ exit
 

Revision as of 14:22, 17 April 2010


The link below was very helpful in the setup of the PostgreSQL database.

http://fedoraproject.org/wiki/Koji/ServerHowTo

My team members and I were able for create the database as required. Below is the commands executed to create that database.

yum install postgresql-server

Once installed you will then need to initialize the Database with the following command:

service postgresql initdb

Then start the Postgresql service with:

service postgresql start

At this point the Postgresql server is installed and operational provided no errors were reported with the database initialized. The next steps is to create a user named “koji”, set up Postgresql and populate the schema:

useradd koji
passwd -d koji
su - postgres
createuser koji
   Shall the new role be a superuser? (y/n) n
   Shall the new role be allowed to create databases? (y/n) n
   Shall the new role be allowed to create more new roles?(y/n) n
createdb -O koji koji
logout

su - koji
psql koji koji < /usr/share/doc/koji*/docs/schema.sql
exit