Install Oracle 18C XE on Windows 10

Sources: https://docs.oracle.com/en/database/oracle/oracle-database/18/xeinw/

Download s/w: 2Gb in size so will take some time depending on download speed, took me 15 minutes

If you don’t already have an account you will need to create one to download the s/w:

https://profile.oracle.com/myprofile/account/create-account.jspx

https://www.oracle.com/technetwork/database/database-technologies/express-edition/downloads/index.html

Will get prompted to allow app to make changes to PC, accept this.

Click Next >:

Read Agreement and select ‘I accept the terms in the license agreement’ if you agree

Then : click Next >:

Choose location to install the s/w, it will default to C: drive and window account in path

I will change to D: as I have more space there on my PC, also update the account path to be ‘oracle’

So: C:apporacleproduct18.0.0 OR D:apporacleproduct18.0.0

Click Next >:

Enter Password to be used for system accounts, as this is just a test install I will choose ‘oracle123’ for this, you can change afterwards if you need: (alter user <username> identified by <password>;)

Click Next >:

Review Summary Screen and click Install:

During the install, Windows defender will alert for java firewall rule, I’ve changed this to

‘Private networks, such as my home or work network’,

I suspect other Virus/Security s/w may also need to have options changed or alert as well.

This will take 30 Minutes

Once install is complete we are presented with final screen:

Note the details for our XE DB:

Port: 1521

Server: localhost

Pluggable DB: XEPDB1

Enterprise Express: https://localhost:5500/em

The container DB will be called XE.

Click Finish, to close installer


Check DB in GUI Enterprise Manager Express

User Name: sys

Password: oracle123

Container name: <Leave blank>

as sysdba: tick box

Click Login



Optional Install SQL Developer

Download SQL Developer so we have a nice front end GUI to do development work using Oracle XE 18c: 400M, 3 mins to download

https://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html

Right click ‘sqldeveloper.exe’ -> create short cut

Then copy/move new shortcut to desktop for easy access.

If prompted you can copy preferences from a previous version of sqldeveloper

Click new connection:

Name: XEPDB1_sys

Username: sys

Password: oracle123

Save Password: check box

Role: SYSDBA

Hostname: localhost

Port: 1521

Service name: xepdb1

Then click test, should see : Status Success

Click Save -> Click Connect

You are now connected to 18c XE db.



Can optionally update tnsnames.ora file in <s/w base dir>/network/admin/tnsnames.ora file to add an connection alias for xepdb1 as below, for me that directory is : D:apporacleproduct18.0.0dbhomeXEnetworkadmin

XEPDB1 =
   (DESCRIPTION =
     (ADDRESS = (PROTOCOL = TCP)(HOST = ACER-HOME-PC)(PORT = 1521))
     (CONNECT_DATA =
       (SERVER = DEDICATED)
       (SERVICE_NAME = XEPDB1)
     )
   )

Optional, Uninstall Oracle 18c XE and delete database (destructive) – CAUTION

(Will need a reboot at the end to complete, but can reboot later if needed)

As per documentation: https://docs.oracle.com/en/database/oracle/oracle-database/18/xeinw/deinstalling-oracle-database-xe.html#GUID-DC36940C-D201-457B-A3D5-D6E2BB800120

Use Add or Remove Programs to deinstall Oracle Database XE:

In the Windows Control Panel, select Add or Remove Programs.

Select Oracle Database 18c Express Edition.

Click Change/Remove or Uninstall.

Follow the prompts to deinstall Oracle Database Express Edition. After few minutes, the window will close and the deinstallation will be complete.

Right Click Oracle Database 18c Express Edition -> Uninstall

Take 30 minutes.

  Click Yes.

Click OK

Once PC has rebooted uninstall is complete.

Uninstall still leaves behind services: (If you don’t run cmd/dos prompt as administrator you will not be able to delete the service)

Run cmd as administrator , cmd -> right click run as adminstrator

sc delete OracleJobSchedulerXE

sc OracleOraDB18Home1MTSRecoveryService

sc delete OracleOraDB18Home1TNSListener
sc delete OracleServiceXE

sc delete OracleVssWriterXE
sc delete OracleOraDB18Home1MTSRecoveryService

Clean up folders left behind, for me it was, check beforehand contents of folder to be sure, before deleting, should just got to recyclebin anyway, if you needed to recover.

Remove: D:apporacleproduct18.0.0