<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>《远程访问ASM》的评论</title>
	<atom:link href="https://www.xifenfei.com/2012/02/%e8%bf%9c%e7%a8%8b%e8%ae%bf%e9%97%aeasm.html/feed" rel="self" type="application/rss+xml" />
	<link>https://www.xifenfei.com/2012/02/%e8%bf%9c%e7%a8%8b%e8%ae%bf%e9%97%aeasm.html</link>
	<description>提供7*24专业数据库(Oracle,SQL Server,MySQL,PostgreSQL等)恢复和技术支持@Tel:17813235971</description>
	<lastBuildDate>Thu, 11 Dec 2025 02:46:14 +0000</lastBuildDate>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>作者：惜分飞</title>
		<link>https://www.xifenfei.com/2012/02/%e8%bf%9c%e7%a8%8b%e8%ae%bf%e9%97%aeasm.html/comment-page-1#comment-689</link>
		<dc:creator><![CDATA[惜分飞]]></dc:creator>
		<pubDate>Fri, 24 Feb 2012 00:38:45 +0000</pubDate>
		<guid isPermaLink="false">https://www.xifenfei.com/?p=2575#comment-689</guid>
		<description><![CDATA[How to connect to ASM instance from a remote client (Oracle Net) [ID 340277.1]
[shell]
Applies to:
Oracle Net Services - Version: 10.1.0.4.0 and later   [Release: 10.1 and later ]
Oracle Server - Enterprise Edition - Version: 9.2.0.8 to 11.1.0.6   [Release: 9.2 to 11.1]
Enterprise Manager for Oracle Database - Version: 10.2.0.3 and later    [Release: 10.2 and later]
Enterprise Manager Base Platform - Version: 10.2.0.4 and later    [Release: 10.2 and later]
Information in this document applies to any platform.
Goal

Connecting to ASM instance remotely using Oracle Net and tools like SQL*Plus.

This note will resolve help resolve the following errors when trying to connect to an ASM isntance remotely

ORA-12505 TNS:listener could not resolve SID given in connect descriptor
ORA-12541: TNS:no listener
ORA-15000: command disallowed by current instance type
ORA-12528: TNS:listener: all appropriate instances are blocking new connections
ORA-1031:   insufficient privileges

Solution
This solution cannot be accomplished using Network Manager (GUI)

The solution is to 
   * Edit the listener.ora on ASM server 
   * Edit the tnsnames.ora on the client 
   * Setup your remote login password for your ASM instance on the ASM server
   * Set your SYS password using ORAPWD for the ASM instance
   * Use the properly formatted connect string to connect with your tool 

1) Edit the listener.ora on ASM server

   a) Logon to the ASM/Database server 

   b) Locate your listener.ora (typically located in the $ORACLE_HOME/network/admin)

   c) Add a SID_LIST_LISTENER entry for your ASM instance (see example below) 

EXAMPLE 
SID_LIST_LISTENER =
    (SID_LIST =
      (SID_DESC =
         (SID_NAME = +ASM)
         (ORACLE_HOME = c:\oracle\app\product\11.1.0\db_1)
      )
   )

   d) Stop the listener

lsnrctl stop

   e) restart the listener

lsnrctl start


2) Edit the tnsnames.ora on the client 

   a) Logon to the client machine that will be used to connect to the ASM instance 
          NOTE: the client machine can also be the ASM/Database server (ie for DBCONTROL)

   b) Locate your tnsnames.ora (typically in the $ORACLE_HOME/network/admin)
   c) Add an entry (tnsalias) for your ASM instance (see example) 

EXAMPLE
ASM =
   (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = kbcook-1)(PORT = 1521))
      (CONNECT_DATA =
         (SERVER = DEDICATED)
         (SID_NAME = +ASM)
         (UR=A)
      )
   )

3) Setup your remote login password for your ASM instance on the ASM server

   a) Logon to the ASM/Database server

   b) Locate the parameter file for your ASM instance (typically $ORACLE_HOME/dbs/init+ASM.ora [unix] or $ORACLE_HOME/dbs/init+ASM.ora [windows] ) 

   c) Edit the parameter file and add 

         remote_login_passwordfile = exclusive ... for stand alone ASM setups
         remote_login_passwordfile = shared ... for ASM setups that also use Real Application Cluster (RAC)
  
   d) Save the file
   NOTE: It may be required that an PFILE be created from an SPFILE in order to be able to edit the file properly ... once the line have been added ... the process can be reversed 

                 For more details Note 249664.1 Pfile vs SPfile ... may be used 

4) Set your SYS password using ORAPWD for the ASM instance

   a) Logon to the ASM/Database server 

   b) Locate your orapw&lt;sid&gt; file for your ASM instance (typically $ORACLE_HOME/dbs/orapw+ASM)

   c) Rename the file to orapw&lt;sid&gt;.old 
  
   d) Run orapwd to reset the password (see example below) 

EXAMPLE
mv &quot;orapw+ASM&quot; &quot;orapw+ASM.old&quot;
orapwd file=orapw+ASM password=kbcook

5) Use the properly formatted connect string for your tool 

Connnect to the ASM instance using the password (#4 above) and the tnsalias (#2 above)

EXAMPLES
C:\oracle\app\product\11.1.0\db_1\BIN\SQLPLUS.EXE &quot;sys/kbcook@asm as sysdba&quot;

&lt;OR&gt;

sqlplus &quot;sys/kbcook@asm as sysdba&quot;

&lt;OR&gt;

sqlplus &quot;sys@asm as sysdba&quot; ... then supply the password when prompted 
[/shell]]]></description>
		<content:encoded><![CDATA[<p>How to connect to ASM instance from a remote client (Oracle Net) [ID 340277.1]</p>
<pre class="brush: bash; title: ; notranslate">
Applies to:
Oracle Net Services - Version: 10.1.0.4.0 and later   [Release: 10.1 and later ]
Oracle Server - Enterprise Edition - Version: 9.2.0.8 to 11.1.0.6   [Release: 9.2 to 11.1]
Enterprise Manager for Oracle Database - Version: 10.2.0.3 and later    [Release: 10.2 and later]
Enterprise Manager Base Platform - Version: 10.2.0.4 and later    [Release: 10.2 and later]
Information in this document applies to any platform.
Goal

Connecting to ASM instance remotely using Oracle Net and tools like SQL*Plus.

This note will resolve help resolve the following errors when trying to connect to an ASM isntance remotely

ORA-12505 TNS:listener could not resolve SID given in connect descriptor
ORA-12541: TNS:no listener
ORA-15000: command disallowed by current instance type
ORA-12528: TNS:listener: all appropriate instances are blocking new connections
ORA-1031:   insufficient privileges

Solution
This solution cannot be accomplished using Network Manager (GUI)

The solution is to 
   * Edit the listener.ora on ASM server 
   * Edit the tnsnames.ora on the client 
   * Setup your remote login password for your ASM instance on the ASM server
   * Set your SYS password using ORAPWD for the ASM instance
   * Use the properly formatted connect string to connect with your tool 

1) Edit the listener.ora on ASM server

   a) Logon to the ASM/Database server 

   b) Locate your listener.ora (typically located in the $ORACLE_HOME/network/admin)

   c) Add a SID_LIST_LISTENER entry for your ASM instance (see example below) 

EXAMPLE 
SID_LIST_LISTENER =
    (SID_LIST =
      (SID_DESC =
         (SID_NAME = +ASM)
         (ORACLE_HOME = c:\oracle\app\product\11.1.0\db_1)
      )
   )

   d) Stop the listener

lsnrctl stop

   e) restart the listener

lsnrctl start


2) Edit the tnsnames.ora on the client 

   a) Logon to the client machine that will be used to connect to the ASM instance 
          NOTE: the client machine can also be the ASM/Database server (ie for DBCONTROL)

   b) Locate your tnsnames.ora (typically in the $ORACLE_HOME/network/admin)
   c) Add an entry (tnsalias) for your ASM instance (see example) 

EXAMPLE
ASM =
   (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = kbcook-1)(PORT = 1521))
      (CONNECT_DATA =
         (SERVER = DEDICATED)
         (SID_NAME = +ASM)
         (UR=A)
      )
   )

3) Setup your remote login password for your ASM instance on the ASM server

   a) Logon to the ASM/Database server

   b) Locate the parameter file for your ASM instance (typically $ORACLE_HOME/dbs/init+ASM.ora [unix] or $ORACLE_HOME/dbs/init+ASM.ora [windows] ) 

   c) Edit the parameter file and add 

         remote_login_passwordfile = exclusive ... for stand alone ASM setups
         remote_login_passwordfile = shared ... for ASM setups that also use Real Application Cluster (RAC)
  
   d) Save the file
   NOTE: It may be required that an PFILE be created from an SPFILE in order to be able to edit the file properly ... once the line have been added ... the process can be reversed 

                 For more details Note 249664.1 Pfile vs SPfile ... may be used 

4) Set your SYS password using ORAPWD for the ASM instance

   a) Logon to the ASM/Database server 

   b) Locate your orapw&lt;sid&gt; file for your ASM instance (typically $ORACLE_HOME/dbs/orapw+ASM)

   c) Rename the file to orapw&lt;sid&gt;.old 
  
   d) Run orapwd to reset the password (see example below) 

EXAMPLE
mv &quot;orapw+ASM&quot; &quot;orapw+ASM.old&quot;
orapwd file=orapw+ASM password=kbcook

5) Use the properly formatted connect string for your tool 

Connnect to the ASM instance using the password (#4 above) and the tnsalias (#2 above)

EXAMPLES
C:\oracle\app\product\11.1.0\db_1\BIN\SQLPLUS.EXE &quot;sys/kbcook@asm as sysdba&quot;

&lt;OR&gt;

sqlplus &quot;sys/kbcook@asm as sysdba&quot;

&lt;OR&gt;

sqlplus &quot;sys@asm as sysdba&quot; ... then supply the password when prompted 
</pre>
]]></content:encoded>
	</item>
</channel>
</rss>
