How do I…Create Windows NT and Oracle client services for the new instance?

Problem

I have created a new Oracle instance under Microsoft Windows NT, but I get an ORA-12547 or ORA-12545 error when I try to connect to it from Server Manager or SQL*Plus, respectively. How do I configure the instance so I can use these tools?

Technique

Under Windows NT, all Oracle8 database instances have a corresponding Windows NT service. A Windows NT service is an executable process. Any and all user connections to an Oracle8 instance require a running NT service specific to the instance. The Oracle8 Instance Manager creates this service during instance creation (see How-To 1.1 for an explanation of the Oracle8 Instance Manager). You can change the characteristics of the NT service from the Windows NT Control Panel, regardless of the options you specified during instance creation. Use the Windows NT Control Panel to start and configure the NT service associated with any Oracle instance. Use the Oracle Network Configuration Wizard to create an Oracle client service for SQL*Plus to use to connect to the instance.

Steps

1. Select the Control Panel menu option from the Settings section of the Windows NT Start menu. Enter the NT Service Manager by double-clicking Services. The Windows NT Service Manager, shown in Figure 1.3, will appear.

2. Click once on the Oracle service corresponding to the instance you want to access. If the status of the service is Stopped, click the Start button to start the service.

3. If the Startup column for the service indicates Manual and you want the service to start every time the computer starts, double-click the line describing the service or single-click the Startup button. Now click the radio button to the left of the word Automatic.

4. Click OK and Close to exit the NT services manager.

5. Select the Programs menu from the Windows NT Start menu, select the Oracle for Windows NT menu, and then select the Oracle Network Configuration Wizard.

6. Click once on the Create New Service button, and supply the database SID and a service name of your choosing in the appropriate fields. Click once on the Next button. You will avoid confusion later if you configure the service so that the values of the database SID and the service name are identical. The Create New Service screen appears in Figure 1.4

7. Select the protocol the client will use to communicate with the server and specify any protocol specific information required in the following dialog box. If you specified Bequeath (for a local database), no additional information is necessary.

How It Works

Steps 1 through 3 start the NT service associated with the Oracle instance and instruct Windows NT to start the service whenever the server starts up, so that the Server Manager interface will be available for the associated database instance. Steps 5 through 7 make an entry in the TNSNAMES.ORA file specifying the connection information necessary for communication via the SQL*Plus and Enterprise Manager interfaces. The Network Configuration Wizard protects users and DBAs from the esoteric syntax of the TNSNAMES.ORA file.

Comments

At some sites, it might be useful to start the NT service corresponding to the database instance even if the instance itself does not start every time the machine starts up. Otherwise, starting the instance will necessitate an extra step to start the associated NT service. The NT Instance Manager enables DBAs to modify the startup mode of the database and the associated NT service together. It does not, however, enable you to specify one startup mode for the instance and a different mode for the NT service.