The client's Linux system is already installed and the company has no DBA and has to go on its own. This article uses for reference: https://www.cnblogs.com/binghe001/p/12950804.html
1. Download installation files
Baidu Netdisk: https://pan.baidu.com/s/1ec-k9ShBg7O91YPAAhJ6mA Extraction Code: rba4
2. Close the firewall
Operating user:root
systemctl stop firewalld.service systemctl disable firewalld.service
3. Install Dependent Packages
Operating user:root
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
Note: If you encounter a choice (y/n) halfway through, just type Y
4. Validate Dependent Packages
Operating user:root
rpm -q binutils compat-libcap1 compat-libstdc++-33 gcc gcc-c++ glibc glibc-devel ksh libaio libaio-devel libgcc libstdc++ libstdc++-devel libXi libXtst make sysstat unixODBC unixODBC-devel
Normally all packages will show installed, check for uninstalled packages
5. Create oracle users
Operating user:root
groupadd -g 502 oinstall groupadd -g 503 dba groupadd -g 504 oper groupadd -g 505 asmadmin useradd -u 502 -g oinstall -G oinstall,dba,asmadmin,oper -s /bin/bash -m oracle passwd oracle
You will be prompted to set your password at the last step
Note: After 500 is the average user
6. Unzip the Oracle installation package
Operating user: oracle
Note: Use su - User name, switch operation user
Store a directory of your choice, mine at root/oradata
unzip linux.x64_11gR2_database_1of2.zip unzip linux.x64_11gR2_database_2of2.zip
You may be prompted that you do not have permission to operate with
chown -R oracle:oinstall /oradata
That's it
Unzip to get a directory of database s
7. Modify system configuration
Operating user:root
vim /etc/security/limits.conf
Add the following configuration item at the end of the file
oracle soft nproc 2047 oracle hard nproc 16384 oracle soft nofile 1024 oracle hard nofile 65536 oracle soft stack 10240
8. Create Oracle installation directory
Operating user: oracle
Depending on the size of the partition, I am at / oradata/soft/oracle11g
9. Modify environment variables
Operating user: oracle
vim ~/.bash_profile
Add the following configuration item at the end of the file
export ORACLE_BASE=/oradata/soft/oracle11g export ORACLE_HOME=$ORACLE_BASE/product/11.2.0.3/dbhome_1 export ORACLE_SID=prod export ORACLE_UNQNAME=prod export NLS_LANG=.AL32UTF8 export PATH=${PATH}:${ORACLE_HOME}/bin/:$ORACLE_HOME/lib64
Making environment variables work
source ~/.bash_profile
10. Modify oracle configuration file
Operating user: oracle
Operations Directory: /oradata
Copy File Template
cp /oradata/database/response/db_install.rsp .
And one last . Can't leak. Will db_install.rsp file from copy to current directory
For db_install.rsp file for editing
vim db_install.rsp
The configuration items that need to be modified are as follows
oracle.install.option=INSTALL_DB_AND_CONFIG ORACLE_HOSTNAME=localhost #You can actually modify it to your own hostname or domain name (IP) UNIX_GROUP_NAME=oinstall INVENTORY_LOCATION=/oradata/soft/oraInventory SELECTED_LANGUAGES=en,zh_CN ORACLE_HOME=/oradata/soft/oracle11g/product/11.2.0.3/dbhome_1 ORACLE_BASE=/oradata/soft/oracle11g oracle.install.db.InstallEdition=EE oracle.install.db.DBA_GROUP=dba oracle.install.db.OPER_GROUP=oper oracle.install.db.config.starterdb.type=GENERAL_PURPOSE oracle.install.db.config.starterdb.globalDBName=oracle oracle.install.db.config.starterdb.SID=oracle oracle.install.db.config.starterdb.characterSet=AL32UTF8 oracle.install.db.config.starterdb.memoryOption=true oracle.install.db.config.starterdb.memoryLimit=1024 oracle.install.db.config.starterdb.installExampleSchemas=false oracle.install.db.config.starterdb.password.ALL=oracle #Or not set oracle.install.db.config.starterdb.control=DB_CONTROL oracle.install.db.config.starterdb.dbcontrol.enableEmailNotification=false oracle.install.db.config.starterdb.dbcontrol.emailAddress=test@qq.com #You can fill in your own mailbox address oracle.install.db.config.starterdb.automatedBackup.enable=false oracle.install.db.config.starterdb.storageType=FILE_SYSTEM_STORAGE oracle.install.db.config.starterdb.fileSystemStorage.dataLocation=/oradata/soft/oracle11g/data oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation=/oradata/soft/oracle11g/fast_recovery_area oracle.install.db.config.starterdb.automatedBackup.enable=false DECLINE_SECURITY_UPDATES=true
The method I use is to transfer the file directly to the local area, edit it and upload it. This is my file: https://pan.baidu.com/s/1Lr-M6KZ0UBLBtrjP7CwblQ Extraction code: m4c8
11. Install Database
Operating user: oracle
Operations Directory: /oradata/database
./runInstaller -silent -ignoreSysPrereqs -responseFile /oradata/db_install.rsp -ignorePrereq
Note: Some warnings will terminate the installation, -ignoreSysPrereqs and-ignorePrereq can skip warnings
Now wait for it to install itself, and you can use tail-f as prompted Command to open another interface to see the installation progress. It's just to see if you're stuck
When the following happens, it means that it is installed
/oradata/soft/oraInventory/orainstRoot.sh /oradata/soft/oracle11g/product/11.2.0.3/dbhome_1/root.sh To execute the configuration scripts: 1. Open a terminal window 2. Log in as "root" 3. Run the scripts 4. Return to this window and hit "Enter" key to continue Successfully Setup Software.
12. Installation Complete
Operating user:root
Execute the following two lines of commands, depending on where you installed them, as prompted by the information from the previous step.
/oradata/soft/oraInventory/orainstRoot.sh /oradata/soft/oracle11g/product/11.2.0.3/dbhome_1/root.sh
13. Verify installation results
Operating user: oracle
sqlplus / as sysdba
Enter SQL command line successfully
14. Start the database
Once installed, both listening and database are open, and if the server restarts, use lsnrctl start Start listening, administrator logs in and uses it startup Open database