11.1 Net8 General Problems

Team-Fly    

 
Oracle Net8 Configuration and Troubleshooting
By Jonathan  Gennick , Hugo Toledo
Table of Contents
Chapter 11.  Solutions to Common Problems


This section describes common Net8 problems that aren't related to a specific component, such as Connection Manager or Oracle Names .

11.1.1 Net8 Cannot Resolve a Service Name

11.1.1.1 Symptom

You try to connect to a database instance and the connection fails with the following message:

 ORA-12154: TNS:could not resolve service name 
11.1.1.2 Possible solution

This is probably the most commonly experienced Net8 problem. The error message tells you that Net8 was unable to look up a definition for the net service name that you provided. The solution is to follow what we refer to as the connectivity path until you find the source of the problem. Refer to Chapter 10, for an extensive discussion of this issue.

11.1.2 Windows Prompts to Make a Dial-up Connection

11.1.2.1 Symptom

You attempt to make a Net8 connection from a Windows client, and a Dial-up Connection dialog opens and prompts you to make a dial-up connection to the Internet.

11.1.2.2 Possible solution

This may occur if you have your Internet Properties configured for autodial. To check this, perform the following steps:

  1. Right-click on Internet Explorer and select Properties from the fly-out menu. This should open the Internet Properties window.

  2. Click the Connections tab.

  3. Look for three radio buttons in the middle of the screen that control whether or not a dial-up connection is attempted automatically.

  4. Choose "Never dial a connection" if you do not want Windows to prompt you to make a dial-up connection when you use Net8.

Another possible cause for this problem is related to the use of LDAP for name resolution. If your NAMES.DIRECTORY_PATH setting ( sqlnet.ora ) includes LDAP, and your DIRECTORY_SERVERS setting ( ldap.ora ) points to an LDAP directory server that can't be contacted, that may trigger Windows to attempt a dial-up networking connection.

11.1.3 Your Firewall Blocks Redirects

11.1.3.1 Symptom

You are trying to make Net8 connections through a firewall. When the Net8 listener redirects your connection to a dedicated server process or to an MTS dispatcher, a new port number is assigned. Your firewall blocks this port number, so connections cannot be made.

11.1.3.2 Possible solution

This is a common problem, and most commercial firewall products have a built-in capability to deal with Net8 connections. You should consult your firewall documentation for information on enabling your firewall's Net8 support.

If your firewall does not support Net8 directly, you may be able to work around the problem using Connection Manager or multi-threaded server. Connection Manager can be placed inside the firewall, and connections can be routed through it. The redirect happens between Connection Manager and the listener, and since both are inside the firewall, it no longer presents a problem. The client outside the firewall communicates with Connection Manager, and that port number never changes. Chapter 9, describes this solution in more detail.

With multi-threaded server, you can configure each dispatcher with a fixed protocol address, which includes a port number. You can then open up those ports in your firewall. Incoming connections are handed off to a dispatcher. Since the dispatcher port numbers are known, and are open in the firewall, connections should be successful. This solution is described in Chapter 5, and only works for MTS connections.

11.1.4 Net8 Assistant Can't Find Your Configuration Files

11.1.4.1 Symptom

You run Net8 Assistant, and instead of getting the main window from which you can edit your current settings, you get an Open Network Configuration dialog box such as the one shown in Figure 11.1.

Figure 11.1. Net8 Assistant's Open Network Configuration dialog
figs/n8c_1101.gif
11.1.4.2 Possible solution

You may have a TNS_ADMIN environment variable or a TNS_ADMIN registry variable (Windows) that points to an invalid location. By default, no such variable exists, and Net8 Assistant looks in $ORACLE_HOME /network /admin for configuration files such as sqlnet.ora and tnsnames.ora . If you've set TNS_ADMIN and it points to a location that doesn't exist, then Net8 Assistant prompts you to choose a location using the Open Network Configuration dialog.

11.1.5 You Get an ORA-12545 Error While Trying to Connect

11.1.5.1 Symptom

You try to connect to a database service and the connect attempt fails with the following message:

 ORA-12545: Connect failed because target host or object does not exist 

You've checked the hostname in your tnsnames.ora file, and it is correct.

11.1.5.2 Possible solution

This problem can occur when either prespawned dedicated server processes or MTS are being used. When the listener redirects an incoming connection to a prespawned server process or to an MTS dispatcher, it does so by building a protocol address and sending that address back to the client to use. That protocol address looks just like the ones you see in tnsnames.ora , and one of the components is a hostname. The problem occurs when the server uses a hostname that the client does not recognize. This could be because the server is misconfigured, or it could be because the client does not know about the host on which a dispatcher process is running. The case study at the end of Chapter 10 focuses on this very issue. By reading that case study, you'll learn how to detect the problem, and you'll see one possible cause of the problem.

11.1.6 You Don't Get a Trace File When You Ask for One

11.1.6.1 Symptom

You enable tracing for Net8 or for a Net8 component, but no trace file is generated.

11.1.6.2 Possible solution

This problem occurs on Windows systems when you attempt to write a trace file to the root directory of a drive ( C:\ for example). Check your trace file location, and make sure that it is pointing to a subdirectory at least one level underneath the root.

11.1.7 You Want to Change the Session Data Unit Size

11.1.7.1 Symptom

You want to tune the amount of data in each packet that Net8 transfers between client and server.

11.1.7.2 Possible solution

You can use the SDU and TDU parameters to tune the size of the session data unit (SDU) and the transport data unit (TDU). The SDU refers to the amount of data in one Net8 packet, and the TDU refers to the packet size used by the underlying transport protocol (TCP/IP, for example). The SDU and TDU should usually be set to the same value.

The SDU and TDU parameters can appear in three places:

  • In the definition of a net service name ( tnsnames.ora )

  • In the SID_LIST for a listener ( listener.ora )

  • In the definition of a dispatcher (MTS_DISPATCHERS)

When a Net8 connection is made, Net8 negotiates the actual SDU and TDU sizes based on the smallest value involved. For example, if the client requests a size of 8K but the listener requests 4K, then 4K will be used. The following example shows a tnsnames.ora entry and a listener SID_LIST entry that will result in an 8K session (and transport) data unit size:

 #in tnsnames.ora: PROD.GENNICK.ORG =   (DESCRIPTION =     (ADDRESS_LIST =       (ADDRESS = (PROTOCOL = TCP)(HOST = donna.gennick.org)(PORT = 1523))     )     (SDU = 8192)     (TDU = 8192)     (CONNECT_DATA =       (SID_NAME = prod)       (SRVR = SHARED)     )   ) #in listener.ora: SID_LIST_LISTENER =   (SID_LIST =     (SID_DESC =       (SDU = 8192)       (TDU = 8192)       (GLOBAL_DBNAME = prod.gennick.org)       (SID_NAME = prod)     )   ) 

Since a multi-threaded server connection is being made in this example (by virtue of SRVR = SHARED), the MTS_DISPATCHERS parameter needs to also include the SDU and TDU parameters:

 MTS_DISPATCHERS="(SDU=8192)(TDU=8192)(PROTOCOL=TCP)(DISPATCHERS=1) \ (POOL=YES)(MULTIPLEX=NO)(SESSIONS=2)(LISTENER=(ADDRESS_LIST= \ (ADDRESS=(PROTOCOL=TCP)(PORT=1523)(HOST=DONNA.GENNICK.ORG))))" 

The default size for SDU and TDU is generally 2K. Prior to the release of Oracle 7.3, 2K was the maximum value for these parameters. From Release 8.0 upwards, the maximum size is 32K. For MTS, these parameters are only tunable beginning with Release 7.3.3.

11.1.8 You Get an ORA-12538 Error When Trying to Connect

11.1.8.1 Symptom

You try to connect to a database service, and the connection attempt fails with the following error message:

 TNS-12538: TNS:no such protocol adapter 
11.1.8.2 Possible solution

Protocol adapters sit between Net8 and the underlying protocol being used. If you use SPX, then you need a protocol to convert Net8 calls into SPX calls, and vice versa. Prior to Oracle8, protocol adapters were separately installable componentsyou could easily add one if it was missing. Beginning with the release of Oracle8, protocol adapters are installed automatically. When you put Oracle on a machine, the installer detects the available protocols and installs the appropriate adapters.

The problem with having the protocol adapters installed automatically is that if you subsequently install a new networking protocol on your machine, there is no easy way to install the corresponding Net8 adapter to support that protocol. The only solution is to run the Oracle installer, uninstall Net8 and all its components, and then reinstall Net8. On the reinstall, the Oracle installer detects the new protocol that you installed, and it then installs the needed Net8 protocol adapter.

11.1.9 Instance Registers with Wrong Listener

11.1.9.1 Symptom

You have two or more databases and you have created one listener for each database. One or more of the database instances then register with the wrong listener.

11.1.9.2 Possible solution

You may need to use the LOCAL_LISTENER parameter in your instance parameter file. By default, an instance will attempt to register services with the listener monitoring the default address of port 1521. If you have more than one listener, they will each be monitoring different addresses. You can use LOCAL_LISTENER in an instance parameter file to point the instance at the listener of your choice. For example:

 LOCAL_LISTENER="(ADDRESS_LIST= \ (ADDRESS=(PROTOCOL=TCP)(PORT=1523)(HOST=donna.gennick.org)) \ )" 

If you are running MTS, you may want to specify the listener using the MTS_DISPATCHER parameter's LISTENER attribute.

11.1.10 Net Service Name Doesn't Work with Enterprise Manager

11.1.10.1 Symptom

You have defined a net service name in your tnsnames.ora file and you can use it from SQL*Plus, but not from Enterprise Manager.

11.1.10.2 Possible solution

If Enterprise Manager is in its own Oracle Home, then it has its own tnsnames.ora file. You need to define your net service name in both files. Alternatively, you can set the TNS_ADMIN environment variable so that all Oracle Homes use the same set of files. See Appendix E, for information on doing that.

This same issue can come up when Oracle Portal (formerly WebDB) is used. Oracle Portal typically gets installed into its own Oracle Home directory.

11.1.11 Net8 Easy Config Complains About Corrupt Files

11.1.11.1 Symptom

You are running a release of Oracle prior to 8.1, and Net8 Easy Config complains that your tnsnames.ora file has been tampered with. There are no problems with the file. You just copied it from another machine where everything works fine.

11.1.11.2 Possible solution

Early versions of Net8 Easy Config tried to guard against manual editing of Net8 configuration files by recording configuration information in two files named sqlnetv2.cfg and sqlnetv2.ini . Manually editing tnsnames.ora would cause it to be out of sync with those other two fileshence the error message. If you copied just tnsnames.ora , it would likely be out of sync with the two sqlnetv2 files on the target machine. To prevent errors, it's necessary to copy all three files.

Beginning with Oracle8 i , Oracle greatly improved the Net8 Easy Config utility, and the sqlnetv2.cfg and sqlnetv2.ini files are no longer an issue.

11.1.12 You Have an Unwanted Listener Service in Windows NT

11.1.12.1 Symptom

You open the Services control panel and you see a listener service that was created by accident . This can be the result of issuing a LSNRCTL START command, and supplying an incorrect listener name by mistake. When you do that, the Listener Control utility automatically creates a new service for whatever name you typed in.

11.1.12.2 Possible solution

See Chapter 4, for information on deleting unwanted listener services from the Windows NT registry.

11.1.13 Developer 2000 Won't Connect to Personal Oracle

11.1.13.1 Symptom

You have installed Personal Oracle, and you need a net service name to use when connecting to your Personal Oracle instance from Developer 2000 or from a similar product.

11.1.13.2 Possible solution

Define a Bequeath (BEQ) connection in your tnsnames.ora file. For example:

 DEV.GENNICK.ORG =    (DESCRIPTION =      (ADDRESS_LIST =        (ADDRESS =          (PROTOCOL = BEQ)         (PROGRAM = oracle80)         (ARGV0 = oracle8ORCL)         (ARGS = '(DESCRIPTION=(LOCAL=YES)(ADDRESS = (PROTOCOL = beq)))')       )     )     (CONNECT_DATA = (SID = ORCL)     )   ) 

Chapter 3, also shows an example of a Bequeath connection. Such a connection is ideal for Personal Oracle, especially under Windows 95 or Windows 98, because no listener is necessary.


Team-Fly    
Top


Oracle Net8 Configuration and Troubleshooting
Oracle Net8 Configuration and Troubleshooting
ISBN: 1565927532
EAN: 2147483647
Year: 2000
Pages: 120

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net