Skip to content

Instantly share code, notes, and snippets.

@dungsaga
Last active October 5, 2023 16:19
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dungsaga/41c342b3c515fb578672c07f62e0c038 to your computer and use it in GitHub Desktop.
Save dungsaga/41c342b3c515fb578672c07f62e0c038 to your computer and use it in GitHub Desktop.
install Oracle XE 18x under WSL2

install Oracle XE 18x under WSL2

  • install package is RPM, it's easier to use CentOS 7 or 8 (from CentOS-WSL or wsldl)
  • if you want to use Debian/Ubuntu, you must convert RPM to DEB (but conversion with alien fails under Debian)
  • first, install oracle-database-preinstall-18c-1.0-1.el7.x86_64.rpm
  • second, install oracle-database-xe-18c-1.0-1.x86_64.rpm
  • see https://mikesmithers.wordpress.com/2019/01/03/installing-and-configuring-oracle-18cxe-on-centos/
  • run as root: /etc/init.d/oracle-xe-18c configure
  • it would fail if host IP is auto-generated to be 127.0.1.1
  • you can update the IP in /etc /hosts and try it again
  • after a while, it claimed around 10GB and finished
  • if you run lsnrctl status, you could see it's listening in the full-qualified host name of the VM in WSL
  • if you want to connect from outside, you may update /opt/oracle/product/18c/dbhomeXE/network/admin/listener.ora and set HOST=0.0.0.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment