User Tools

Site Tools


software:db2:setup

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
software:db2:setup [2013/02/28 09:39] seelasoftware:db2:setup [Unknown date] (current) – removed - external edit (Unknown date) 127.0.0.1
Line 1: Line 1:
-====== Setup of Database Server ======  
- 
-====Teaching - Understanding DB2==== 
- 
-**September 2012** 
- 
-<code> 
- 
- 
- 
-The database server is not accessible by students or faculty directly 
-Any connection to the database will occur from the client's instance 
- 
-As of September 2012, we are running DB2 -Express-C Version 10.1 
- 
-This is a freely available version for universities. 
- 
-You need to register with IBM's Academic Initiative Alliance for valid downloads 
- 
- 
-The client's connection can be accessed from any host users can login into  
-with a valid unix login. 
- 
-   
-Entering db2 from any linux desktop in the department will 
-allow you to access db2 eg: 
- 
-   gemini 316 % db2 connect to c3421a 
-  
-  
- 
-   Database Connection Information 
- 
- Database server        = DB2/LINUXX8664 10.1.0 
- SQL authorization ID   = SEELA 
- Local database alias   = C3421A 
- 
- 
- 
-For Teaching purposes , databases are created by the administrator  
-once a semester and always takes the course number and session. At 
-the end of each semester, it is dropped . 
- 
- 
-</code> 
- 
- 
-**Faculty members who are teaching the course must remember to request the  
-creation of the database for that particular semester. 
-** 
- 
- 
-====Teaching with a Database==== 
- 
-In order to create a database for the current semester 
- 
-First drop the previous term. It's always good to consult with the teaching  
-faculty that they have already submitted their marks  
-If not DO NOT DROP  
- 
-Then proceed to dropping the database if you have permission 
- 
-   * On the client host (red as an example and using the client id db2leduc) 
-     Become user db2leduc 
-     db2 "uncatalog database c3421a" 
-      
-     If successful and you issue the following command , the database should not 
-     exist on the list 
-     db2 list database directory 
- 
-   * On the DB Server (gold) 
-     as the instance owner 
-     db2 drop database c3421a 
-    
-   * Now create the database for the winter semester 
-     db2 create database c3421m 
-         The CREATE DATABASE command completed successfully. 
- 
-   * Back on the client host 
-     db2cli 
-     db2 catalog database c3421m as c3421m at node gold 
-         The CATALOG DATABASE command completed successfully. 
- 
-    make the database available to all users 
-      On the DB server, connect with the instance ID and do the following 
-             $db2 connect to database name 
-       $db2 "revoke connect , createtab, bindadd on database from public" 
-       $db2 "grant connect , createtab, bindadd on database to group faculty" 
-       $db2 "grant connect , createtab, bindadd on database to group ugrad" 
-       $db2 "grant connect,createtab,bindadd on database to group grad" 
- 
-   * Test the connection from any client host in the lab (all linux machines in the department) 
- 
-      From any host in prism 
-       jun04 > db2 
-               db2=> connect to c3421a 
-                     list tables 
-                .... 
- 
- 
- 
- 
- 
- 
-   
-  
- 
- 
  
software/db2/setup.1362062342.txt.gz · Last modified: 2013/02/28 09:39 by seela

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki