How to pack the application and Oracle client

zhaozj2021-02-16  54

How to pack the application and Oracle client

Author: Jay Bi photo

When we are doing programs, we often need to install Oracle client. If the customer terminal is very much, this will be a very troublesome work. On the one hand, we have to arrange our app, on the other hand to install Racle The client, but also to the Oracle client NET Easy configuration, it is really incapable.

To this end, I have been studying for a long time. Now I can pack the Oracle client and the app, but also use the program to configure Net Easy. I have two younger brother before two days asked how to pack the client to pack and configure the program. Net Easy's question, I am here today.

Due to time problems, I can only talk about the client package today. Another question I will tell you next.

1. The question you want to know:

A. What files to pack.

B, how to modify the registry.

C, how to set the environment variable.

D, which tools are packaged.

2, package the file to use:

Let's first find a machine with Oracle and package the following files. In order to ensure that Oracle can access it normally, we need to keep the original directory structure unchanged.

A, $ Oracle_Home / BIN All DLL, Imp.exe, Exp.exe, Sqlplus.exe, Sqlplusw.exe. ($ Oracle_home refers to Oracle's home directory, such as D: / Oracle / ORA8i).

B, $ 3 directory under the Oracle_Home / NetWork directory: admin, MESG, TNSAPI, package all them.

C, $ Oracle_Home / Ocommon / NLS directory.

D, $ Oracle_Home / ORACORE / MESG directory.

E, two directories under $ oracle_home / sqlplus: admin, mesg.

3, how to modify the registry:

For trouble, we can move the Oracle information in the registry of the Oracle machine. All photo.

4, how to set environment variables:

Set an environment variable, we have to add $ Oracle_home / bin in front of Path;

5. What packages are used:

My personal favorite tool is WISEINSTALLER. Its function is very powerful. It can import the entire file directory (I feel better than install shilled), import the registry, you can set the environment variable, and set NT service, etc. (I am good Like it gives it to it).

We can use it now to do our client.

The first step, first introduced all of these file directories to our installation project.

Step 2, find the setup registry option, import all the registry values ​​under the registry hkey_local_machine / software / oracle.

In the third step, find the environment variable setting option, add $ oracle_home / bin there. $ Oracle_home here is replaced by .

Do this, compile, release, ok.

6. How to modify NET Easy with manual.

Now suppose we have finished this installation package, and install it on our computer, then, on the start menu is no Oracle option, how to set up Oracle Net Easy?

We can do this now:

Open our Oracle client installation directory, find the TNSNames.oran file under the network / admin subdirectory, and then edit it directly.

For example, we now want to configure a service name called NTSERVER, we can write: NTServer =

(Description =

(Address_list =

(Address = (protocol = tcp) (Host = machine name) (port = port number))

)

(Connect_data =

(Service_name = Global Database Name)

)

)

Then, add it directly to the back of the TNSNames.oran.

If the NTSERVER is already existing, we can directly modify its machine name.

The port number and the global database name are OK.

转载请注明原文地址:https://www.9cbs.com/read-19551.html

New Post(0)