In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
[root@oraclep ~] # hostnamectl set-hostname oraclep
[root@oraclep ~] # vim / etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
:: 1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.56.118 oraclep
[root@oraclep ~] # su-oracle
Last login: 15:20:31 on July 2, 2002 on CST 2019pts/1
[oracle@oraclep ~] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 14:54:02 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to an idle instance.
SQL > startup mount
ORACLE instance started.
Total System Global Area 768294912 bytes
Fixed Size 2232312 bytes
Variable Size 452984840 bytes
Database Buffers 310378496 bytes
Redo Buffers 2699264 bytes
Database mounted.
SQL > alter database archivelog
Alter database archivelog
*
ERROR at line 1:
ORA-00265: instance recovery required, cannot set ARCHIVELOG mode
SQL > alter database open
Database altered.
SQL > shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL > startup mount
ORACLE instance started.
Total System Global Area 768294912 bytes
Fixed Size 2232312 bytes
Variable Size 452984840 bytes
Database Buffers 310378496 bytes
Redo Buffers 2699264 bytes
Database mounted.
SQL > alter database archivelog
Database altered.
SQL > alter database force logging
Database altered.
SQL > alter database open
Database altered.
SQL > archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence 4
Next log sequence to archive 6
Current log sequence 6
SQL > select force_logging from v$database
FOR
-
YES
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oraclep ~] $exit
[root@oraclep ~] # su-oracle
Last login: 3 / 7 / 3, 15:00:08 on CST 2019pts/0
[oracle@oraclep ~] $select * from v$logfile
-bash: syntax error near unexpected symbol `from'
[oracle@oraclep ~] $exit
Log out
[root@oraclep ~] # rz
Rz waiting to receive.
Zmodem trl+C coach
100% 119 KB 119 KB/s 00:00:01 0 Errors64.rpm...
[root@oraclep] # yum-y localinstall rlwrap-0.43-2.el7.x86_64.rpm
Loaded plug-in: fastestmirror
Checking rlwrap-0.43-2.el7.x86_64.rpm: rlwrap-0.43-2.el7.x86_64
Rlwrap-0.43-2.el7.x86_64.rpm will be installed
Resolving dependencies
-- > checking transaction
-> package rlwrap.x86_64.0.0.43-2.el7 will be installed
-- > processing dependency / usr/bin/python3.6, which is required by the package rlwrap-0.43-2.el7.x86_64
Loading mirror speeds from cached hostfile
Epel/x86_64/metalink | 4.5 kB 00:00:00
* base: mirror.jdcloud.com
* epel: mirrors.yun-idc.com
* extras: mirror.jdcloud.com
* updates: mirrors.tuna.tsinghua.edu.cn
Base | 3.6 kB 00:00:00
Epel | 5.3kB 00:00:00
Extras | 3.4 kB 00:00:00
Updates | 3.4 kB 00:00:00
-- > processing dependency perl (Data::Dumper), which is required by the package rlwrap-0.43-2.el7.x86_64
-- > checking transaction
-> package perl-Data-Dumper.x86_64.0.2.145-3.el7 will be installed
-> package python36.x86_64.0.3.6.8-1.el7 will be installed
-- > processing dependency python36-libs (x86-64) = 3.6.8-1.el7, which is required by the package python36- 3.6.8-1.el7.x86_64
-- > processing dependency libpython3.6m.so.1.0 () (64bit), which is required by the package python36-3.6.8-1.el7.x86_64
-- > checking transaction
-> package python36-libs.x86_64.0.3.6.8-1.el7 will be installed
-- > resolve dependency completion
Dependency resolution
=
Package Schema version Source size
=
Installing:
Rlwrap x8631 64 0.43-2.el7 / rlwrap-0.43-2.el7.x86_64 281k
Install for dependency:
Perl-Data-Dumper x8631 64 2.145-3.el7 base 47k
Python36 x8631 64 3.6.8-1.el7 epel 67k
Python36-libs x8631 64 3.6.8-1.el7 epel 8.6m
Transaction summary
=
Install 1 package (+ 3 dependent package)
Total: 9.0 M
Total downloads: 8.7 M
Installation size: 37 m
Downloading packages:
Python36-libs-3.6.8-1.el7.x86 _ FAILED 0% [] 0.0B python36-libs-3.6.8 s | 0 B--:-ETA
Http://fedora.cs.nctu.edu.tw/epel/7/x86_64/Packages/p/python36-libs-3.6.8-1.el7.x86_64.rpm: [Errno 14] HTTP Error 404-Not Found] 0.0BUnip s | 0 B--:-ETA
Another mirror is being tried.
To address this issue please refer to the below wiki article
Https://wiki.centos.org/yum-errors
If above article doesn't help to resolve this issue please use https://bugs.centos.org/.
(1can3): perl-Data-Dumper-2.145-3.el7.x86_64.rpm | 47 kB 00:00:00
Warning: / var/cache/yum/x86_64/7/epel/packages/python36-3.6.8-1.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID 352c64e5: NOKEY
The public key of python36-3.6.8-1.el7.x86_64.rpm has not been installed
(2ap3): python36-3.6.8-1.el7.x86_64.rpm | 67 kB 00:00:00
(3x3): python36-libs-3.6.8-1.el7.x86_64.rpm | 8.6MB 00:00:19
-
Total 439 kB/s | 8.7 MB 00:00:20
Retrieve the key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
Import GPG key 0x352C64E5:
User ID: "Fedora EPEL (7)"
Fingerprint: 91e9 7d7c 4a5e 96f1 7f3e 888f 6a2f aea2 352c 64e5
Software package: epel-release-7-11.noarch (@ extras)
From: / etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing: python36-libs-3.6.8-1.el7.x86_64 1 Compact 4
Installing: python36-3.6.8-1.el7.x86_64 2Cand4
Installing: perl-Data-Dumper-2.145-3.el7.x86_64 3 Compact 4
Installing: rlwrap-0.43-2.el7.x86_64 4 Compact 4
Validating: python36-3.6.8-1.el7.x86_64 1Univer 4
Validating: perl-Data-Dumper-2.145-3.el7.x86_64 2 Compact 4
Validating: python36-libs-3.6.8-1.el7.x86_64 3 Compact 4
Validating: rlwrap-0.43-2.el7.x86_64 4 Compact 4
Installed:
Rlwrap.x86_64 0RO 0.43-2.el7
Installed as a dependency:
Perl-Data-Dumper.x86_64 0VOR 2.145-3.el7 python36.x86_64 0RU 3.6.8-1.el7 python36-libs.x86_64 0RU 3.6.8-1.el7
Over!
[root@oraclep] # scp rlwrap-0.43-2.el7.x86_64.rpm 192.168.56.117purl ~
Root@192.168.56.117's password:
Rlwrap-0.43-2.el7.x86_64.rpm 100% 119KB 12.8MB/s 00:00
[root@oraclep] # ssh 192.168.56.117
Root@192.168.56.117's password:
Last login: Wed Jul 3 15:00:48 2019 from 192.168.56.118
[root@oracles] # yum-y localinstall rlwrap-0.43-2.el7.x86_64.rpm
Loaded plug-in: fastestmirror
Checking rlwrap-0.43-2.el7.x86_64.rpm: rlwrap-0.43-2.el7.x86_64
Rlwrap-0.43-2.el7.x86_64.rpm will be installed
Resolving dependencies
-- > checking transaction
-> package rlwrap.x86_64.0.0.43-2.el7 will be installed
-- > processing dependency / usr/bin/python3.6, which is required by the package rlwrap-0.43-2.el7.x86_64
Loading mirror speeds from cached hostfile
Epel/x86_64/metalink | 4.5 kB 00:00:00
* base: mirrors.tuna.tsinghua.edu.cn
* epel: mirrors.tuna.tsinghua.edu.cn
* extras: mirrors.tuna.tsinghua.edu.cn
* updates: mirrors.tuna.tsinghua.edu.cn
Base | 3.6 kB 00:00:00
Epel | 5.3kB 00:00:00
Extras | 3.4 kB 00:00:00
Updates | 3.4 kB 00:00:00
-- > processing dependency perl (Data::Dumper), which is required by the package rlwrap-0.43-2.el7.x86_64
-- > checking transaction
-> package perl-Data-Dumper.x86_64.0.2.145-3.el7 will be installed
-> package python36.x86_64.0.3.6.8-1.el7 will be installed
-- > processing dependency python36-libs (x86-64) = 3.6.8-1.el7, which is required by the package python36- 3.6.8-1.el7.x86_64
-- > processing dependency libpython3.6m.so.1.0 () (64bit), which is required by the package python36-3.6.8-1.el7.x86_64
-- > checking transaction
-> package python36-libs.x86_64.0.3.6.8-1.el7 will be installed
-- > resolve dependency completion
Dependency resolution
=
Package Schema version Source size
=
Installing:
Rlwrap x8631 64 0.43-2.el7 / rlwrap-0.43-2.el7.x86_64 281k
Install for dependency:
Perl-Data-Dumper x8631 64 2.145-3.el7 base 47k
Python36 x8631 64 3.6.8-1.el7 epel 67k
Python36-libs x8631 64 3.6.8-1.el7 epel 8.6m
Transaction summary
=
Install 1 package (+ 3 dependent package)
Total: 9.0 M
Total downloads: 8.7 M
Installation size: 37 m
Downloading packages:
Python36-libs-3.6.8-1.el7.x86 _ FAILED 0% [] 0.0B python36-libs-3.6.8 s | 0 B--:-ETA
Http://fedora.cs.nctu.edu.tw/epel/7/x86_64/Packages/p/python36-libs-3.6.8-1.el7.x86_64.rpm: [Errno 14] HTTP Error 404-Not Found] 0.0BUnip s | 0 B--:-ETA
Another mirror is being tried.
To address this issue please refer to the below wiki article
Https://wiki.centos.org/yum-errors
If above article doesn't help to resolve this issue please use https://bugs.centos.org/.
Warning: / var/cache/yum/x86_64/7/epel/packages/python36-3.6.8-1.el7.x86_64.rpm: header V3 RSA/SHA256 Signature, key ID 352c64e5: NOKEY
The public key of python36-3.6.8-1.el7.x86_64.rpm has not been installed
(1ap3): python36-3.6.8-1.el7.x86_64.rpm | 67 kB 00:00:00
(2ache 3): perl-Data-Dumper-2.145-3.el7.x86_64.rpm | 47 kB 00:00:01
(3x3): python36-libs-3.6.8-1.el7.x86_64.rpm | 8.6MB 00:00:19
-
Total 431 kB/s | 8.7 MB 00:00:20
Retrieve the key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
Import GPG key 0x352C64E5:
User ID: "Fedora EPEL (7)"
Fingerprint: 91e9 7d7c 4a5e 96f1 7f3e 888f 6a2f aea2 352c 64e5
Software package: epel-release-7-11.noarch (@ extras)
From: / etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing: python36-libs-3.6.8-1.el7.x86_64 1 Compact 4
Installing: python36-3.6.8-1.el7.x86_64 2Cand4
Installing: perl-Data-Dumper-2.145-3.el7.x86_64 3 Compact 4
Installing: rlwrap-0.43-2.el7.x86_64 4 Compact 4
Validating: python36-3.6.8-1.el7.x86_64 1Univer 4
Validating: perl-Data-Dumper-2.145-3.el7.x86_64 2 Compact 4
Validating: python36-libs-3.6.8-1.el7.x86_64 3 Compact 4
Validating: rlwrap-0.43-2.el7.x86_64 4 Compact 4
Installed:
Rlwrap.x86_64 0RO 0.43-2.el7
Installed as a dependency:
Perl-Data-Dumper.x86_64 0VOR 2.145-3.el7 python36.x86_64 0RU 3.6.8-1.el7 python36-libs.x86_64 0RU 3.6.8-1.el7
Over!
[root@oracles ~] # cat / home/oracle/.bash_profile
>
> alias sqlplus='rlwrap sqlplus'
> alias rman='rlwrap rman'
> EOF
[root@oracles ~] # exit
Log out
Connection to 192.168.56.117 closed.
[root@oraclep ~] # cat / home/oracle/.bash_profile
>
> alias sqlplus='rlwrap sqlplus'
> alias rman='rlwrap rman'
> EOF
[root@oraclep ~] # su-oracle
Last login: 3 / 7 / 3, 15:04:23 on CST 2019pts/0
[oracle@oraclep ~] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:13:37 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > select * from v$logfile
GROUP# STATUS TYPE
MEMBER
IS_
-
3 ONLINE
/ u01/app/oradata/yunhaip/redo03.log
NO
2 ONLINE
/ u01/app/oradata/yunhaip/redo02.log
NO
GROUP# STATUS TYPE
MEMBER
IS_
-
1 ONLINE
/ u01/app/oradata/yunhaip/redo01.log
NO
SQL > set linesize 200
SQL > set pagesize 50
SQL > select * from v$logfile
GROUP# STATUS TYPE
MEMBER
-
IS_
-
3 ONLINE
/ u01/app/oradata/yunhaip/redo03.log
NO
2 ONLINE
/ u01/app/oradata/yunhaip/redo02.log
NO
1 ONLINE
/ u01/app/oradata/yunhaip/redo01.log
NO
SQL > select member from v$logfile
MEMBER
-
/ u01/app/oradata/yunhaip/redo03.log
/ u01/app/oradata/yunhaip/redo02.log
/ u01/app/oradata/yunhaip/redo01.log
SQL > select * from v$log
GROUP# THREAD# SEQUENCE# BYTES BLOCKSIZE MEMBERS ARC STATUS FIRST_CHANGE# FIRST_TIME NEXT_CHANGE# NEXT_TIME
- --
1 1 4 52428800 512 1 YES INACTIVE 1022663 02-JUL-19 1036922 02-JUL-19
2 1 5 52428800 512 1 YES INACTIVE 1036922 02-JUL-19 1058279 03-JUL-19
3 1 6 52428800 512 1 NO CURRENT 1058279 03-JUL-19 2.8147E+14
SQL > alter database add standby logfile group 21'/ u01 size size 50m
Database altered.
SQL > alter database add standby logfile group 22'/ u01 size size 50m
Database altered.
SQL > alter database add standby logfile group 23'/ u01 size size 50m
Database altered.
SQL > alter database add standby logfile group 24'/ u01 size size 50m
Database altered.
SQL > create pfile from spfile
File created.
SQL > host
[oracle@oraclep ~] $cd $ORACLE_HOME/dbs
[oracle@oraclep dbs] $pwd
/ u01/app/oracle/product/11.2.0/db_1/dbs
[oracle@oraclep dbs] $scp inityunhaip.ora 192.168.56.117:/u01/app/oracle/product/11.2.0/db_1/dbs/
The authenticity of host '192.168.56.117 (192.168.56.117)' can't be established.
ECDSA key fingerprint is SHA256:MZlavdM0myCuuIkRXJhhutLZufmC7UmAk4/308p+WG0.
ECDSA key fingerprint is MD5:a3:d1:78:7c:60:c7:48:2a:7d:fb:4c:50:12:d5:93:8c.
Are you sure you want to continue connecting (yes/no)? Yes
Warning: Permanently added '192.168.56.117' (ECDSA) to the list of known hosts.
Oracle@192.168.56.117's password:
Inityunhaip.ora 100% 909 1.1MB/s 00:00
[oracle@oraclep dbs] $cat > > / u01/app/oracle/product/11.2.0/db_1/dbs/inityunhaip.ora * .db_unique_name='yunhaip'
> * .fal_server='yunhais'
> * .log_archive_config='dg_config= (yunhaip,yunhais)'
> * .log_archive_dest_1='location=use_db_recovery_file_dest valid_for= (all_logfiles, all_roles) db_unique_name=yunhaip'
> * .log_archive_dest_2='service=yunhais lgwr async valid_for= (online_logfile,primary_role) db_unique_name=yunhais'
> * .log_archive_dest_state_1=ENABLE
> * .log_archive_dest_state_2=ENABLE
> * .standby_file_management='AUTO'
> * .db_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
> * .log_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
> EOF
[oracle@oraclep dbs] $cat > > / u01/app/oracle/product/11.2.0/db_1/dbs/inityunhaip.ora shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL > create spfile from pfile
File created.
SQL > startup
ORACLE instance started.
Total System Global Area 768294912 bytes
Fixed Size 2232312 bytes
Variable Size 452984840 bytes
Database Buffers 310378496 bytes
Redo Buffers 2699264 bytes
Database mounted.
Database opened.
SQL > ALTER USER SYS IDENTIFIED BY sys
User altered.
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oraclep dbs] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Tue Jul 2 16:19:01 2019
[oracle@oracles ~] $cd $ORACLE_HOME/dbs
[oracle@oracles dbs] $cat > > / u01/app/oracle/product/11.2.0/db_1/dbs/inityunhaip.ora * .db_unique_name='yunhais'
> * .fal_server='yunhaip'
> * .log_archive_config='dg_config= (yunhaip,yunhais)'
> * .log_archive_dest_1='location=use_db_recovery_file_dest valid_for= (all_logfiles, all_roles) db_unique_name=yunhais'
> * .log_archive_dest_2='service=yunhaip lgwr async valid_for= (online_logfile,primary_role) db_unique_name=yunhaip'
> * .log_archive_dest_state_1=ENABLE
> * .log_archive_dest_state_2=ENABLE
> * .standby_file_management='AUTO'
> * .db_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
> * .log_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
> EOF
[oracle@oracles dbs] $cat inityunhaip.ora
Yunhaip.__db_cache_size=310378496
Yunhaip.__java_pool_size=4194304
Yunhaip.__large_pool_size=4194304
Yunhaip.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
Yunhaip.__pga_aggregate_target=310378496
Yunhaip.__sga_target=461373440
Yunhaip.__shared_io_pool_size=0
Yunhaip.__shared_pool_size=134217728
Yunhaip.__streams_pool_size=0
* .audit_file_dest='/u01/app/admin/yunhaip/adump'
* .audit_trail='db'
* .compatible='11.2.0.0.0'
* .control_files='/u01/app/oradata/yunhaip/control01.ctl','/u01/app/fast_recovery_area/yunhaip/control02.ctl'
* .db_block_size=8192
* .db_domain=''
* .db_name='yunhaip'
* .db_recovery_file_dest='/u01/app/fast_recovery_area'
* .db_recovery_file_dest_size=4322230272
* .diagnostic_dest='/u01/app'
* .dispatchers=' (PROTOCOL=TCP) (SERVICE=yunhaipXDB)'
* .memory_target=769654784
* .open_cursors=300
* .processes=150
* .remote_login_passwordfile='EXCLUSIVE'
* .undo_tablespace='UNDOTBS1'
* .db_unique_name='yunhais'
* .fal_server='yunhaip'
* .log_archive_config='dg_config= (yunhaip,yunhais)'
* .log_archive_dest_1='location=use_db_recovery_file_dest valid_for= (all_logfiles, all_roles) db_unique_name=yunhais'
* .log_archive_dest_2='service=yunhaip lgwr async valid_for= (online_logfile,primary_role) db_unique_name=yunhaip'
* .log_archive_dest_state_1=ENABLE
* .log_archive_dest_state_2=ENABLE
* .standby_file_management='AUTO'
* .db_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
* .log_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
[oracle@oracles dbs] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep dbs] $pwd
/ u01/app/oracle/product/11.2.0/db_1/dbs
[oracle@oraclep dbs] $scp orapwyunhaip 192.168.56.117:/u01/app/oracle/product/11.2.0/db_1/dbs/
Oracle@192.168.56.117's password:
Orapwyunhaip 100% 1536 1.4MB/s 00:00
[oracle@oraclep dbs] $strings spfileyunhaip.ora
Yunhaip.__db_cache_size=310378496
Yunhaip.__java_pool_size=4194304
Yunhaip.__large_pool_size=4194304
Yunhaip.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
Yunhaip.__pga_aggregate_target=310378496
Yunhaip.__sga_target=461373440
Yunhaip.__shared_io_pool_size=0
Yunhaip.__shared_pool_size=134217728
Yunhaip.__streams_pool_size=0
* .audit_file_dest='/u01/app/admin/yunhaip/adump'
* .audit_trail='db'
* .compatible='11.2.0.0.0'
* .control_files='/u01/app/oradata/yunhaip/control
01. CtlrecoveryharmareaUniverse control l02.ctl'
* .db_block_size=8192
* .db_domain=''
* .db_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
* .db_name='yunhaip'
* .db_recovery_file_dest='/u01/app/fast_recovery_area'
* .db_recovery_file_dest_size=4322230272
* .db_unique_name='yunhaip'
* .diagnostic_dest='/u01/app'
* .dispatchers=' (PROTOCOL=TCP) (SERVICE=yunhaipXDB)'
* .fal_server='yunhais'
* .log_archive_config='dg_config= (yunhaip,yunhais)'
* .log_archive_dest_
1='location=use_db_recovery_file_dest valid_for= (all_logfiles, all_roles) db_unique_name=yunhaip'
* .log_archive_dest_2='service=yunhais lgwr async valid_for= (online_logfile,primary_role) db_unique_name=yunhais'
* .log_archive_dest_state_1='ENABLE'
* .log_archive_dest_state_2='ENABLE'
* .log_file_name_convert='/u01/app/oradata/yunhaip','/u01/app/oradata/yunhaip'
* .memory_target=769654784
* .open_cursors=300
* .processes=150
* .remote_login_passwordfile='EXCLUSIVE'
* .standby_file_management=
'AUTO'
* .undo_tablespace='UNDOTBS1'
01. Ctlrecoveryrecovery areaUnip
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 15:26:24 2019 from 192.168.56.118
[oracle@oracles ~] $cd $ORACLE_HOME/dbs
[oracle@oracles dbs] $mkdir-p / u01/app/oracle
[oracle@oracles dbs] $mkdir-p / u01/app/admin/yunhaip/ {a _ r _ r _ c _ r _ c _ r _ r _ u} dump
[oracle@oracles dbs] $mkdir-p / u01/app/oradata/yunhaip/
[oracle@oracles dbs] $mkdir-p / u01/app/fast_recovery_area/yunhaip/
[oracle@oracles dbs] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep dbs] $cd.. / network/admin/
[oracle@oraclep admin] $ls
Listener1907023 afternoon 2038.bak listener.ora samples shrept.lst sqlnet1907023 afternoon 2038.bak sqlnet.ora
[oracle@oraclep admin] $cat listener.ora
# listener.ora Network Configuration File: / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1521))
(ADDRESS = (PROTOCOL = TCP) (HOST = oracles) (PORT = 1521))
)
)
ADR_BASE_LISTENER = / u01/app
[oracle@oraclep admin] $vim listener.ora
# listener.ora Network Configuration File: / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = oracles) (PORT = 1521))
)
)
ADR_BASE_LISTENER = / u01/app
"listener.ora" 13L, 361C has been written
"listener.ora" 13L, 361C has been written
# listener.ora Network Configuration File: / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1521))
(ADDRESS = (PROTOCOL = TCP) (HOST = oraclep) (PORT = 1521))
)
)
ADR_BASE_LISTENER = / u01/app
[oracle@oraclep admin] $pwd
/ u01/app/oracle/product/11.2.0/db_1/network/admin
[oracle@oraclep admin] $cat > > / u01/app/oracle/product/11.2.0/db_1/network/admin/tnsnames.ora yunhaip =
> (DESCRIPTION =
> (ADDRESS_LIST =
> (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.118) (PORT = 1521))
>)
> (CONNECT_DATA =
> (SERVICE_NAME = yunhaip)
>)
>)
>
> yunhais =
> (DESCRIPTION =
> (ADDRESS_LIST =
> (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.117) (PORT = 1521))
>)
> (CONNECT_DATA =
> (SERVICE_NAME = yunhais)
>)
>)
> EOF
[oracle@oraclep admin] $cat tnsnames.ora
Yunhaip =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.118) (PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = yunhaip)
)
)
Yunhais =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.117) (PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = yunhais)
)
)
[oracle@oraclep admin] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 15:32:36 2019 from 192.168.56.118
[oracle@oracles ~] $cd / u01/app/oracle/product/11.2.0/db_1/network/admin
[oracle@oracles admin] $cat > > / u01/app/oracle/product/11.2.0/db_1/network/admin/tnsnames.ora yunhaip =
> (DESCRIPTION =
> (ADDRESS_LIST =
> (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.118) (PORT = 1521))
>)
> (CONNECT_DATA =
> (SERVICE_NAME = yunhaip)
>)
>)
>
> yunhais =
> (DESCRIPTION =
> (ADDRESS_LIST =
> (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.117) (PORT = 1521))
>)
> (CONNECT_DATA =
> (SERVICE_NAME = yunhais)
>)
>)
> EOF
[oracle@oracles admin] $cat tnsnames.ora
Yunhaip =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.118) (PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = yunhaip)
)
)
Yunhais =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.117) (PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = yunhais)
)
)
[oracle@oracles admin] $cd.. /.. / dbs/
[oracle@oracles dbs] $ls
Init.ora inityunhaip.ora orapwyunhaip
[oracle@oracles dbs] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:39:48 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to an idle instance.
SQL > create spfile from pfile
File created.
SQL > startup nomount
ORACLE instance started.
Total System Global Area 768294912 bytes
Fixed Size 2232312 bytes
Variable Size 452984840 bytes
Database Buffers 310378496 bytes
Redo Buffers 2699264 bytes
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles dbs] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep admin] $lsnrctl start
LSNRCTL for Linux: Version 11.2.0.3.0-Production on 03-JUL-2019 15:40:37
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Starting / u01/app/oracle/product/11.2.0/db_1/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 11.2.0.3.0-Production
System parameter file is / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
Log messages written to / u01/app/diag/tnslsnr/oraclep/listener/alert/log.xml
Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)
Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=oraclep) (PORT=1521)
Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)
STATUS of the LISTENER
-
Alias LISTENER
Version TNSLSNR for Linux: Version 11.2.0.3.0-Production
Start Date 03-JUL-2019 15:40:39
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
Listener Log File / u01/app/diag/tnslsnr/oraclep/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=oraclep) (PORT=1521))
The listener supports no services
The command completed successfully
[oracle@oraclep admin] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 15:38:10 2019 from 192.168.56.118
[oracle@oracles ~] $ls
Ls lsattr lsblk lscpu lshw lsinitrd lsipc lslocks lslogins lsmem lsmod lsnodes lsnrctl lsnrctl0 lsns lsscsi
[oracle@oracles ~] $lsnrctl start
LSNRCTL for Linux: Version 11.2.0.3.0-Production on 03-JUL-2019 15:40:59
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Starting / u01/app/oracle/product/11.2.0/db_1/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 11.2.0.3.0-Production
System parameter file is / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
Log messages written to / u01/app/oracle/diag/tnslsnr/oracles/listener/alert/log.xml
Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)
Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=oracles) (PORT=1521)
Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)
STATUS of the LISTENER
-
Alias LISTENER
Version TNSLSNR for Linux: Version 11.2.0.3.0-Production
Start Date 03-JUL-2019 15:41:01
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
Listener Log File / u01/app/oracle/diag/tnslsnr/oracles/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=oracles) (PORT=1521))
The listener supports no services
The command completed successfully
[oracle@oracles ~] $tnsping yunhais
TNS Ping Utility for Linux: Version 11.2.0.3.0-Production on 03-JUL-2019 15:41:30
Copyright (c) 1997, 2011, Oracle. All rights reserved.
Used parameter files:
/ u01/app/oracle/product/11.2.0/db_1/network/admin/sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.117) (PORT = 1521)) (CONNECT_DATA = (SERVICE_NAME = yunhais)
OK (0 msec)
[oracle@oracles ~] $tnsping yunhaip
TNS Ping Utility for Linux: Version 11.2.0.3.0-Production on 03-JUL-2019 15:41:35
Copyright (c) 1997, 2011, Oracle. All rights reserved.
Used parameter files:
/ u01/app/oracle/product/11.2.0/db_1/network/admin/sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = 192.168.56.118) (PORT = 1521)) (CONNECT_DATA = (SERVICE_NAME = yunhaip)
OK (0 msec)
[oracle@oracles ~] $rman target sys/sys@yunhaip auxiliary sys/sys@yunhais
Recovery Manager: Release 11.2.0.3.0-Production on Wed Jul 3 15:43:07 2019
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to target database: YUNHAIP (DBID=665781658)
RMAN-00571: =
RMAN-00569: = ERROR MESSAGE STACK FOLLOWS =
RMAN-00571: =
RMAN-00554: initialization of internal recovery manager package failed
RMAN-04006: error from auxiliary database: ORA-12528: TNS:listener: all appropriate instances are blocking new connections
[oracle@oracles ~] $rman target sys/sys@yunhaip auxiliary /
Recovery Manager: Release 11.2.0.3.0-Production on Wed Jul 3 15:43:58 2019
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to target database: YUNHAIP (DBID=665781658)
Connected to auxiliary database: YUNHAIP (not mounted)
RMAN > exit
Recovery Manager complete.
[oracle@oracles ~] $cd $ORACLE_HOME/network
[oracle@oracles network] $cd admin/
[oracle@oracles admin] $pwd
/ u01/app/oracle/product/11.2.0/db_1/network/admin
[oracle@oracles admin] $ls
Listener.ora samples shrept.lst sqlnet.ora tnsnames.ora
[oracle@oracles admin] $cat > > / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora SID_LIST_LISTENER =
> (SID_LIST =
> (SID_DESC =
> (GLOBAL_DBNAME = yunhais)
> (ORACLE_HOME = / u01/app/oracle/product/11.2.0/db_1)
> (SID_NAME = yunhaip)
>)
>)
>
> EOF
[oracle@oracles admin] $cat listener.ora
# listener.ora Network Configuration File: / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
# Generated by Oracle configuration tools.
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1521))
(ADDRESS = (PROTOCOL = TCP) (HOST = oracles) (PORT = 1521))
)
)
ADR_BASE_LISTENER = / u01/app/oracle
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = yunhais)
(ORACLE_HOME = / u01/app/oracle/product/11.2.0/db_1)
(SID_NAME = yunhaip)
)
)
[oracle@oracles admin] $lsn
Lsnodes lsnrctl lsnrctl0 lsns
[oracle@oracles admin] $lsnrctl stop
LSNRCTL for Linux: Version 11.2.0.3.0-Production on 03-JUL-2019 15:46:16
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)
The command completed successfully
[oracle@oracles admin] $lsnrctl start
LSNRCTL for Linux: Version 11.2.0.3.0-Production on 03-JUL-2019 15:46:25
Copyright (c) 1991, 2011, Oracle. All rights reserved.
Starting / u01/app/oracle/product/11.2.0/db_1/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 11.2.0.3.0-Production
System parameter file is / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
Log messages written to / u01/app/oracle/diag/tnslsnr/oracles/listener/alert/log.xml
Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)
Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=oracles) (PORT=1521)
Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)
STATUS of the LISTENER
-
Alias LISTENER
Version TNSLSNR for Linux: Version 11.2.0.3.0-Production
Start Date 03-JUL-2019 15:46:25
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
Listener Log File / u01/app/oracle/diag/tnslsnr/oracles/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=oracles) (PORT=1521))
Services Summary...
Service "yunhais" has 1 instance (s).
Instance "yunhaip", status UNKNOWN, has 1 handler (s) for this service...
The command completed successfully
[oracle@oracles admin] $cat > > / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora duplicate target database for standby from active database nofilenamecheck
Starting Duplicate Db at 03-JUL-19
Using target database control file instead of recovery catalog
Allocated channel: ORA_AUX_DISK_1
Channel ORA_AUX_DISK_1: SID=19 device type=DISK
Contents of Memory Script:
{
Backup as copy reuse
Targetfile'/ u01 targetfile'/ u01qqapapapwyunhaip' auxiliary format
'/ u01apapapwyunhaip' apwyunhaip'
}
Executing Memory Script
Starting backup at 03-JUL-19
Allocated channel: ORA_DISK_1
Channel ORA_DISK_1: SID=40 device type=DISK
Finished backup at 03-JUL-19
Contents of Memory Script:
{
Backup as copy current controlfile for standby auxiliary format'/ u01According to oradataUniverse control 01.ctl'
Restore clone controlfile to'/ u01 from App from fastening recovery area
'/ u01According to oradataUniverse control l01.ctl'
}
Executing Memory Script
Starting backup at 03-JUL-19
Using channel ORA_DISK_1
Channel ORA_DISK_1: starting datafile copy
Copying standby control file
Output file name=/u01/app/oracle/product/11.2.0/db_1/dbs/snapcf_yunhaip.f tag=TAG20190703T154737 RECID=1 STAMP=1012664859
Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:07
Finished backup at 03-JUL-19
Starting restore at 03-JUL-19
Using channel ORA_AUX_DISK_1
Channel ORA_AUX_DISK_1: copied control file copy
Finished restore at 03-JUL-19
Contents of Memory Script:
{
Sql clone 'alter database mount standby database'
}
Executing Memory Script
Sql statement: alter database mount standby database
Contents of Memory Script:
{
Set newname for tempfile 1 to
"/ u01/app/oradata/yunhaip/temp01.dbf"
Switch clone tempfile all
Set newname for datafile 1 to
"/ u01/app/oradata/yunhaip/system01.dbf"
Set newname for datafile 2 to
"/ u01/app/oradata/yunhaip/sysaux01.dbf"
Set newname for datafile 3 to
"/ u01/app/oradata/yunhaip/undotbs01.dbf"
Set newname for datafile 4 to
"/ u01/app/oradata/yunhaip/users01.dbf"
Backup as copy reuse
Datafile 1 auxiliary format
"/ u01/app/oradata/yunhaip/system01.dbf" datafile
2 auxiliary format
"/ u01/app/oradata/yunhaip/sysaux01.dbf" datafile
3 auxiliary format
"/ u01/app/oradata/yunhaip/undotbs01.dbf" datafile
4 auxiliary format
"/ u01/app/oradata/yunhaip/users01.dbf"
Sql 'alter system archive log current'
}
Executing Memory Script
Executing command: SET NEWNAME
Renamed tempfile 1 to / u01/app/oradata/yunhaip/temp01.dbf in control file
Executing command: SET NEWNAME
Executing command: SET NEWNAME
Executing command: SET NEWNAME
Executing command: SET NEWNAME
Starting backup at 03-JUL-19
Using channel ORA_DISK_1
Channel ORA_DISK_1: starting datafile copy
Input datafile file number=00001 name=/u01/app/oradata/yunhaip/system01.dbf
Output file name=/u01/app/oradata/yunhaip/system01.dbf tag=TAG20190703T154752
Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:01:35
Channel ORA_DISK_1: starting datafile copy
Input datafile file number=00002 name=/u01/app/oradata/yunhaip/sysaux01.dbf
Output file name=/u01/app/oradata/yunhaip/sysaux01.dbf tag=TAG20190703T154752
Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:01:15
Channel ORA_DISK_1: starting datafile copy
Input datafile file number=00003 name=/u01/app/oradata/yunhaip/undotbs01.dbf
Output file name=/u01/app/oradata/yunhaip/undotbs01.dbf tag=TAG20190703T154752
Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:15
Channel ORA_DISK_1: starting datafile copy
Input datafile file number=00004 name=/u01/app/oradata/yunhaip/users01.dbf
Output file name=/u01/app/oradata/yunhaip/users01.dbf tag=TAG20190703T154752
Channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:03
Finished backup at 03-JUL-19
Sql statement: alter system archive log current
Contents of Memory Script:
{
Switch clone datafile all
}
Executing Memory Script
Datafile 1 switched to datafile copy
Input datafile copy RECID=1 STAMP=1012665062 file name=/u01/app/oradata/yunhaip/system01.dbf
Datafile 2 switched to datafile copy
Input datafile copy RECID=2 STAMP=1012665062 file name=/u01/app/oradata/yunhaip/sysaux01.dbf
Datafile 3 switched to datafile copy
Input datafile copy RECID=3 STAMP=1012665063 file name=/u01/app/oradata/yunhaip/undotbs01.dbf
Datafile 4 switched to datafile copy
Input datafile copy RECID=4 STAMP=1012665063 file name=/u01/app/oradata/yunhaip/users01.dbf
Finished Duplicate Db at 03-JUL-19
RMAN > exit
Recovery Manager complete.
[oracle@oracles admin] $cat > > / u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora select status from v$instance
STATUS
-
MOUNTED
SQL > alter database open
Alter database open
*
ERROR at line 1:
ORA-10458: standby database requires recovery
ORA-01152: file 2 was not restored from a sufficiently old backup
ORA-01110: data file 2:'/ u01 *
SQL > alter database recover managed standby database using current logfile disconnect from session
Database altered.
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles admin] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep admin] $cd / u01/app/diag/
Rdbms/ tnslsnr/
[oracle@oraclep admin] $cd / u01/app/diag/rdbms/
[oracle@oraclep rdbms] $ls
Yunhaip
[oracle@oraclep rdbms] $cd yunhaip/
[oracle@oraclep yunhaip] $ll
Total dosage 0
-rw-r- 1 oracle oinstall 0 July 2 15:13 i_1.mif
Drwxr-x--- 15 oracle oinstall 188 July 2 15:13 yunhaip
[oracle@oraclep yunhaip] $cd yunhaip/trace/
[oracle@oraclep trace] $vim alert_yunhaip.log
Tue Jul 02 15:13:36 2019
Starting ORACLE instance (normal)
LICENSE_MAX_SESSION = 0
LICENSE_SESSIONS_WARNING = 0
Shared memory segment for instance monitoring created
Picked latch-free SCN scheme 3
Using LOG_ARCHIVE_DEST_1 parameter default value as USE_DB_RECOVERY_FILE_DEST
Autotune of undo retention is turned on.
IMODE=BR
ILAT = 27
LICENSE_MAX_USERS = 0
SYS auditing is disabled
Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options.
ORACLE_HOME = / u01/app/oracle/product/11.2.0/db_1
System name: Linux
Node name: oracles
Release: 3.10.0-957.el7.x86_64
Version: # 1 SMP Thu Nov 8 23:39:32 UTC 2018
Machine: x86_64
Using parameter settings in client-side pfile/ u01/app/admin/yunhaip/pfile/init.ora on machine oracles
System parameters with non-default values:
Processes = 150
Memory_target = 736m
Control_files = "/ u01/app/oradata/yunhaip/control01.ctl"
Control_files = "/ u01/app/fast_recovery_area/yunhaip/control02.ctl"
Db_block_size = 8192
Compatible = "11.2.0.0.0"
Db_recovery_file_dest = "/ u01/app/fast_recovery_area"
Db_recovery_file_dest_size= 4122M
Undo_tablespace = "UNDOTBS1"
Remote_login_passwordfile= "EXCLUSIVE"
Db_domain = ""
Dispatchers = "(PROTOCOL=TCP) (SERVICE=yunhaipXDB)"
Audit_file_dest = "/ u01/app/admin/yunhaip/adump"
Audit_trail = "DB"
Db_name = "yunhaip"
Open_cursors = 300
Diagnostic_dest = "/ u01/app"
Tue Jul 02 15:13:38 2019
PMON started with pid=2, OS id=10079
Tue Jul 02 15:13:38 2019
PSP0 started with pid=3, OS id=10081
Tue Jul 02 15:13:39 2019
VKTM started with pid=4, OS id=10084 at elevated priority
VKTM running at (1) millisec precision with DBRM quantum (100) ms
Tue Jul 02 15:13:39 2019
GEN0 started with pid=5, OS id=10088
Tue Jul 02 15:13:39 2019
DIAG started with pid=6, OS id=10090
Tue Jul 02 15:13:39 2019
DBRM started with pid=7, OS id=10092
Tue Jul 02 15:13:39 2019
DIA0 started with pid=8, OS id=10094
PING [ARC2]: Heartbeat failed to connect to standby 'yunhais'. Error is 12154.
Wed Jul 03 15:47:53 2019
Thread 1 advanced to log sequence 9 (LGWR switch)
Current log# 3 seq# 9 mem# 0: / u01/app/oradata/yunhaip/redo03.log
Wed Jul 03 15:47:54 2019
Archived Log entry 3 added for thread 1 sequence 8 ID 0x27aeb09a dest 1:
Wed Jul 03 15:51:01 2019
ALTER SYSTEM ARCHIVE LOG
Wed Jul 03 15:51:01 2019
Thread 1 advanced to log sequence 10 (LGWR switch)
Current log# 1 seq# 10 mem# 0: / u01/app/oradata/yunhaip/redo01.log
Wed Jul 03 15:51:01 2019
Archived Log entry 4 added for thread 1 sequence 9 ID 0x27aeb09a dest 1:
Wed Jul 03 15:52:36 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: Error 12154 creating remote archivelog file 'yunhais'
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:52:57 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: Error 12154 creating remote archivelog file 'yunhais'
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:53:17 2019
Error 12154 received logging on to the standby
Suppressing further error logging of LOG_ARCHIVE_DEST_2.
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:53:37 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:54:26 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:54:46 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:55:06 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
ORACLE Instance yunhaip-Archival Error. Archiver continuing.
Wed Jul 03 15:55:26 2019
Error 12154 received logging on to the standby
FAL [server, ARC3]: FAL archive failed, see trace file.
ARCH: FAL archive failed. Archiver continuing
[oracle@oraclep trace] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:55:59 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL > startup
ORACLE instance started.
Total System Global Area 768294912 bytes
Fixed Size 2232312 bytes
Variable Size 452984840 bytes
Database Buffers 310378496 bytes
Redo Buffers 2699264 bytes
Database mounted.
Database opened.
SQL > select switchover_status,database_role from v$database
SWITCHOVER_STATUS DATABASE_ROLE
--
TO STANDBY PRIMARY
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oraclep trace] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 15:40:46 2019 from 192.168.56.118
[oracle@oracles ~] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:57:37 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > select status from v$instance
STATUS
-
MOUNTED
SQL > select switchover_status,database_role from v$database
SWITCHOVER_STATUS DATABASE_ROLE
--
NOT ALLOWED PHYSICAL STANDBY
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles ~] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:58:17 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence 10
Next log sequence to archive 0
Current log sequence 12
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles ~] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep trace] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:58:28 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence 10
Next log sequence to archive 12
Current log sequence 12
SQL > alter database switch logs
Alter database switch logs
*
ERROR at line 1:
ORA-02000: missing ALL keyword
SQL > alter system switch logfile
System altered.
SQL > archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence 11
Next log sequence to archive 13
Current log sequence 13
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oraclep trace] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 15:57:34 2019 from 192.168.56.118
[oracle@oracles ~] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:59:12 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence 11
Next log sequence to archive 0
Current log sequence 13
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles ~] $sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 15:59:46 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > alter database recover managed standby database cancel
Database altered.
SQL > alter database open
Database altered.
SQL > alter database recover managed standby database using current logfile disconnect
Database altered.
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles ~] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep trace] $sqlplus test/test
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 16:00:39 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > create table test (id int, nums int)
Table created.
SQL > insert into test values (1Jue 2)
1 row created.
SQL > commit
Commit complete.
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oraclep trace] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 15:59:09 2019 from 192.168.56.118
[oracle@oracles ~] $sqlplus test/test
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 16:01:59 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > select * from test
ID NUMS
--
1 2
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oracles ~] $exit
Log out
Connection to 192.168.56.117 closed.
[oracle@oraclep trace] $sqlplus test/test
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 16:02:19 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > insert into test values (2jue 2)
1 row created.
SQL > exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@oraclep trace] $ssh 192.168.56.117
Oracle@192.168.56.117's password:
Last login: Wed Jul 3 16:01:52 2019 from 192.168.56.118
[oracle@oracles ~] $sqlplus test/test
SQL*Plus: Release 11.2.0.3.0 Production on Wed Jul 3 16:02:36 2019
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL > select * from test
ID NUMS
--
1 2
2 2
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.