1.oracle 11.2.0.4 download
--failed by below way because of support.oracle.com
wget -O p13390677_112040_Linux-x86-64_1of7.zip -b http://aru-akam.oracle.com/adcarurepos/vol/patch43/PLATFORM/CORE/Linux-x86-64/R80112040/p13390677_112040_Linux-x86-64_1of7.zip?FilePath=/adcarurepos/vol/patch43/PLATFORM/CORE/Linux-x86-64/R80112040/p13390677_112040_Linux-x86-64_1of7.zip&File=p13390677_112040_Linux-x86-64_1of7.zip¶ms=NzR6di9WZk0rb29Bd2hRdWxSK1NDUTphcnU9MTY3MTYzNzUmZW1haWw9YWxsZXlfbGlAaW5mb3N5cy5jb20mZmlsZV9pZD02NDMxMjgwNiZwYXRjaF9maWxlPXAxMzM5MDY3N18xMTIwNDBfTGludXgteDg2LTY0XzFvZjcuemlwJnVzZXJpZD1vLWFsbGV5X2xpQGluZm9zeXMuY29tJnNpemU9MTM5NTU4Mjg2MCZjb250ZXh0PUFAMTArSEBhYXJ1dm10cDA4Lm9yYWNsZS5jb20rUEAmZG93bmxvYWRfaWQ9Mzc4NTczNDUy&AuthParam=1525485913_406039a2baccf313676f2e5356f00aa4
wget -O p13390677_112040_Linux-x86-64_2of7.zip -b http://aru-akam.oracle.com/adcarurepos/vol/patch43/PLATFORM/CORE/Linux-x86-64/R80112040/p13390677_112040_Linux-x86-64_2of7.zip?FilePath=/adcarurepos/vol/patch43/PLATFORM/CORE/Linux-x86-64/R80112040/p13390677_112040_Linux-x86-64_2of7.zip&File=p13390677_112040_Linux-x86-64_2of7.zip¶ms=Ynp3dWxyWW5TOXpqc3A1bTNjaUV2dzphcnU9MTY3MTYzNzUmZW1haWw9YWxsZXlfbGlAaW5mb3N5cy5jb20mZmlsZV9pZD02NDMxMjgwNyZwYXRjaF9maWxlPXAxMzM5MDY3N18xMTIwNDBfTGludXgteDg2LTY0XzJvZjcuemlwJnVzZXJpZD1vLWFsbGV5X2xpQGluZm9zeXMuY29tJnNpemU9MTE1MTMwNDU4OSZjb250ZXh0PUFAMTArSEBhYXJ1dm10cDAyLm9yYWNsZS5jb20rUEAmZG93bmxvYWRfaWQ9Mzc4NTc0NDYz&AuthParam=1525486684_40a640206064a469387267b74b92ad97
2.create user/group/directory
oracle12c:
[root@db-test ~]# id oracle
uid=1001(oracle) gid=1002(oinstall) groups=1002(oinstall),1001(dba)
[root@db-test ~]#
oracle11g:
user:oracle
ora11g.env
#add by Alley
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_HOSTNAME=pss-test-db-test; export ORACLE_HOSTNAME
ORACLE_UNQNAME=auchan11g; export ORACLE_UNQNAME
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1; export ORACLE_HOME
ORACLE_SID=auchan11g; export ORACLE_SID
ORACLE_TERM=xterm; export ORACLE_TERM
NLS_LANG=AMERICAN_AMERICA.ZHS16GBK; export NLS_LANG
PATH=/usr/sbin:$PATH; export PATH
PATH=$ORACLE_HOME/bin:$PATH; export PATH
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
/*
[root@getoraclelnx01 Server]# useradd -g oinstall -G dba oracle11g
[root@getoraclelnx01 Server]# mkdir -p /data/u02/app/oracle
[root@getoraclelnx01 Server]# chown -R oracle11g:oinstall /data/u02/app/oracle
[root@getoraclelnx01 Server]# chmod -R 775 /data/u02/app/oracle
*/
[oracle@db-test ~]$ source .db-test
[oracle@db-test ~]$ source ora12c.env
[oracle@db-test ~]$ source ora11g.env
mkdir -p /u01/app/oracle/product/11.2.0/db_1
chmod -R 775 /u01/app/oracle/product/11.2.0/db_1
chown -R oracle:oinstall /u01/app/oracle/product/11.2.0/db_1
chmod -R 775 /data/oracle11g/
chown -R oracle:oinstall /data/oracle11g/
[oracle@db-test ~]$ ll
total 1112
drwxr-xr-x 2 oracle oinstall 73 May 4 08:08 cc
-rw-r--r-- 1 oracle oinstall 1039982 May 3 07:36 cc.zip
-rw-r--r-- 1 oracle oinstall 25194 May 5 12:03 db11g.rsp
-rwxr-xr-x 1 oracle oinstall 2086 Apr 21 12:16 info2
-rwxr-xr-x 1 oracle oinstall 27219 Apr 20 23:56 KYS.py
-rw-r--r-- 1 oracle oinstall 27219 Apr 20 23:56 KYS.py.1
-rw-r--r-- 1 oracle oinstall 538 May 5 11:27 ora11g.env
-rw-r--r-- 1 oracle oinstall 537 May 5 11:28 ora12c.env
---图形界面方式
[root@db-test ~]# xhost +
access control disabled, clients can connect from any host
[root@db-test ~]#
[oracle@db-test ~]$ ssh -X oracle@172.16.0.6
The authenticity of host '172.16.0.6 (172.16.0.6)' can't be established.
ECDSA key fingerprint is SHA256:wL1SJdf8C5PO4GxvEJiiY+kgursuCPIAZSaqL27r8mQ.
ECDSA key fingerprint is MD5:4c:32:62:67:1a:5a:b4:76:93:d1:74:4f:6d:17:9d:4e.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '172.16.0.6' (ECDSA) to the list of known hosts.
Password:
Last login: Sat May 5 11:36:32 2018 from db-test
[oracle@db-test ~]$ cd /data/oracle11g/database/
[oracle@db-test database]$ ./runInstaller
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 14184 MB Passed
Checking swap space: must be greater than 150 MB. Actual 17407 MB Passed
Checking monitor: must be configured to display at least 256 colors
>>> Could not execute auto check for display colors using command /usr/bin/xdpyinfo. Check if the DISPLAY variable is set. Failed <<<<
Some requirement checks failed. You must fulfill these requirements before
continuing with the installation,
Continue? (y/n) [n] y
>>> Ignoring required pre-requisite failures. Continuing...
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-05-05_11-40-13AM. Please wait ...[oracle@db-test database]$ You can find the log of this install session at:
/u01/app/oraInventory/logs/installActions2018-05-05_11-40-13AM.log
[oracle@db-test database]$
[oracle@db-test database]$ ls
install readme.html response rpm runInstaller sshsetup stage welcome.html
[oracle@db-test database]$ cd
[oracle@db-test ~]$ ls
cc cc.zip db11g.rsp info2 KYS.py KYS.py.1 ora11g.env ora12c.env
[oracle@db-test ~]$ source ora11g.env
[oracle@db-test ~]$ vi ora11g.env
[oracle@db-test ~]$ dbca
[oracle@db-test ~]$ sqlplus / as sysdba
SQL*Plus: Release 11.2.0.4.0 Production on Sat May 5 12:43:26 2018
Copyright (c) 1982, 2013, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> show parameter control
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
control_file_record_keep_time integer 7
control_files string /u01/app/oracle/oradata/auchan
11g/control01.ctl, /u01/app/or
acle/fast_recovery_area/auchan
11g/control02.ctl
control_management_pack_access string DIAGNOSTIC+TUNING
[root@db-test db_1]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda2 30G 22G 8.1G 73% /
devtmpfs 28G 0 28G 0% /dev
tmpfs 28G 7.4G 21G 27% /dev/shm
tmpfs 28G 25M 28G 1% /run
tmpfs 28G 0 28G 0% /sys/fs/cgroup
/dev/sdc1 2.0T 457G 1.5T 24% /data
/dev/sda1 497M 79M 419M 16% /boot
tmpfs 5.6G 0 5.6G 0% /run/user/0
/dev/sdb1 111G 29G 77G 27% /mnt/resource
tmpfs 5.6G 0 5.6G 0% /run/user/1001
/dev/loop0 4.3G 4.3G 0 100% /mnt/centos7
[root@db-test db_1]#