Win7-64-bit oracle client-plsql Connection database

Source: Internet
Author: User
Tags dedicated server

Win7-64 bit install oracle client-plsql Connection database 64-bit win7 flagship Edition sp1 system: 1, installed oracle11gR2 64-bit server version (according to the Neusoft to the method ), you have created instances and databases and created listeners .. In addition, the built-in slq-plus can be logged on (the local machine is used), indicating that the network configurations such as server listening should be correct. Because plsql is 32-bit, it is in Chinese version 9.0. ...... (See the uc browser's favorites page). Directly install the 32-bit client 11gr1zip downloaded from the official website. When installing, only install instantclient (more than 150 MB), for example, installation path D: \ app \ dsd \ win32 \ product \ 11.1.0 \ client_1 remarks: the client connection configuration file tnsnames. ora and oci. dll is in 2 under D: \ app \ dsd \ win32 \ product \ 11.1.0 \ client_1. This step can not be used: plsql option-oracle connection, select the Home Directory of the 32-bit oracle client (that is, the home directory when oracle is installed, for example, D: \ app \ ds D \ win32 \ product \ 11.1.0 \ client_1 ".) And oci Library (oci. dll, which is a call interface of oracle) path, such as: D: \ app \ dsd \ win32 \ product \ 11.1.0 \ client_1 \ oci. dll 3. The system variable in the environment variable is also changed according to the online method: Make sure that the path variable contains D: \ app \ dsd \ win32 \ product \ 11.1.0 \ client_1, this path variable may not be added to the installation path of the oracle 32-bit client. The variable automatically contains the 32-bit path of the oracle client and the 64-bit Server installation path. (Because the server version is installed on the local machine and the client version is installed.) create a new "TNS_ADMIN" variable with the value: D: \ app \ dsd \ win32 \ product \ 11.1.0 \ client_1, this variable must be created. Otherwise, plsql cannot be connected and the same error is reported. Create a new variable named "NLS_LANG" with the value of "SIMPLIFIED CHINESE_CHINA.ZHS16GBK". This variable is created to change the English error reported by plsql logon to a Chinese error. Zhs16gbk is the default data character set when you manually create a database after oracle11g is installed. But at this time, it is still the error "ORA-12154: TNS: unable to resolve the specified connection identifier", the local sqlplus can log on, suspected to be the oracle client tnsnames. ora has a problem. Then, check the listener Configuration File listener on the server. connection string in ora: LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP) (HOST = dsd-PC5) (PORT = 1521) (ADDRESS = (PROTOCOL = IPC) (KEY = EXTPROC1521) it is found that the host is the computer name, as above, is the dsd-pc5, then, the client's oracle client installation path of the configuration file tnsnames. the host in the connection string in ora is the server host name (originally, as follows: DSD = (DESCRIPTION = (AD DRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = dsd-PC5) (PORT = 1521) (CONNECT_DATA = (SERVICE_NAME = lmsdsd) login with plsql, success... In addition, it is strange to change the host name in tnsnames. ora to, and plsql can be connected normally .. Summary: the key to the problem lies in the TNS_ADMIN variable. The path of the TNS_ADMIN variable will lead to the Net Manager under oracle in the Start menu (originally on the server side, instantclient client does not include this) to which the configuration file tnsnames is modified. ora and listener. ora (Listener Configuration File) (the client does not need to listen), and also causes plsql to call the oci. dll, tnsnames. ora is under that path. In addition, the database name entered during plsql login is actually the network service name, that is, the network name configured by Net Manager (the first line of the connection string in tnsnames. ora ). Or is there no Net Manager tool on the client? The key is that the tns_admin variable value must specify a 32-bit oracle client, and the connection string parameter in tnsnames. ora must be set. Of course, the premise is that the server port has been monitored, that is, the listener. ora content on the server must be correct. Note: Net Configuration Assistant is actually a Net Manager with wizard mode. It is also determined by the tns_admin variable which path it modifies tnsnames. ora and listener. "listener Configuration" in ora Net Configuration Assistant affects listener. ora file and create a listener. Its "Local Network Service name configuration" affects tnsnames. ora, in fact, the database server does not need to configure "Local Network Service name configuration", unless you want to use plsql on the server's local computer, but directly change the tnsnames on the server. ora is more convenient? In addition, as mentioned above, a 32-bit oracle client must be installed on a 64-bit server, and a 32-bit plsq can only be used (the tns_admin variable must be changed). Note that the oracle server has a listening service, you can see it in the Service Management of the operating system .. If the listening service is stopped and plsq is used on the local machine, a message indicating no listening is displayed. If plsql is used by other hosts on the network, a message indicating connection timeout is displayed. The server listening service is available only after a listener is added (no listening service is available when the oracle11g server is installed), that is, the Net Configuration Assistant can add a listener once (the network service name does not need to be added) after the listening service is added, no listener is generated under E: \ app \ dsd64 \ product \ 11.2.0 \ dbhome_1 \ NETWORK \ ADMIN. ora configuration file? The listener in the tns_admin variable path is generated under D: \ app \ dsd \ win32 \ product \ 11.1.0 \ client_1. if ora is deleted, the listening service cannot be started after it is stopped. If multiple identical connection strings exist in tnsnames. ora, multiple optional Network Service names are available at plsql startup. Plsql calls tnsnames in the specified path of the tns_admin variable. ora and oci. dll such as tnsnames. ora has the following two connection strings. dsd1 and dsd2 are available when plsql logs in. DSD1 = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = dsd-PC5) (PORT = 1521) (CONNECT_DATA = (SERVICE_NAME = lmsdsd) DSD2 = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = dsd-PC5) (PORT = 1521) (CONNECT_DATA = (SERVICE_NAME = lmsdsd) the Virtual Machine-32-bit xp proves that you only need to install the 11g instantclient component of the oracle client, and then set the tns_admin variable. plsql can read tnsnames. ora and call oci. when dll is created in DBCA (manual database creation wizard), a prompt is displayed, asking us to select a connection class. Type. There are two types: Dedicated server and Shared server (Dedicated mode and Shared mode. if SERVER = DEDICATED is declared in the connection string in ora, the DEDICATED mode (exclusive mode) is used to connect to the SERVER, for example, LOAD_BALANCE = yes in the connection string ), that is, load balancing, rac: Oracle RAC cluster, RAC, full name real application clusters, the system will prompt whether to install the "Single Instance" or rac: real application clusters oracle base directory, for example, e: \ app \ dsd64 directory of all oracle products, such as: e: \ app \ dsd64 \ product \ 11.2.0 \ dbhome_1 indicates the location of the oracle software file. Install oracle Database Management System Server Edition. During installation, only the database software is installed. After the installation is successful, there is no listening service. (The service list of the operating system .) When no listening is configured on the server, no configuration file is available in E: \ app \ dsd64 \ product \ 11.2.0 \ dbhome_1 \ NETWORK \ ADMIN.

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: 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.