M1 맥북 오라클 - M1 maegbug olakeul

M1 맥북 오라클 - M1 maegbug olakeul

아직 안 함

M1 맥북 오라클 - M1 maegbug olakeul
Oracle Database

미지원: Rosetta 2

Apple Silicon이 Oracle Database 을 지원하나요?, Rosetta 2 으로 Oracle Database 을 지원함, Oracle Database on M1 Macbook Air, Oracle Database on M1 Macbook Pro, Oracle Database on M1 Mac Mini, Oracle Database on M1 iMac

자세한 사항

As Apple has released the M1 chip with a different architecture than the previous generation, it resulted in various apps including Oracle Instant Client not being able to work normally on Apple silicon. However, there’s Rosetta 2 — “A translation process that allows users to run apps that contain x86–64 instructions on Apple silicon” says by Apple. So, In this article I’m going to share my sample steps for setting up Oracle Database Instant Client in Apple Silicon M1.

If you are facing an issue related to installation of Oracle Database Instant Client on M1 something like “DPI-1047: Cannot locate a 64-bit Oracle Client library: mach-o, but wrong architecture”, you may consider the following solution as an alternative way to install Oracle Instant Client.

Steps to Install Oracle Instant Client on Apple Silicon

Step 1: install rosetta2

Use below command to install rosetta2:

/usr/sbin/softwareupdate — install-rosetta

Note: The above command will launch the Rosetta installer. Then, you just need to agree to its license agreement. However, you can skip the license agreement by providing this additional flag as below:

/usr/sbin/softwareupdate –install-rosetta –agree-to-license

Then, I duplicate the terminal and set default to “open using rosetta” and will use this terminal to install other items in the next steps.

Step 2: install brew

Use below command to install brew:

arch -x86_64 /bin/bash -c “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

Note: ensure that the library should located at (/usr/local/Homebrew/bin/brew)

Step 3: install python

Use below command to install python:

arch -x86_64 brew install python

Step 4: install pip and dependencies library

Use below command to install pip:

Note: make sure that the libraries are installed with -x86_64.

curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py

python get-pip.py

Step 5: download instant client

Link: https://www.oracle.com/database/technologies/instant-client/macos-intel-x86-downloads.html

> Move ${instantclient_folder_name} folder (group Basic Package, SQL*Plus Package, SDK Package as 1 folder) after unzip to /Users/[your user path]

> Create a folder ~/lib

> Create a symbolic link

- ln -s /Users/[your user path]/${instantclient_folder_name}/libclntsh.dylib ~/lib/

step 6: setup export path in .zshrc file

> sudo vi .zshrc

> Enter your mac password

> To insert text to file press -> i

Insert below paths to the file:

export PATH=/Users/[your user path]/instantclient:$PATH

export ORACLE_HOME=/Users/[your user path]/instantclient

export DYLD_LIBRARY_PATH=/Users/[your user path]/instantclient

export OCI_LIB_DIR=/Users/[your user path]/instantclient

export OCI_INC_DIR=/Users/[your user path]/instantclient/sdk/include

> Save and quit by command -> :wq

> source .zshrc

Step 7: Install cx_Oracle from PyPi

> python -m pip install cx_Oracle — upgrade — user

Note: The — user is optional and may be useful, if you don’t have permission to write to system directories

Step 8: try running SQLPlus

References:

https://stackoverflow.com/questions/64963370/error-cannot-install-in-homebrew-on-arm-processor-in-intel-default-prefix-usr

https://docs.brew.sh/Installation

M1 맥북 오라클 - M1 maegbug olakeul

Hey guys, Recently I bought a M1 pro MacBook pro and I am trying to install oracle db on it but clearly there is no m1 arm updates for installation other than by using VM. If anyone has a M1 pro MacBook Pro (m1 Mac) and have installed oracle db (any version) on VM or natively then can you please share the steps ??

M1 맥북 오라클 - M1 maegbug olakeul

level 1

It won't work. There is no version of Oracle Database that runs on Arm yet. And there's too much assembler in code for it to successfully run under emulation like Rosetta. You may be able to get bits of it to work, but it won't be fast or reliable, I'm afraid.

level 1

This doesn't answer the question directly, but... A solution worth considering for M1 Mac users is using the Oracle-cloud database. It's "always free" so it's not a trial that expires after a certain time period. It's essentially having your own oracle database in the cloud that you can connect to natively from your own machine

https://www.oracle.com/cloud/free/

level 1

You can install oracle db on apple silicon based Mac. Check out this video. Oracle Database on Apple Silicon Mac (M1) https://youtu.be/GJyCY3F0mmI

level 2

Thanks for the input buddy 👍🏻 but time was a constraint for me so bought a windows laptop too. If any other leads then do mention in the post below.

level 1

Do you found solution for this?

level 1

I am also facing issue..Unable to install oracle client ON M1 PRO MAC..any suggestion plz

level 2

That doesn't work unfortunately. Those images are only supported on linux.

Might be possible to wrangle something using docker on top of Multipass, https://multipass.run/ which now supports M1. I might have a play with it if I get bored (I'm a DBA and I have a macbook air...)