www.blackboard.com global.blackboard.com
Blackboard, the Blackboard logo, Blackboard e-Education Suite, Blackboard Learning System, Blackboard Learning
System ML, Blackboard Portal System, Blackboard Transaction System, Building Blocks, and Bringing Education Online
are either registered trademarks or trademarks of Blackboard Inc. in the United States and/or other countries. Intel and
Pentium are registered trademarks of Intel Corporation. Microsoft and Windows are registered trademarks of Microsoft
Corporation in the United States and/or other countries. Sun, Solaris, UltraSPARC, and Java are either registered
trademarks or trademarks of Sun Microsystems, Inc. in the United States and/or other countries. Oracle is a registered
trademark of Oracle Corporation in the United States and/or other countries. Red Hat is a registered trademark of Red
Hat, Inc. in the United States and/or other countries. Linux is a registered trademark of Linus Torvalds in the United States
and/or other countries. Apache is a trademark of The Apache Software Foundation in the United States and/or other
countries. Macromedia, Authorware and Shockwave are either registered trademarks or trademarks of Macromedia, Inc.
in the United States and/or other countries. Real Player and Real Audio Movie are trademarks of RealNetworks in the
United States and/or other countries. Adobe and Acrobat Reader are either registered trademarks or trademarks of Adobe
Systems Incorporated in the United States and/or other countries. Macintosh and QuickTime are registered trademarks of
Apple Computer, Inc. in the United States and/or other countries. WordPerfect is a registered trademark of Corel
Corporation in the United States and/or other countries. Crystal Reports is a trademark of Crystal Decisions in the United
States and/or other countries. WebEQ is a trademark of Design Science, Inc. in the United States and/or other countries.
JSpell is a trademark of The Solution Café in the United States and/or other countries. Other product and company names
mentioned herein may be the trademarks of their respective owners. Patents pending.
© 2005 Blackboard Inc. All rights reserved. Made and printed in the USA.
No part of the contents of this manual may be reproduced or transmitted in any form or by any means without the written
permission of the publisher, Blackboard Inc.
Blackboard Learning System—Basic Edition Upgrading Oracle 8i to Oracle 9i
TABLE OF CONTENTS
Table of Contents 3
Getting Started 4
GETTING STARTED
Overview
Oracle is ending support for its Oracle 8i (version 8.1.7) RDBMS product. Error correction support will end
on December 31, 2004 and extended support will end on December 31, 2007. This information is provided
in Oracle support note 148054.1. Oracle will end error correction support on July 1, 2005 and extended
support on July 1, 2008 for Oracle version 9.0.2. This information is provided in Oracle support note
283326.1. To ensure that Blackboard is running on a database that is both supported and patched when
errors are discovered, Blackboard is encouraging all customers to move to the Oracle 9i (version 9.2.0.0.0).
This document covers how to move a Blackboard Oracle 8i database to Oracle 9i.
The migration process will involve a period of database unavailability. The old database must be stopped
and connections restricted while moving data to the new database. The length of the outage is dependant
on the amount of data and performance of the disk subsystem.
This document assumes that the old and the new database will exist on the current server hardware. The
procedures for moving the database to new server hardware is very similar to what is described in this
document.
Migration Description
This document is for Administrators who are migrating from Small Scale Oracle 8.x.x to Small Scale Oracle
9.x.x.x. There are several methods to migrate from Oracle 8i to Oracle 9i. The method selected for this
document provides the most protection for the existing data. The method is to backup the database, export
the data, install the new database and import the data into the new database. If there is problem or a desire
to return to the Oracle 8i database, the previous database can be restored.
Technical skills
Performing a database migration requires specific technical skills. This document is written with the
assumption that the Administrator performing the migration has the following skills:
Prerequisites
Before starting the migration process there are certain prerequisites that have to be met before the upgrade
can occur successfully.
Ensure that the database server meets Oracle’s minimum hardware requirements and
Blackboard’s minimum hardware requirements. Blackboard requirements can be found on the
Behind the Blackboard Web site (http://www.blackboard.com/products/services/support.htm)
Ensure that there enough disk space to hold three times the existing used space. The method
described in this document produces a backup of the current installation, an export of the existing
data and a complete install of Oracle 9i. If disk space is a concern then the existing database
backup can be moved off the system.
All Blackboard services must be shutdown before the upgrade procedure can begin. This will close all
Blackboard database connections and will prevent the Blackboard application from trying to re-establish the
connections to the databases during the upgrade process.
#cd /usr/local/blackboard/tools/admin
#./ServiceController.sh services.stop
This command will backup all the files and subdirectories in the Backboard directory:
Overview
The first step in the migration process is to back up the current database. To backup an Oracle 8i database
all the Oracle software, data files, log files, control files, password and initialization files must be backed up.
Instructions
STEP 1
Log on to the database server as Oracle.
To locate all the files associated with Oracle 8i, log on using SQL*Plus as sysdba and issue the following
command:
# su - oracle
# sqlplus “/ as sysdba”
Connected to:
OracleXX Standard Edition Release X.X.X.X.X – XXbit Production
STEP 2
After getting a list of Oracle database files to backup, shutdown the database.
If Oracle hangs on a shutdown it may be necessary to issue a shutdown abort, restart the database and
then shutdown the database.
SQL>
It is important that the database server shuts down completely before migrating the databases.
STEP 3
Backup the databases after shutting down the Oracle server. The entire Oracle subdirectory should be
tarred and saved. To save disk space, this tar file can be moved off line. Use gnu tar and the z option to
create a compressed tar file which will save a significant amount of disk space. After backup, be sure to test
the restore procedure before migrating the databases.
This command will backup all the files and subdirectories in the directory specified by the $ORACLE_HOME
environment variable to a file called oracle_backup.tar.
STEP 4
After backing up the Oracle software, review the oracle8i_files.lst file to ensure that the Oracle database files
were included in the tar file. If the Oracle database files where not included then they should be tarred as
well. Here is an example where the database files are located in the /u01/oradata and /u02/oradata
directories.
or
Once the Oracle installation has been backed up and the restore process tested, the rest of the migration
may continue.
Overview
The next step in the migration process is to record tablespace information and export all user accounts
except sys and system. When the export file is imported it will expect a tablespace with the same name as
the tablespace that was exported. A list of tablespace names will be collected so that tablespace with the
same name can be created in the new database. To ensure that data is not modified, the database will be
started in a restricted mode. Only accounts that have been given restricted session privileges will be able to
connect. The default Blackboard accounts have not been granted this privilege.
Instructions
STEP 1
The database should be shutdown from the previous section, Backup the Existing Database. Restart the
database in restricted mode before continuing.
# sqlplus “/ as sysdba”
The startup restrict command will prevent most users from logging into the database server.
STEP 2
To create a SQL script for re-creating the existing tablespaces in the new server, execute the following
statements. For all of the following scripts that are created edit them to remove the first and last line that
begin with “SQL> “.
Furthermore, if you exit SQLPLUS and enter it again, execute the four set commands, for example set echo
off, before executing the commands to create the scripts. Otherwise, the scripts will contain non-SQL
statements that will cause errors when the scripts are run.
STEP 3
Execute the following statements to create a SQL script for re-creating existing users. All existing users are
re-created except; sys, system, dbsnmp, oe, qs_adm, qs_ws, qs_os, qs_cs, qs_cb, qs_cbadm, qs_es, qs,
scott, hr, pm, outln, odm, odm_mtr, wmsys, sh, ordsys, ordplugins, mdsys, ctxsys, xdb, anonymous,
olapsys, perfstat, aurora$jis$utility$, ose$http$admin, aurora$orb$anauthenticated, wksys, wkproxy, csmig,
wk_test, exfsys, sysman, dmsys, mgmt_view, si_informtn_schema, mddata, or dip.
STEP 4
To create a SQL script for re-granting the same roles to the existing users, execute the following statements:
STEP 5
To create a SQL script for re-granting the system privileges to the existing users, execute the following
statements.
After saving the scripts for recreating the tablespaces and users and the scripts for re-granting the roles and
privileges to the users, exit SQL*Plus.
STEP 6
The next task is to set the ORACLE NLS_LANG environment variable. The following is an example of setting
the environment in the SH or BASH shell:
The NLS_LANG variable should also be set in the .profile (for the SH shell) and .bash_profile (for the
BASH shell) files.
STEP 7
Estimate the size of the database. List all of the files that comprise the database to determine which
directories they are located in.
# sqlplus “/ as sysdba”
Connect to:
OracleXX Standard Edition Release X.X.X.X.X – XXbit Production
FILE_NAME
-------------------------------------------------------------------------------
-
/export/home/oracle/data/dbf/system01.dbf
/export/home/oracle/data/dbf/undotbs01.dbf
/export/home/oracle/bbdata/bbadmin_data_file1.dbf
/export/home/oracle/bbdata/bbadmin_indx_file1.dbf
/export/home/oracle/bbdata/bb_bb60_stats_data_file1.dbf
/export/home/oracle/bbdata/bb_bb60_stats_indx_file1.dbf
/export/home/oracle/bbdata/bb_bb60_data_file1.dbf
/export/home/oracle/bbdata/bb_bb60_indx_file1.dbf
/export/home/oracle/bbdata/CMS_DATA_file1.dbf
/export/home/oracle/bbdata/CMS_INDX_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_USERS_DATA_file1.dbf
FILE_NAME
-------------------------------------------------------------------------------
-
/export/home/oracle/bbdata/CMS_FILES_USERS_INDX_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_COURSES_DATA_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_COURSES_INDX_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_ORGS_DATA_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_ORGS_INDX_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_INST_DATA_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_INST_INDX_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_LIBRARY_DATA_file1.dbf
/export/home/oracle/bbdata/CMS_FILES_LIBRARY_INDX_file1.dbf
20 rows selected.
SQL>exit
Disconnected from Oracle XX Standard Edition Release X.X.X.X.X.X – Xxbit
Production
#
Navigate to the common directories indicated by the output of the previous command and determine the disk
space being used in each directory. In this case, there are two directories of interest.
# cd /export/home/oracle/data/dbf
# du -sh .
454M .
# cd /export/home/oracle/bbdata
# du -sh .
1.1G .
#
Add the disk usage of both directories to determine how much space is required to back up the existing
database.
STEP 8
After setting the NLS_LANG variable, export the data. To export the data use the Oracle exp command. Use
the system account to connect to the database. This is the only account that will be able to connect to the
database since it is running in restricted mode.
If the database is less than or equal to 2 GB in size, use the command below to export the data:
Substitute the names found in the recreate_users.sql file in the owner=(user1, user2, …) clause. The
minimum set of users consists of bbadmin, bb_bb60, bb_bb60_stats, and bb_bb60_report.
If the database is greater than 2 GB in size, divide the size of the database by two to determine the number
of database export files that will be needed to store the data. For example, if the database is 6 GB, then
three export files would be required. Use the command below to export the data, specifying the filenames
that will be used for data storage:
Perform the same substitution of names as in the example above for databases that are less than or equal
to 2GB. If enough filenames to store all of the data are not specified, Oracle will prompt for additional file
names. The filesize option for the Oracle exp command is available in Oracle versions 8.1.5 and
greater.
STEP 9
After export is complete, shutdown the Oracle database and database listener. To stop the database, use
SQL*Plus and connect to the database as sysdba:
# sqlplus “/ as sysdba”
Connect to:
OracleXX Standard Edition Release X.X.X.X.X – XXbit Production
SQL> shutdown
Database closed.
Database dismounted
ORACLE instance shut down.
SQL>exit
# lsnrctl stop
Connecting to (DESCRIPTION=(XXXXXXXXXXXXXXXXXXXXXX)))
The command completed successfully
#
STEP 10
After exporting the data and shutting down Oracle prepare to install Small-Scale Oracle 9i. The Oracle 8i
install can be removed by deleting the Oracle directories.
Overview
Blackboard Learning System – Basic Edition includes a version of Oracle designed to support the
Blackboard Learning System. This version of Oracle is smaller than a full license and can only be used to
support Blackboard Learning System – Basic Edition.
NOTE: These instructions are only intended for use with the Small-Scale Oracle
provided by Blackboard. Use the instructions provided with the database
management system for any other version of Oracle.
This section explains how to set the semaphores and shared menu configuration for Solaris.
NOTE: Red Hat Linux users should not change these parameters prior to
installing Small-Scale Oracle!
Before installing Small-Scale Oracle, parameters in the /etc/system file must be set as shown below.
set shmsys:shminfo_shmmax=294967295
set shmsys:shminfo_shmmin=1
set shmsys:shminfo_shmmni=100
set shmsys:shminfo_shmseg=10
*
*max number of semaphore identifiers:
set semsys:seminfo_semmni=50
*
*max number of semaphores per identifier:
*semmsl=largest number of processes of all instances < 512
set semsys:seminfo_semmsl=200
*
*max number of semaphores: semmns=semmni*semmsl
*semmns>=sum of all processes of all instances
set semsys:seminfo_semmns=10000
set semsys:seminfo_semopm=100
set semsys:seminfo_semvmx=32767
Changes to the /etc/system file do not become active until after a system reboot. Check the currently
active Solaris kernel parameters with the command sysdef.
The commands in this section apply to Red Hat Linux 7.2, Red Hat Linux Advanced Server 2.1, and Red Hat
Enterprise Linux 3.0.
Before installing Small-Scale Oracle, check that the following parameters are set in the
/etc/sysctl.conf file:
kernel.shmmax=294967295
The active shared memory and semaphore configuration can be verified by executing the following
commands:
echo /proc/sys/kernel/shmmax
echo /proc/sys/kernel/sem
To make the shared memory and semaphore configuration active without rebooting the system, execute the
following commands:
Installation
Follow the steps below to install the Small-Scale Oracle database software provided with the Blackboard
Learning System – Basic Edition.
NOTE: These instructions assume that the path to the directory for Small-Scale
Oracle is /usr/local/oracle. Do not install Small-Scale Oracle to
/usr/local/blackboard!
4 Verify that the server meets the hardware/software requirements for the
Blackboard Learning System – Basic Edition. Be sure that the correct version of
GNUTar is installed.
Linux:
small_scale_oracle_linux.bin
Solaris:
small_scale_oracle_solaris.bin
6 Login as Root.
7 Create the /usr/local/oracle directory.
mkdir /usr/local/oracle
export ORACLE_BASE=/usr/local/oracle
export ORACLE_HOME=/usr/local/oracle/9i
9 Create the dba and oinstall groups, if they do not already exist.
Linux:
grep oracle /etc/passwd
useradd –g oinstall -G dba –c “Oracle Software Owner” –d
/home/oracle –m oracle
Solaris:
grep oracle /etc/passwd
useradd –g oinstall -G dba –c “Oracle Software Owner” –d
/export/home/oracle –m oracle
mv /usr/local/oracle/small_scale_oracle_solaris.bin
$ORACLE_BASE
cd $ORACLE_BASE
chmod +x small_scale_oracle_solaris.bin
./small_scale_oracle_solaris.bin
NOTE: When installing Small-Scale Oracle, do not use @ in any Oracle database
user passwords. To be sure that Oracle database user passwords do not violate
Oracle rules for passwords, use only letters, numbers, and the underscore.
It is permissible to use @ in passwords for Blackboard Learning System user
accounts.
Overview
After the Small-Scale Oracle 9i database software is installed, import the Blackboard data into the database.
The Oracle import utility will attempt to import data into the same table space from which it was exported.
Before the data can be imported, the tablespaces have to be created. Previously a spool file with a create
table statement for each of the tablespaces that existed in the Oracle 8 database was created. This file was
saved as recreate_tablespaces.sql.
Before the database import can begin, the Blackboard database files path must be added to the
init${ORACLE_SID}.ora file. This assumes that the Blackboard database files are located at
/usr/local/oracle/bbdata. This section assumes that the ORACLE_SID value is BB60. Restart the
database before importing the Blackboard data.
# su – oracle
# cd $ORACLE_HOME/dbs
# cat >> init${ORACLE_SID}.ora <<EOF
db_create_file_dest=/usr/local/oracle/bbdata
EOF
# sqlplus “/ as sysdba”
SQL> shutdown immediate
SQL> startup
SQL> exit
Instructions
STEP 1
Create tablespaces. The database must be running.
# sqlplus “/ as sysdba”
SQL> @recreate_tablespaces.sql
STEP 2
After the tablespaces are created, all previous Blackboard Oracle users can be recreated by using the script
created in the previous step (Step 1).
SQL> @recreate_users.sql
STEP 3
Grant previous users them the same privileges that they had in the old version of the server, for example,
the privileges they had in Oracle 8i.
SQL> @regrant_role_privs.sql
SQL> @regrant_sys_privs.sql
STEP 4
Use the Oracle import utility to import the previously created dump file blackboard_data.dmp into the
database.
After the data is imported into the database, the migration of Oracle is complete. A cold backup should be
taken of the new database installation.
Once the import is complete the process is finished. Start and test the Blackboard Learning System to
ensure that it is working correctly.