Get the App
SLTechnology News&Howtos  ›  Database  › 

Oracle dynamic registration and static registration

Shulou Source: shulou.com Published: 2022-06-01 11:04:46 10月02日 Update

Dynamic registration: after the instance is started, pmon automatically registers the service name with the listener every minute, or manually registers the alter system register; system. By default, there is a listener; that does not need a listener.ora file to start listening. The instance must be started under mount to start listening.

Practice: add dynamic registration of port 1522

Add listener.ora content as shown below

Add tnsnames.ora content as shown below

Alter system set local_listener='jw'

Start listening lsnrctl start niceman

Execute sqlplus / as sysdba

Alter system register

Static registration: listener.ora must be set for static registration, but the instance does not need to be started. After starting static listening, you can start the database remotely by static listening.

Practical static registration:

Clear the content that was previously registered dynamically

Alter system set local_listener=''

Set the static registration content as shown in the following figure. Note that this configuration is not overridden, otherwise an error will be reported. The author has been studying this problem for several hours before discovering this pit.

Start static registration listening, and if it is found that the status is UNKNOWN, it is static registration.

In this case, the instance is shutdown, but it does not affect the startup of static registration listening.

Demonstrate static registration of remote startup database

The static registration port demonstrated just now is 1523X Win7 computer client configuration.

Found that the database could be started successfully.

Note that tnsping can only test whether the tnsnames configuration is normal and whether the listening is smooth, but it is not necessarily possible to connect to the database through tnsping. If the database does not start the instance, tnspingtong cannot connect to the database.

Simple connection method:

Sqlplus user / password @ IP address: Port number / service name

Tags: Static data database instance content dynamic configuration actual combat port service demonstration success smooth author listener slogan can pass address client client Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker NVidia OPPO Reno Shulou Tech Info macOS