Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-15139

Wrong mysql binary in Mac OS distribution?

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.2.12
    • 10.2(EOL)
    • Configuration
    • Mac OS X 10.13.3 (latest as of bug filing date), on a 2GHz i7 Mac Mini (Macmini5,3) with 16GB RAM, from a 240GB SSD on a case-sensitive APFS file system.

    Description

      I have been having a fit trying to install MariaDB 10.2 on MacOS X, both via the official installer, and via homebrew.

      But I was using an older OS than the one stated on the MariaDB Download page, so I went deeper to try to eliminate variables.

      I re-formatted the disk, clean-installed the latest MacOS (10.13.3), installed the latest Xcode, installed Remote Desktop (this Mac Mini server is normally headless), and downloaded the latest (10.2.12) MariaDB installer. Should be pretty much like your test environment, no?

      The installer said the installation failed, near the very end of the process.

      /var/log/mariadb_installer.log ends with:

      sh: line 1:  1580 Illegal instruction: 4  '/usr/local/mariadb/server/bin/mysql' --no-defaults --help 2>&1 > /dev/null
      FATAL ERROR: Can't execute '/usr/local/mariadb/server/bin/mysql'
      

      Figuring that the physical install succeeded, but initialization scripts failed, I manually followed the instructions in INSTALL_BINARY, and I manually ran "./bin/mysqld_safe --user=mysql &"

      Then I tried to run mysql from the shell, and I get "Illegal Instruction: 4" and a shell return code of 132. (mariadb/server/bin/perror tells me that means: "Old database file," which is strange, coming from a new installation.) I tried running other utilities in /usr/local/mariadb/server/bin, and got a similar message, probably because they are mostly shell script wrappers around mysql.

      I installed the third-party GUI MySQL clients "Sequel Pro" and "Querious." Both of them can connect to the database at 127.0.0.1. I successfully created a simple table in the test database and wrote/read a few records.

      I used the tool "Pacifist" to open the MacOS Installer package and extract just the mysql binary. It has the same cksum(1) as the installed one, and behaves the same.

      SO it appears that there is a bad copy of the client program "mysql" in the official download package for MacOS. At least, I can't think of any other reason there could be an "illegal instruction" exception.

      UPDATE, 2012-02-03: I repeated the test on a different, nearly identical MacMini5,3, with the same result. I will attempt to install the Homebrew bottled (pre-compiled) version next.

      Attachments

        Issue Links

          Activity

            I downloaded the pkg file for MACOS from https://downloads.mariadb.com/MariaDB/mariadb-10.2.12/.

            Then i installed it , worked for me
            Also did once by just unpacking and then ran the binary, that also worked.

            I am using MAC OSX 10.13.2 on a 2.7 GHz Intel Core i5

            varun Varun Gupta (Inactive) added a comment - I downloaded the pkg file for MACOS from https://downloads.mariadb.com/MariaDB/mariadb-10.2.12/ . Then i installed it , worked for me Also did once by just unpacking and then ran the binary, that also worked. I am using MAC OSX 10.13.2 on a 2.7 GHz Intel Core i5
            Bytesmiths Jan Steinman added a comment -

            @Varun Gupta, perhaps that's because you're on an i5?

            Our MacMini5.3 servers have i7 processors.

            I repeated this test on a different, but nearly identical, server, same results. I downloaded a fresh Mac OS .pkg installer file, extracted mysql, and it says "Illegal Instruction: 4" when I run it.

            The first machine has an SSD for the boot drive, whereas the second has a 500GB hard disk. They are both running Mac OS 10.13.3

            Bytesmiths Jan Steinman added a comment - @Varun Gupta, perhaps that's because you're on an i5? Our MacMini5.3 servers have i7 processors. I repeated this test on a different, but nearly identical, server, same results. I downloaded a fresh Mac OS .pkg installer file, extracted mysql, and it says "Illegal Instruction: 4" when I run it. The first machine has an SSD for the boot drive, whereas the second has a 500GB hard disk. They are both running Mac OS 10.13.3

            cvicentiu, svoj, maybe that's something to work out with the community – we don't have the variety of Macs in house, need some kind of a poll, what works when where.

            elenst Elena Stepanova added a comment - cvicentiu , svoj , maybe that's something to work out with the community – we don't have the variety of Macs in house, need some kind of a poll, what works when where.
            Bytesmiths Jan Steinman added a comment - - edited

            @Elena Stepanova, I am willing to do a quick test of new Mac OS binary releases on my five Macs, but none of them are very new.

            In any event, I suggest that the current binary release either be pulled, or at least annotated to not run on my particular combination (MacMini5,3 on Mac OS 10.13.3).

            Bytesmiths Jan Steinman added a comment - - edited @Elena Stepanova, I am willing to do a quick test of new Mac OS binary releases on my five Macs, but none of them are very new. In any event, I suggest that the current binary release either be pulled, or at least annotated to not run on my particular combination (MacMini5,3 on Mac OS 10.13.3).
            alice Alice Sherepa added a comment -

            I installed via homebrew without any problems (installed 10.2.12, upgraded to 10.3.4), but can't install 10.2 from source, I get issues with gnutls like in MDEV-13128. (MacBook Pro 2013, OS X 10.13.3)

            alice Alice Sherepa added a comment - I installed via homebrew without any problems (installed 10.2.12, upgraded to 10.3.4), but can't install 10.2 from source, I get issues with gnutls like in MDEV-13128 . (MacBook Pro 2013, OS X 10.13.3)
            Bytesmiths Jan Steinman added a comment - - edited

            UPDATE: I also installed 10.2.12 via homebrew on the same machine, and the mysql binary client works fine.

            The homebrew version and the official distribution version have different checksums. Since they are both for the 10.2.12 distribution, they should have identical checksums, no? (Yea, I realize different CFLAGS could result in different checksums.)

            Bytesmiths Jan Steinman added a comment - - edited UPDATE: I also installed 10.2.12 via homebrew on the same machine, and the mysql binary client works fine. The homebrew version and the official distribution version have different checksums. Since they are both for the 10.2.12 distribution, they should have identical checksums, no? (Yea, I realize different CFLAGS could result in different checksums.)
            Bytesmiths Jan Steinman added a comment -

            I see the new distro (10.2.13) has no MacOS binary. I was hoping to download it and test it for you.

            Bytesmiths Jan Steinman added a comment - I see the new distro (10.2.13) has no MacOS binary. I was hoping to download it and test it for you.
            cvicentiu Vicențiu Ciorbaru added a comment - - edited

            We now have OS X PKGs built for 10.5. This task will probably be closed once we have tested those properly.

            See MDBF-48 for more details.

            cvicentiu Vicențiu Ciorbaru added a comment - - edited We now have OS X PKGs built for 10.5. This task will probably be closed once we have tested those properly. See MDBF-48 for more details.

            People

              vladbogo Vlad Bogolin
              Bytesmiths Jan Steinman
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.