I have a MBP, installed MAMP, and I find that phpMyADMIN works fine.
I am also able to create websites and browse to them locally.
but now I am trying to do a DRUPAL install locally
I am able to get to the install screen of the DRUPAL system. but I can not get the DB SETUP
I am getting this error:
----------------------------------------------------------------------------------------
Failed to connect to your MySQL database server. MySQL reports the following message: Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2).
* Are you sure you have the correct username and password?
* Are you sure that you have typed the correct database hostname?
* Are you sure that the database server is running?
----------------------------------------------------------------------------------------
i ran this command from shell:
ps aux|grep mysql
and I get this:
vincentyoumans 32411 0.1 0.0 590472 192 s000 R+ 2:12PM 0:00.00 grep mysql
vincentyoumans 27431 0.0 0.3 634328 13740 ?? S 12:52PM 0:01.64 /Applications/MAMP/Library/libexec/mysqld --basedir=/Applications/MAMP/Library --datadir=/Applications/MAMP/db/mysql --user=mysql --pid-file=/Applications/MAMP/tmp/mysql/mysql.pid --port=8889 --socket=/Applications/MAMP/tmp/mysql/mysql.sock --lower_case_table_names=0
vincentyoumans 27400 0.0 0.0 600172 692 ?? S 12:52PM 0:00.01 /bin/sh /Applications/MAMP/Library/bin/mysqld_safe --port=8889 --socket=/Applications/MAMP/tmp/mysql/mysql.sock --lower_case_table_names=0 --pid-file=/Applications/MAMP/tmp/mysql/mysql.pid --log-error=/Applications/MAMP/logs/mysql_error_log
so mySQL is running...
but I do have some observations:
1... the first error I am getting on the DRUPAL error screen , the line: /var/mysql/mysql.sock does not exist on my box.
so there appears to be a problem with a config file somewhere.
so what can I do to fix this?
thanks
ps... I have a hunch that I may have installed macports with apache and mysql a long time ago. so there may be preexisting config files.
Comments
Where did you unzip your
Where did you unzip your Drupal files? Where are the files for the local sites you can get to?
drupal and MAMP
I can browse to: dr01.localhost
and get the install screen for drupal.
but then I try to do the DB and nothing happens
I get the problems I mention above.
I put MAMP under applications
and my root dir seems to be working.
I am now going to try reinstalling MAMP
Doing Native iPHONE, ANDROID, Titanium, node.js and DRUPAL. as a contractor.
You have to create a MySQL
You have to create a MySQL database with a user and password before you can install Drupal.
At the command line: mysql
From MySQL prompt:
create database db_name;
use db_name;
grant all on db_name.* to db_user@'localhost' identified by 'password';
flush privileges;
Joseph Davis
Technical Support Representative
jdavis@hostmysite.com
yes, I know that.
and I was able to connect to my DB that I created for the DRUPAL site from phpMyadmin. but since I posted this message, I have been monkeying around with my MBP so much, now even phpmyadmin does not work.
what I was looking for were the config files / environment vars that php and mysql use to point to a DB.
Normally, I deploy DRUPAL on a server. I have done it about 300 times in the last couple months. and I have WAMP running great on my windows machine. But I just got this new MBP to do iPhone development, and wanted to get WAMP running on this. NOT easy for me.
Doing Native iPHONE, ANDROID, Titanium, node.js and DRUPAL. as a contractor.
Had the same problem...
Found this googling and it works:
In the settings.php file add "i" and port "8889" to the database connection path as so:
$db_url = 'mysqli://root:root@localhost:8889/';