After our Oracle database 12.2 has been created on Windows server, we should open port 1521 on firewall for incoming connections. For Linux, you can refer to : How to Open Ports and Survives from Reboots
Use ⊞ Win + F to search for "Windows Firewall with Advanced Security", then click it.
In "Inbound Rules", we add a new rule.
Please input the port number 1521 for TCP protocol.
Since this is a white rule, please allow incoming connection.
Apply all sources of connections.
Name the inbound rule.
The rule takes effect immediately.
Now the listener is accessible externally. Optionally, if you would like to connect enterprise manager express 12c from outside other than localhost, you should open port 5500 too. The access URL is:
At times, an inconsistent states between Windows Service and SQLPlus that you might have been aware of. I'll talk about it in the post: How to Resolve "Connected to an idle instance" on Windows.