Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6604813
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T19:12:25+00:00 2026-05-25T19:12:25+00:00

I grabbed the CI2/Doctrine2 from Wildly Inaccurate . I’m trying to start using it,

  • 0

I grabbed the CI2/Doctrine2 from Wildly Inaccurate. I’m trying to start using it, but before I’m actually getting to work with it, I wanted to make sure everything works. However, when I try the command line tool, I run into the following error:

$ ./doctrine orm:schema-tool:create

ATTENTION: This operation should not be executed in a production environment.

Creating database schema...

Warning: PDO::__construct(): [2002] Socket operation on non-socket (trying to connect via unix:///var/mysql/mysql.sock) in /Users/joris/Desktop/ci2_starter/application/libraries/Doctrine/DBAL/Driver/PDOConnection.php on line 36



  [PDOException]                                         
  SQLSTATE[HY000] [2002] Socket operation on non-socket  



orm:schema-tool:create [--dump-sql]

I’m running this on a cleanly installed MAMP Pro 2.0.1; I’m not really sure what to do to fix this error.. I’m not really knowledgeable on the inner (background) workings of MySQL. Could someone clear this up for me? Thanks a lot.

Update:

MacBook-Pro-van-Joris-Ooms:~ joris$ sudo find / -name 'mysql.sock'
Password:
/Applications/MAMP/tmp/mysql/mysql.sock
find: /dev/fd/3: Not a directory
find: /dev/fd/4: Not a directory
/private/var/mysql/mysql.sock
/private/var/mysql/mysql.sock/mysql.sock
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T19:12:26+00:00Added an answer on May 25, 2026 at 7:12 pm

    MAMP does use it’s own mysql socket while the CLi uses the default one in /var/mysql/mysql.sock.
    This could mean you are running the wrong PHP version (not the MAMP one but the default MAC OS X one). Not a big deal since it can deal with your Doctrine Command Line Issues as well.
    So you do have several options:

    1. try using the MAMP php version to start the CLi tool by putting the Path to your MAC OS X php version as a prefix i.e.

      /Applications/MAMP/bin/php5.3/bin/php ./doctrine orm:schema-tool:create

    2. just set up a link from /var/mysql/mysql.sock to the actual Socket file which should be in /Applications/MAMP//tmp/mysql/mysql.sock
      So you go to the terminal while your MAMP is running an type (You will be asked to type in a password):

      sudo ln -s /Applications/MAMP//tmp/mysql/mysql.sock /var/mysql/mysql.sock

    3. Find every occurrence of “/Applications/MAMP//tmp/mysql/mysql.sock” in any of your MAMP config files and change it to be /var/mysql/mysql.sock so you actually do use the default address for MySQL Socket. Though, i have never tested if this does work.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to compare a value which was grabbed using the get method
I'm trying to parse the json grabbed from here . Basically what I do
using PHP and MySQL i have grabbed an array of facebook user ids from
Having a bit of a nightmare getting bluecloth to work on windows. I grabbed
I'm using dompdf to generate a PDF. I've grabbed the code from the dompdf
I grabbed this code form JCarousel and just trying to understand these lines below.
I have grabbed some XML data using this piece of jQuery: $.ajax({ type: POST,
I'm working on a long string grabbed from a Session that uses § (Section
Grabbed the images from a similar question in WPF. Basically I want the extra
Grabbed this from a sample: protected override ObjectContext CreateDataSource() { NorthwindContext nw = new

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.