One. Preparation installation
1. Installation of the Liunx system.
Oracle installation requires a lot of swap space (> 400m), with at least 128m memory. So in the installation of the Linux system, the SWAP partition should be placed near 0 tracks during partitioning. It is recommended that its partition is 800M or more. If there is enough hard disk space, it should be sufficient to consider the / usr and / partition space when partitioning. The following is my partition:
Hard disk 17.3g,
/ 5G;
/ usr 5.5g;
/ home 2 g;
/ var 3G;
/ TMP 1G;
/ SWAP 800M.
After the partition, select the installation package, the package with the COMPAT should be installed (need to be required when installing Oracle). Installing Oracle8i on LinuxServer requires at least 7G space.
It should be noted that 1. The maximum memory parameter is 0x4000000 after installation of Linux system is 64M (if your system is 128M memory, this value is half of memory) #define shmmax 0x4000000. To change this value to 0x8000000 (ie 128M) in / usr / src / linux / include / asm (probably this directory) VI Shmparam.h this file, you can see these parameters. After saving the file is restarted, you need to recompile the kernel. If you can't find this parameter in your system, you can do not modify it.
The installation system is best in English using the default language because the Oracle character set bugs. If Chinese uses Chinese, the settings for Chinese environment variables should be added (Export NLS_LANG = Chinese_China.zHS16CGB231280 or Export NLS_LANG = "Simplified Chinese"). But sometimes the installation interface is chasing code.
2. Need to download the package
JDK-1.3.1_01.i386
I386-glibc21-linux.tar
GLIBC-2.1.3-stubs.tar
Linux81701.tar
ENV_CTX.MK
3. Configuration of Linux system
a. Prepare user environment
GroupAdd DBA
GroupAdd OinsTall
UserAdd Oracle -g OinsTall -g DBA
Passwd oracle
Enter user password *******
b. Create an installation directory (take U01 as an example)
MKDIR / U01 /
* Oracle requires four directories and can be created.
MKDIR / U01 / U02 / U03 / U04 * /
Chown Oracle.dba / U01
CHMOD 777 / U01
C. Edit / etc / profile file
Add the following lines in the file
Java_home = / usr / java / jdk1.3.1_01
Classpath = .: ~: $ java_home / lib / dt.jar:
$ Java_home / lib / Tools.jar:
$ JAVA_HOME / lib / jaxp.jar:
$ JAVA_HOME / LIB
Export Java_Home ClassPath
IF! Echo $ PATH | / BIN / GREP -Q "$ java_home / bin";
THEN
Path = "$ PATH: $ java_home / bin"
Fi
. /usr/i386-glibc21-linux/bin/i386-glibc21-linux-env.sh
Export ld_assume_kernel = 2.2.5
Export LDemulation = ELF_I386_GLIBC21
Export Oracle_Base = / U01 / App / OracleExport Oracle_Home = $ Oracle_Base / Product / 8.1.7
Export oracle_sid = Orcl
Export ORA_NLS33 = $ Oracle_Home / Ocommon / NLS / Admin / Data
Export ClassPath = $ ClassPath:
. /$$_home/jdbc/lib/classes111.zip
Export LD_Library_Path = $ LD_LIBRARY_PATH
:
$ Oracle_Home / Lib: $ Oracle_Home / Network / LIB
Export Path = $ PATH: $ ORACLE_HOME / LIB: $ ORACLE_HOME
/ DBS: / ETC
Export Oracle_Term = VT100
# If after installation, Oracle uses Chinese, you need to increase after installation.
Under the three lines, before installation, if the default language used by the system is
Chinese, it should be designated as English, "ie" limited environment variable lc_all = c and
LANG = C.
EXPORT LC_ALL = zh_cn.gb2312
Export LC_CTYPE = zh_cn.gb2312
Export lang = zh_cn.gb2312
UMASK 022 / * If your umask value is not 022, you need to add this * /
These environment variable settings can be placed three places. If only Oracle account uses Oracle, you can put the environment variable under the / home / oracle. If you have other accounts in the system, you should be put In / etc / profile file, this file needs to be modified by root. If there are multiple databases in the system, the environment variable is placed in a separate execution script that can be run by the user, and the named Oracle_home / bin is in the Oracle_Home / BIN. Restart the system or run after saving ..bashrc command enables environment variables to take effect. You can also use the Source command.
2 start installation
1. Install the package required
RPM-IVH JDK-1.3.1_01.i386
TAR-XVF I386-glibc21-linux.tar
/ * CP to / us first first
Tar-xvf linux81701.tar -c / tmp /
/ * Unzip the installation disk to / TMP * /
2 start installation
After the system is restarted, Oracle is logged in, start WIN windows
CD / TMP / DISK1
./RunInstall / * Do this message * /
If it is installed with a disc installed, the / mnt / cdrom / runinstall command is executed, and the Oracle installation interface appears, select the source file path and the installation path. Next, let you add the group name oinstall, then there is a mistake to pop up "*** orainstroot.sh **", switch a console, with root in /u01/app***/8.1.7/ (ie Oracle_home The directory) executes the sh orapost.sh command. Note when selecting Java's path: Installed JDK1.3.1 its path is / usr / java. And the default Java path when installed, / usr / local / java pays attention to the root modification path. SID item Enter Orcl. After a period of installation, the system prompts × × INS_CTX.MK error. Under another console, download the downloaded Env_ctx.mk file CP to $ Oracle_Home / CTX / Lib (this paper is /u01/app/**/8.1.7/CTX/LIB). After returning, click Retry to continue the installation. In fact, this step is ignored or installed successfully. The end of the installation is that the system has prompts. At this time, the console is executed as root. SH (under $ ORACLE_HOME), click OK, pop up the window of the configuration NET8. Do not rush to create a database at this time. Switch the console, copy the downloaded Oracle patch Glibc-2.1.3-stubs.tar.gz to $ Oracle_HOME TAR-XVF /... Tar-xvf /... Tar.gz
Then run ./setup_stubs.sh After finishing the patch, return to the installation interface, create a database, select Perform Typical Configuration, and NEXT Create a database. After the database is created. Click EXIT, Oracle installation to complete. Restart the system. Execute the svrmgrl command to connect the database. LSNRCTL starts monitoring, then execures SQLPLUS to connect to the database.
Three installation Oracle should pay attention:
1 When installing, use an Oracle user to log in, don't be any Oracle.
2 Determine the system environment variable lc_all = c and lang = C before installation, so that there is no Chinese in Chinese.
3 If you use, set the environment variable NLS_LANG = Simplified Chinese_China.zhs16GBK, remember
4 During the installation process of the Oracle system and database establishment, each place has a language to set the language, and must pay attention to the choice. Use the Custom installation, there is a charset setting, select Chinese.
5 After installing oracle, you can change the environment variable back lc_all = zh_cn and lang = zh_cn