PHP / MySQL on Clean Install

I've just been asked t set up a new production server using 10.6.8 server.


I've got a clean install of 10.6 Server with the software update completed to 10.6.8.


I have DNS, Open Directory, AFP, SMB & Web services running.


In the web server I have enabled the PHP module *and* checked that this has been uncommented in the httpd.conf file and restarted everything (even tried rebooting) but PHP is still not running.


What else do I need to do to get PHP running on a clean install?


What (if anything) will I need to do to get MySQL running and talking to PHP?


This is the first time I've had to bring up a production web server using OSX server so sorry if these questions are a little lame.


We're using MAMP on the development server, but this is for production.

Posted on Apr 9, 2013 1:57 AM

Reply
4 replies

Apr 9, 2013 4:35 AM in response to Dave_E_P

Assuming php5_module is eanbled in the module list, you'll need to get php.ini created and configured for local requirements from the /etc/php.ini.default default using nano or vim or such, and you need to enable CGI execution for the particular web site in the options tab and add (usually) index.php or such into the list of files in the default list in the general tab of the web site. You might want server side includes and you probably do not want WebDAV and folder listings.


Quick write-ups I did a while back here is how to enable php on OS X Server and FWIW, here is how to enable php on OS X client. The latter has some more details on working with the php.ini file.


And FWIW and solely to confirm your DNS services are correct — mentioned only because DNS is fundamental to the whole configuration of OS X Server, and getting DNS wrong tends to cause cascading failures in other services and difficulties — launch Terminal.app and issue the following non-distructive diagnostic command:


sudo changeip -checkhostname


After some chatter about the local host, that'll then (usually) tell you if DNS is correct or if it needs changes.

Apr 9, 2013 5:16 AM in response to MrHoffman

Thanks for the reply. I really appreciate it. The php.ini file was already there and it seems everything was right all along because some how it all ust started working without me making any more changes.


MySQL is enabled and I've downloaded myPHPAdmin and installed. Now I'm confused again because I get the login screen (myPHPAdmin) enter 'root' and the MySQL password and all I get is a blank screen. There's code in the source but nothing showing on the screen, so I guess at least I'm on to the next step.


Thanks again 🙂

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

PHP / MySQL on Clean Install

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.