Opinions, Expertise, Passion.

Information in black and white, and sometimes some color.

Nov
30

MySQL under Mac OS/X 10.5

Link to this post

Time to install MySQL on my new MacBook.

$ cd /opt
$ wget http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-5.0.45-osx10.4-i686.tar.gz/from/http://mysql.mirrors.hoobly.com/
$ tar xvfz mysql-5.0.45-osx10.4-i686.tar.gz
$ cd mysql-5.0.45-ox10.4-i686
$ scripts/mysql_install_db
Installing MySQL system tables...
071129 22:10:48 [Warning] Setting lower_case_table_names=2 because file system for /opt/mysql-5.0.45-osx10.4-i686/data/ is case insensitive
OK
Filling help tables…
071129 22:10:48 [Warning] Setting lower_case_table_names=2 because file system for /opt/mysql-5.0.45-osx10.4-i686/data/ is case insensitive
OK

bin/mysqld_safe &
[1] 239
macbook:mysql-5.0.45-osx10.4-i686 rbradfor$ chown: /opt/mysql-5.0.45-osx10.4-i686/data/macbook.err: Operation not permitted
Starting mysqld daemon with databases from /opt/mysql-5.0.45-osx10.4-i686/data

$ bin/mysqladmin -uroot password ’sakila’
$ bin/mysql -uroot -psakila -e “SELECT VERSION()”
$ bin/mysqladmin -uroot -psakila shutdown

It was interesting that these normal steps under Linux provided two errors not normally seen.

1. Setting lower_case_table_names=2 because file system for /opt/mysql-5.0.45-osx10.4-i686/data/ is case insensitive

2. chown: /opt/mysql-5.0.45-osx10.4-i686/data/macbook.err: Operation not permitted

The first is interesting, is Mac like Windows in that sense? I’ll need to check that out.
The second occurs every time I start MySQL which is also intriguing, but for now doesn’t affect MySQL operation. It’s interesting that the permissions of the error file is the same as the user running it, so go figure.

Posted under Apple, Databases, MacBook, MySQL, Professional on 30 Nov 2007

4 Comments »

  1. Yep, the Mac OS X filesystem (HFS+) Is case preserving, but case insensitive - causes a few funny little gotchas on the unix side every now and again.

    Linc

    Comment by Lincoln Stoll — November 30, 2007 @ 2:42 pm

  2. Actually, a Mac OS X disk can be formatted as HFS+ with or without case sensitivity (case insensitive is the default) as well as UFS, and hopefully soon (please Steve) ZFS. Apple generally recommends the default though.

    As for the chown error - are you starting mysqld as root?

    Comment by Xander — November 30, 2007 @ 3:21 pm

  3. HFS+ is case-insensitive by default. But do NOT be tempted to reformat your macbook (or at least your boot drive) to be case-sensitive. OS X works fine, but many apps blow up. They try to load shared libraries (components) with wrong case names, etc. It’s a big mess.

    The chown is probably not run as root.

    Finally, you’re now running a 32-bit binary on a 64-bit box. Not optimal. MySQL does not provide 64-bit Intel binaries for OS X. I was able to build a 64-bit version, so it’s just a build/packaging thing and not a technical problem.

    Comment by Arjen Lentz — December 3, 2007 @ 7:31 am

  4. How is MySQL running on your MacBook? The MySQL forums indicate that Leopard & MySQL don’t work well together. Your PlanetMySQL post was the only promising resource I could find.

    Comment by Eric — January 15, 2008 @ 4:07 pm

RSS feed for comments on this post.

Leave a comment

Home
Professional Blog RSS Feed of Professional Blog
Consulting
Presentations
About Ronald
Related Links
Contact Ronald
  • « Oct spinner iCalendar Dec »
    November 2007
    M T W T F S S
     1234
    567891011
    12131415161718
    19202122232425
    2627282930EC
  • Categories:
    • Professional
      • 42SQL
      • Apple
        • iPhone
        • MacBook
        • OS/X
      • Clever Design
      • Cloud Computing
        • 10gen
        • AppNexus
        • Kaavo
        • Kloudshare
      • Databases
        • Drizzle
        • Ingres
        • MySQL
          • Compiling
          • GUI Products
          • MySQL Events
            • mysqlcamp01
            • mysqlcamp02
          • MySQL Proxy
          • MySQL User Conferences
            • mysqluc06
            • mysqluc07
            • mysqluc08
          • Storage Engines
            • Non Transactional
              • Infobright
              • KickFire
              • Maria
              • Nitro
            • Transactional
              • Blob Streaming
              • Falcon
              • InnoDB
              • PBXT
              • Solid
        • Oracle
      • Extreme Programming (XP)
      • General
      • Java
        • Tomcat
      • Linux
        • One Liners
      • Microsoft
      • Open Source
        • Buildbot
        • Ubuntu
        • UltimateLAMP
        • Virtual Box
      • OSCON 2008
      • Packet General
      • PrimeBase Technologies
      • Solid State Drives
      • Sun
      • The Daily WTF
      • Web 2.0 NY
      • Windoze
      • Yahoo
    • Web
      • Google
        • App Engine
        • Summer of Code
      • SEO
        • Brand Identity
      • Web Development
        • Amazon
          • EC2
          • S3
          • SimpleDB
        • CSS
        • HTML
        • PHP
        • Web 2.0
      • Web Sites
        • Application Software
        • Content
        • Cool Tools
        • Linux Stuff
        • MySQL Related
        • Show Your Stuff
        • Twitter
        • Unype
      • WordPress
  • Pages:
    • Best Of PlanetMySQL Articles
    • Interesting Articles
    • MediaWiki Restyling (1)

  • Archives:
    • November 2008
    • October 2008
    • September 2008
    • August 2008
    • July 2008
    • June 2008
    • May 2008
    • April 2008
    • March 2008
    • February 2008
    • January 2008
    • December 2007
    • November 2007
    • October 2007
    • September 2007
    • August 2007
    • July 2007
    • June 2007
    • May 2007
    • April 2007
    • March 2007
    • February 2007
    • January 2007
    • December 2006
    • November 2006
    • October 2006
    • September 2006
    • August 2006
    • July 2006
    • June 2006
    • May 2006
    • April 2006
    • March 2006
    • February 2006
    • January 2006
    • December 2005
    • November 2005
    • October 2005
    • September 2005
    • July 2005
    • June 2005
    • February 2005
    • October 2004
    • September 2004
    • July 2004
    • June 2004