{"id":50,"date":"2008-07-16T06:41:34","date_gmt":"2008-07-16T12:41:34","guid":{"rendered":"http:\/\/www.schwie.com\/brad\/?p=50"},"modified":"2018-01-06T16:32:56","modified_gmt":"2018-01-06T22:32:56","slug":"mysql-and-cocoamysql-tmpmysqlsock","status":"publish","type":"post","link":"https:\/\/www.schwie.com\/brad\/?p=50","title":{"rendered":"MySQL and CocoaMySQL \/tmp\/mysql.sock"},"content":{"rendered":"<p>I was having problems making a connection to a MySQL 5 database from CocoaMySQL, both running on Mac OS X Server 10.5.  I fired up Terminal, punched in the following line of code:<\/p>\n<p>sudo ln -s \/var\/mysql\/mysql.sock \/tmp\/mysql.sock<\/p>\n<p>and all was good.<\/p>\n<p>\n** UPDATE 1\/6\/2017 **<\/p>\n<p>\nWas having a similar problem under MacOS High Sierra Server.<\/p>\n<p>Error 2002 [HY000]: Can&#8217;t connect to local MySQL server through socket &#8216;\/var\/lib\/mysql\/mysql.sock&#8217; [2]<\/p>\n<p>I opened Terminal and punched in the following lines of code:<\/p>\n<p>mkdir \/var\/lib\/mysql\/<br \/>\nsudo ln -s \/var\/mysql\/mysql.sock \/var\/lib\/mysql\/mysql.sock<\/p>\n<p>All is good (again).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I was having problems making a connection to a MySQL 5 database from CocoaMySQL, both running on Mac OS X Server 10.5. I fired up Terminal, punched in the following line of code: sudo ln -s \/var\/mysql\/mysql.sock \/tmp\/mysql.sock and all &hellip; <a href=\"https:\/\/www.schwie.com\/brad\/?p=50\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-50","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=\/wp\/v2\/posts\/50","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=50"}],"version-history":[{"count":5,"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=\/wp\/v2\/posts\/50\/revisions"}],"predecessor-version":[{"id":531,"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=\/wp\/v2\/posts\/50\/revisions\/531"}],"wp:attachment":[{"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=50"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=50"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.schwie.com\/brad\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=50"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}