How to remotely access ASM in Oracle

Source: Internet
Author: User
Tags connect reserved oracle database sqlplus

First, dynamic monitoring

1. Listening for files

[Oracle@node1 admin]$ More/u01/oracle/network/admin/listener.ora

Sid_list_listener =

(Sid_list =

(Sid_desc =

(Sid_name = Plsextproc)

(Oracle_home =/u01/oracle)

(program = Extproc)

)

)

LISTENER =

(Description_list =

(DESCRIPTION =

(address = (PROTOCOL = TCP) (HOST = Node1) (PORT = 1521))

(address = (PROTOCOL = IPC) (KEY = EXTPROC0))

)

)

2. Listening status

[Oracle@node1 admin]$ lsnrctl Status

Lsnrctl for linux:version 10.2.0.4.0-production on 18-jan-2012 13:38:42

Copyright (c) 1991, 2007, Oracle. All rights reserved.

Connecting to (description= address= (protocol=tcp) (Host=node1) (port=1521))

STATUS of the LISTENER

------------------------

Alias LISTENER

More Wonderful content: http://www.bianceng.cn/database/Oracle/

Version Tnslsnr for Linux:version 10.2.0.4.0-production

Start Date 18-jan-2012 13:32:49

Uptime 0 days 0 hr. 5 min. sec

Trace level off

Security On:local OS Authentication

SNMP off

Listener Parameter File/u01/oracle/network/admin/listener.ora

Listener Log File/u01/oracle/network/log/listener.log

Listening Endpoints Summary ...

(Description= (address= (protocol=tcp) (Host=node1) (port=1521))

(Description= (address= (PROTOCOL=IPC) (KEY=EXTPROC0))

Services Summary ...

Service "+asm" has 1 instance (s).

Instance "+asm", Status BLOCKED, has 1 handler (s) for the This service ...

Service "+ASM_XPT" has 1 instance (s).

Instance "+asm", Status BLOCKED, has 1 handler (s) for the This service ...

Service "Plsextproc" has 1 instance (s).

Instance "Plsextproc", Status UNKNOWN, has 1 handler (s) for the This service ...

Service "CHF" has 1 instance (s).

Instance "CHF", Status READY, has 1 handler (s) for the This service ...

Service "Chfxdb" has 1 instance (s).

Instance "CHF", Status READY, has 1 handler (s) for the This service ...

Service "CHF_XPT" has 1 instance (s).

Instance "CHF", Status READY, has 1 handler (s) for the This service ...

The command completed successfully

3. Client TNS file [with part of the test added (Ur=a)]

Vm_asm =

(DESCRIPTION =

(address = (PROTOCOL = TCP) (HOST = 192.168.1.30) (PORT = 1521))

(Connect_data =

(service_name = +asm)

(instance_name = +asm)

(ur=a) #分存在和不存在测试

)

)

VM_CHF =

(DESCRIPTION =

(address = (PROTOCOL = TCP) (HOST = 192.168.1.30) (PORT = 1521))

(Connect_data =

(service_name = CHF)

(instance_name = CHF)

)

)

4. No test (UR=A)

C:\users\xifenfei>tnsping vm_asm

TNS Ping Utility for 32-bit windows:version 11.2.0.1.0-production on 2 March-February-

2012 22:15:10

Copyright (c) 1997, Oracle. All rights reserved.

Parameter file used:

E:\oracle\11_2_0\network\admin\sqlnet.ora

Used the TNSNAMES adapter to resolve the alias

Attempt to connect (DESCRIPTION = (address = (PROTOCOL = TCP) (HOST = 192.168.1.30) (PORT =

1521)) (Connect_data = (service_name = +asm) (instance_name = +asm)))

OK (10 ms)

C:\users\xifenfei>sqlplus Sys/xifenfei@vm_asm as Sysdba

Sql*plus:release 11.2.0.1.0 Production on Thursday February 23 22:15:14 2012

Copyright (c) 1982, Oracle. All rights reserved.

ERROR:

Ora-12514:tns: The listener is currently unable to recognize the service requested in the connection descriptor

Please enter user name:

ERROR:

ORA-12560:TNS: Protocol Adapter error

Please enter user name:

ERROR:

ORA-12560:TNS: Protocol Adapter error

sp2-0157: Unable to connect to ORACLE after 3 attempts, exit Sql*plus

--Through the following database instance test, prove that dynamic monitoring is working properly, you can access the database

C:\users\xifenfei>sqlplus SYS/XIFENFEI@VM_CHF as Sysdba

Sql*plus:release 11.2.0.1.0 Production on Thursday February 23 21:55:03 2012

Copyright (c) 1982, Oracle. All rights reserved.

Connect to:

Oracle Database 10g Enterprise Edition Release 10.2.0.4.0-production

With the partitioning, OLAP, Data Mining and real application testing options

Sql> select instance_name from V$instance;

Instance_name

----------------

Chf

5. Including (ur=a) test

C:\users\xifenfei>tnsping vm_asm

TNS Ping Utility for 32-bit windows:version 11.2.0.1.0-production on 2 March-February-

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.