New To Mac-Forums?

Welcome to our community! Join the discussion today by registering your FREE account. If you have any problems with the registration process, please contact us!

Get your questions answered by community gurus Advice and insight from world-class Apple enthusiasts Exclusive access to members-only contests, giveaways and deals

Join today!

 
Start a Discussion
 

Mac-Forums Brief

Subscribe to Mac-Forums Brief to receive special offers from Mac-Forums partners and sponsors

Join the conversation RSS
Web Design and Hosting Creating sites, scripting, and hosting discussions.

Installing mySQl on Mac OS X


Post Reply New Thread Subscribe

 
Thread Tools
sealey
Guest
 
Posts: n/a

Hi, I wonder if anyone can be of assistance. I am doing a few web projects at the moment in PHP using mySQL as a back end but it's so time consuming to keep FTPing the files up to my ISP to test every change.

So I decided to install PHP and mySQL on my Mac running Mac OS X 10.3. Installation of PHP went very smoothly and is running fine with the Apache installation that came with Mac OS X. However I am really struggling to get mySQL up and running. DOwnlaoded it from the mySQL site and run the install and followed the instructions as best I could but I have no idea how to link it in with PHP and have no idea to test if it's installed okay or check if it's running. Can someone please offer me some simple step by step instructions?

Thanks in advance,

Richard Seale
QUOTE Thanks
dziner
Guest
 
Posts: n/a

I recommend Marc Liyanage's site:

entropy.ch

There seems to be a lot of info there. Like you, I have tried to install php and mysql so that I can build dynamic sites locally. BUT, I got into a mess of stuff and I don't think mysql is installed properly... so I kinda gave up. Until I rebuild my system and start over again.
QUOTE Thanks
Murlyn

 
Murlyn's Avatar
 
Member Since: Jun 11, 2003
Location: Mount Vernon, WA
Posts: 4,909
Murlyn is a name known to allMurlyn is a name known to allMurlyn is a name known to allMurlyn is a name known to allMurlyn is a name known to allMurlyn is a name known to allMurlyn is a name known to all
Mac Specs: MacBook Pro 2.6 GHz Core 2 Duo 4GB RAM OS 10.5.2

Murlyn is offline
Install phpMyAdmin that will help you figure out if it is running or not.
QUOTE Thanks
nr-media
Guest
 
Posts: n/a

Ping port 3306, should get a response if mySql is up.

I use the Navicat client to access mySql.
QUOTE Thanks
h0tk4rl
Guest
 
Posts: n/a

You don't need to link mysql to php. It's more of a loading php modules in your apache config file. To see if MySQL is functional, from a terminal window,

cd /usr/local/mysql/bin
./mysql

If the server is running you should get this:
Quote:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 60 to server version: 4.0.20-standard

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql>
If not, you should get something like this

Quote:
ERROR 2002: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
To make sure your php is configured properly, create a test.php file with the following in it:
Quote:
<?php

phpinfo()

?>
If when you load http://localhost/test.php you see your php configs then you properly set up the module in apache.

Finally get a copy of phpmyadmin. Once you copy that to your site directory you only have to add the phpmyadmin home directory to the config file and if everything is configured, you'll have access to your database.
QUOTE Thanks
steveedge
Guest
 
Posts: n/a

If anyone else wants to do the above, check out this tutorial
http://www.onlamp.com/pub/ct/49
QUOTE Thanks
aXid
Guest
 
Posts: n/a

If all you need is to test your projects, I highly recommend using MAMP (Macintosh, Apache, MySQL, PHP). It has worked fine for me and installing it is a breeze.

Note: By default, you need to specify port when connecting to mysql or localhost:
PHP Code:
$link mysql_connect"127.0.0.1:8889""root""root" ); 
Code:
http://localhost:8888/
Good luck
QUOTE Thanks
mgm_03
Guest
 
Posts: n/a

NOTE :: Please advise all Mac users you know to use the installer packages at http://www.serverlogistics.com. Complete PHP, Complete Apache, Complete MySQL

Installations do NOT get any easier than this...
QUOTE Thanks

Post Reply New Thread Subscribe


« How do you host your website on your mac? | .PNG files for Photoshop on a Mac »
Thread Tools

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread
Thread Starter
Forum
Replies
Last Post
Mac Songs The mac 13 Switcher Hangout 7 05-06-2010 12:35 AM
pc to mac.. now back to pc.. my g5 1.6 biggest headache! dankim723 Apple Desktops 25 05-14-2005 11:05 AM
removing xp and installing mac os x 10.2 red_afrooo OS X - Operating System 17 01-14-2004 08:17 PM
Mac Users Get More ISP Choices schweb Apple Rumors and Reports 1 03-06-2003 10:57 AM

All times are GMT -4. The time now is 03:22 AM.

Powered by vBulletin
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
X

Welcome to Mac-Forums.com

Create your username to jump into the discussion!

New members like you have made this community the ultimate source for your Mac since 2003!


(4 digit year)

Already a member?