Skip to content

Support for Apple M1 #688

Closed
Closed

Description

@leinad1

Is there a way to support Apple M1?
I am on Monterey 12.0.1.

I am facing the following error:
ImportError: dlopen(/opt/homebrew/Caskroom/miniforge/base/lib/python3.9/site-packages/ibm_db.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace '_SQLAllocHandle'

Activity

  1. amukherjee28 commented on Nov 8, 2021

    @amukherjee28
    Member

    Could you try installing the ibm_db driver using the --no-cache-dir option.

    pip install ibm_db --no-cache-dir and let me know if that works.

    Unfortunately we dont have a test system with the above OS, so cannot check this for now.

  2. leinad1 commented on Nov 9, 2021

    @leinad1
    Author

    uninstalled and installed with option above, but no change.
    In the meantime, I found out, that it is not working only with homebrewed python installation.
    "Normal" python installation does work: /usr/local/bin/python3

  3. klaasbrant commented on Nov 26, 2021

    @klaasbrant

    The issue is that is no Db2 CLI client for ARM processors. That has to be fixed before the python client can be fixed (if it needs fixing at all).

  4. bimalkjha commented on Nov 26, 2021

    @bimalkjha
    Member

    @klaasbrant The newer clidriver does work on M1 chip processor. Few user has tested. If you see above post by leinad1, problem is only with homebrewed python. Thanks.

  5. klaasbrant commented on Nov 26, 2021

    @klaasbrant

    @bimalkjha are you sure? When you look at the files in https://public.dhe.ibm.com/ibmdl/export/pub/software/data/db2/drivers/odbc_cli/ there is only 1 macos file which is x86
    I just tried to install on rasberry pi (also ARM like Mac M1) and it fails because it cannot resolve the platform

  6. bimalkjha commented on Nov 26, 2021

    @bimalkjha
    Member

    @klaasbrant If you see this comment by one of the user of M1 Chip system, db2level and db2cli commands works fine on Mac M1 system. So, I updated here. One other github user christo-ph also confirmed it.
    I am not sure about Rasberry pi or Alpine Linux yet, but it seems the macos64_clidriver.tar.gz works for both x64 and arm64 processor. I am yet to get access of an M1 system, so I have not tested it. Once, I'll verify then will update here. Thanks.

  7. vinaydeep0711 commented on Nov 17, 2022

    @vinaydeep0711

    I am trying to install odbc , pymysql and mysql connector on the my mac os M1 air machine and getting the same error
    symbol not found in flat namespace '_SQLAllocHandle-
    return import("pyodbc")
    ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages/pyodbc.cpython-310-darwin.so, 0x0002): symbol not found in flat namespace '_SQLAllocHandle'

    Can someone help me to resolve this.

  8. bimalkjha commented on Nov 17, 2022

    @bimalkjha
    Member

    @vinaydeep0711 This forum is only for issues related to ibm_db and not for pyodbc. Please post your problem in different forum. Thanks.

  9. bimalkjha commented on Dec 30, 2024

    @bimalkjha
    Member

    @leinad1 @klaasbrant We have released ibm_db v3.2.5 with native installation support for MacOS Silicon Chip system and no need to use the emulated environment with x86_64 python on M1 chip system. Please install latest version of ibm_db and verify. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions