Standard Korean pronunciation entry -vowels and consonants

2023-03-14   ES  

Preface

In order to back up an old database, the company needs to install Oracle services on the new server. Because it is a 11G version, although there are many online information, they are copied and pasted by Dongpin. The author has stumbled through more exploration, and hereby records the approximate installation process.

Let’s talk about the pits first:

1. Determine whether there is an Oracle client, server or environment variable on the server, be sure to remove it and clear it, otherwise there will be hidden dangers in subsequent use. I did not use the new version of the client during the installation process. As a result, when the IMP imports the data file, it is prompted:

IMP-00003: Encountered Oracle error 942
ORA-00942: Table or view does not exist
IMP-00017: Due to Oracle error 942, the following statements fail:

I found it for a long time to find out that it wasOracle’s server and client version do not match the client version and cause, finally adjusted it to the same version before the import was successful.

2. New Oracle users and user groups are newly built. Be careful when doing file authorization, and the scope of unauthorized unauthorization is too large. You must also pay attention to reporting an error prompt during the installation process. If it is prompted to read a file failure on the way, you must first pay attention to whether to read the file. It may be that some configurations are not adjusted to read the document left by history during installation.

3, the character set is carefully set, the library can not be changed

4. Look at the server memory in advance, the hard disk is not enough to mount in advance

View linux basic information

1. View system version:cat /etc/redhat-release

2. View the system bit:uname -m

linux version Oracle11g installation package download

download address:https://www.oracle.com/cn/technical-resources/

Big version 11g, small version choice by yourself

download is two compressed packages:

linux.x64_11gR2_database_1of2.zip

linux.x64_11gR2_database_2of2.zip

Configuration before installation

1. Modify the host name, add host name and IP corresponding record

Note: Many online data tutorials need to be configured. I am ashamed that I do n’t know what this configuration is, so I only modified the host name and did not correspond to the IP.

sed -i "s/HOSTNAME=localhost.localdomain/HOSTNAME=oracledb/" /etc/sysconfig/network
hostname oracledb
vim /etc /hosts # Edit hosts

2, close Selinux

sed -i "s/SELINUX=enforcing/SELINUX=disabled/" /etc/selinux/config 
setenforce 0
Note: If the prompt is wrong, it may be closed before, just ignore

3. Create users and groups

# Create Oinstall, database administrator group DBA, and Oracle users 
 groupadd -g 200 oinstall 
 Groupadd -g 201 DBA 
 Useradd -U 440 -G OINSTALL -G DBA Oracle #(Main Group OINSTALL, other groups: DBA) 
 passwd oracle #(p)

4. Modify kernel parameters

vim /etc/sysctl.conf # Edit sysctl.conf, add the following parameters at the end

net.ipv4.ip_local_port_range= 9000 65500

fs.file-max = 6815744

kernel.shmall = 10523004

kernel.shmmax = 6465333657

kernel.shmmni = 4096

kernel.sem = 250 32000 100128

net.core.rmem_default=262144

net.core.wmem_default=262144

net.core.rmem_max=4194304

net.core.wmem_max=1048576

fs.aio-max-nr = 1048576

: WQ save and exit
sysctl -P # to make the configuration take effect

5. Modify system resource restrictions

vim /etc/security/limits.conf # Edit limits.conf, add the following parameters at the end
oracle  soft  nproc  2047
oracle  hard  nproc  16384
oracle  soft  nofile  1024
oracle  hard  nofile  65536

 ​

6. Create the installation directory and allocate permissions

mkdir -p /oracle/ 
chmod 755 /oracle/ 
chown oracle.dba -R / oracle/

7、Set Oracle environment variable

vim ~/.bash_profile # editor
export ORACLE_BASE=/oracle
export ORACLE_HOME=$ORACLE_BASE/data/product/11.2.0/db_1
export PATH=$PATH:$HOME/bin:$ORACLE_HOME/bin
export ORACLE_SID=orcl
export ORACLE_PID=ora11g
export NLS_LANG=AMERICAN_AMERICA.AL32UTF8
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/usr/lib

Save and exit

source ~/.bash_profile # to make the configuration take effect immediately 

 ENV | GREP ORA # View whether the environment variable is completed

Installation database

1. An installation dependency package

yum -y install binutils compat-libcap1 compat-libstdc++-33 compat-libstdc++-33*i686 compat-libstdc++-33*.devel compat-libstdc++-33 compat-libstdc++-33*.devel gcc gcc-c++ glibc glibc*.i686 glibc-devel glibc-devel*.i686 ksh libaio libaio*.i686 libaio-devel libaio-devel*.devel libgcc libgcc*.i686 libstdc++ libstdc++*.i686 libstdc++-devel libstdc++-devel*.devel libXi libXi*.i686 libXtst libXtst*.i686 make sysstat unixODBC unixODBC*.i686 unixODBC-devel unixODBC-devel*.i686/

2, decompress installation package

Note: It is recommended to move the installation package in advance to the /Oracle directory authorized before
unzip linux.x64_11gR2_database_1of2.zip
unzip linux.x64_11gR2_database_2of2.zip

After decompression, enter the /oracle /database directory. There are three .RSP files in this directory for templates for answering files during silent installation. The role of the three files is:

db_install.rsp: Installation response 
 dbca.rsp: Create a database response 
 Netca.RSP: Establishing a response to network settings such as monitoring, local service names

3. Silent installation file configuration

CD/Oracle/DataBase/Response # into the Response directory 
 cp db_install.rsp db_install_copy.rsp # Back a copy db_install.rsp to avoid changing errors 
 vim db_install.rsp # editor, adjust according to the configuration below

oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0

oracle.install.option=INSTALL_DB_SWONLY

ORACLE_HOSTNAME=oracledb

UNIX_GROUP_NAME=dba

INVENTORY_LOCATION=/oracle/data/oraInventory #important

SELECTED_LANGUAGES=en,zh_CN

ORACLE_HOME=/oracle/data/product/11.2.0/db_1 #important

ORACLE_BASE=/oracle/data #important

oracle.install.db.InstallEdition=EE

oracle.install.db.isCustomInstall=false

oracle.install.db.customComponents=oracle.server:11.2.0.1.0,oracle.sysman.ccr:10.2.7.0.0,oracle.xdk:11.2.0.1.0,oracle.rdbms.oci:11.2.0.1.0,oracle.network:11.2.0.1.0,oracle.network.listener:11.2.0.1.0,oracle.rdbms:11.2.0.1.0,oracle.options:11.2.0.1.0,oracle.rdbms.partitioning:11.2.0.1.0,oracle.oraolap:11.2.0.1.0,oracle.rdbms.dm:11.2.0.1.0,oracle.rdbms.dv:11.2.0.1.0,orcle.rdbms.lbac:11.2.0.1.0,oracle.rdbms.rat:11.2.0.1.0

oracle.install.db.DBA_GROUP=dba

oracle.install.db.OPER_GROUP=oinstall

oracle.install.db.CLUSTER_NODES=

oracle.install.db.config.starterdb.type=GENERAL_PURPOSE

oracle.install.db.config.starterdb.globalDBName=ora11g

oracle.install.db.config.starterdb.SID=ora11g

oracle.install.db.config.starterdb.characterSet=AL32UTF8

oracle.install.db.config.starterdb.memoryOption=true

oracle.install.db.config.starterdb.memoryLimit=1500

oracle.install.db.config.starterdb.installExampleSchemas=false

oracle.install.db.config.starterdb.enableSecuritySettings=true

oracle.install.db.config.starterdb.password.ALL=oracle

oracle.install.db.config.starterdb.password.SYS=

oracle.install.db.config.starterdb.password.SYSTEM=

oracle.install.db.config.starterdb.password.SYSMAN=

oracle.install.db.config.starterdb.password.DBSNMP=

oracle.install.db.config.starterdb.control=DB_CONTROL

oracle.install.db.config.starterdb.gridcontrol.gridControlServiceURL=

oracle.install.db.config.starterdb.dbcontrol.enableEmailNotification=false

oracle.install.db.config.starterdb.dbcontrol.emailAddress=

oracle.install.db.config.starterdb.dbcontrol.SMTPServer=

oracle.install.db.config.starterdb.automatedBackup.enable=false

oracle.install.db.config.starterdb.automatedBackup.osuid=

oracle.install.db.config.starterdb.automatedBackup.ospwd=

oracle.install.db.config.starterdb.storageType=FILE_SYSTEM_STORAGE

oracle.install.db.config.starterdb.fileSystemStorage.dataLocation=

oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation=

oracle.install.db.config.asm.diskGroup=

oracle.install.db.config.asm.ASMSNMPPassword=

MYORACLESUPPORT_USERNAME=

MYORACLESUPPORT_PASSWORD=

SECURITY_UPDATES_VIA_MYORACLESUPPORT=

DECLINE_SECURITY_UPDATES=true    //must be set to TRUE

PROXY_HOST=

PROXY_PORT=

PROXY_USER=

PROXY_PWD=

Save and exit

less/oracle/database/response/db_install.rsp | GREP -V "#" | GREP -V "^$"# View configuration

4. Start installation silently

SU -Oracle # Switch to Oracle users 

 CD/Oracle/DataBase/ #enter/oracle/database directory 
 ./runinstaller -silent -Force -ResponseFile/Oracle/database/response/db_install.rsp

When SuccessFully Setup Software appears. Prove that it has been successfully installed, and then use the prompt to execute the script by the ROOT user

sh /oracle/data/oraInventory/orainstRoot.sh
sh /oracle/database/product/11.2.0/db_1/root.sh

5. Configuration monitoring program

Start monitoring: LSNRCTL Start 
 Stop monitoring: LSNRCTL Stop 
 Restart supervision: LSNRCTL RELOAD 
 View monitoring: LSNRCTL Status
$ Oracle_Home/Bin/Netca/Silent/ResponseFile/Oracle/dataBase/Response/netca.rsp # 6 6 6

6. Silently built the library

SU -ROOT # Switch to ROOT users 
 vim /opt/database/response/dbca.rsp
gdbname = "OrCl" # 78 line 
 Sid = "orCl" # 149 line 
 Characterset = "Al32UTF8" # 415 line 
 NationalCharaCterset = "UTF8" # 425 line
SU -Oracle # Switch to Oracle users 
 $ Oracle_Home/Bin/DBCA -SILENT -RESPONSEFILE /OPT/DataBase/Response/dbca.RSP #

Note: After the execution, you will clear the screen first. After the screen is cleared, there is no prompt. Enter the password of the Oracle user directly, return to the car, and then enter it again, and return to the car. Wait a while, and will start to create automatically.

7. Open port 1521 (required for remote connection to Oracle)

View whether the port is open: Firewall-CMD-Query-PORT = 1521/TCP 

 Permanent open 1521-side number: Firewall-CMD-PerManent-Zone = Public-ADD-PORT = 1521/TCP 

 Restart the firewall: SystemCtl Restart Firewalld.service 

 View firewall status: SystemCtl Status Firewalld.service 

 Remarks: Start | Close | Restart the firewall 

 SystemCtl [Start | Stop | RESTART] Firewalld.service

Follow -up is the guidance library or the creation of the user table structure for verification. At this point Oracle 11G is silent installation. There will be a variety of problems on the way. You can search for solutions more, and Du Niang is still very powerful.

PS: Finally, I have to talk about this editor. It is really too useful to use it. It has been organized by about three o’clock. It has been tossed for more than two hours. East and west, do everything in the vip of vip in the flower, the Buddha has been the Buddha …

source

Related Posts

Python 3.8 version, install and use the Pymouse library

Ruby basic knowledge (1)

F1 score, Micro F1Score, Macro F1Score

Software construct LAB5 error use guide ()

Standard Korean pronunciation entry -vowels and consonants

Random Posts

Luogu P6192 [Template] The smallest Stanner Tree

Use PyeChartsco in Django

Thymeleaf calls onClick passing the js function (multi -parameter) writing

AIX+Oracle11g+ASM Add Disk expansion LHDZ

[javascript] 2. JS compatibility writing of IE/FF