Oracle Multi-Tenant databases offer the capability to change the port number of the listener, providing greater flexibility in server configuration. By following a few simple steps, you can easily modify the listener's port number to meet your needs.
To begin, log in to the server where the Oracle database is installed with the necessary administrative privileges. Then, follow these steps:
Stop the Listener: Use the command lsnrctl stop to halt the listener.
Edit the Listener Configuration File: Locate the listener.ora file, typically found in the ORACLE_HOME/network/admin directory. Open the file using a text editor and locate the section that defines the listener's configuration.
Modify the Port Number: Look for the line specifying the current port number (defaulted to 1521). Update the port number to your desired value, such as 1522.
Save the Changes and Start the Listener: Save the modified listener.ora file, then initiate the listener using the command lsnrctl start.
Verify the Listener Status: Confirm that the listener has started successfully and is now listening on the new port by executing lsnrctl status. This will display the listener's status, including the new port number.