There is basically no big difference in OSX10.9. For the convenience of new system users, the younger brother reorganized it, because the Server software under OSX10.9 has been upgraded a lot, and some steps are not the same. The hardware is not described in detail. First, you must have a PC or Mac that can run OSX. This article focuses on operations
There is basically no big difference in OS X 10.9. For the convenience of new system users, the younger brother reorganized it, because the Server software under OSX 10.9 has been upgraded a lot, and some steps are not the same. The hardware is not described in detail. First, you must have a PC or Mac that can run OS X. This article focuses on operations
There is basically no big difference in OS X 10.9. For the convenience of new system users, the younger brother reorganized it, because the Server software under OSX 10.9 has been upgraded a lot, and some steps are not the same.
The hardware is not described in detail. First, you must have a PC or Mac that can run OS X.
The operating system used in this article is OS X 10.9 Mavericks.ServerSuite Server 3.
First, downloadServerSuite Server 3.0 can be found in App Store (19.99 $) and Software Download Area.
This Server suite can be installed or not, because in addition to some functions unexpectedly provided by the WEB service, such as WIKI and mail service, Server 3 suite, xcode collaboration and other functions are basically irrelevant to the WEB services to be used. the Apache service we want to use can be used without a graphical interface.ConfigurationSo, you finally understand.
WEBServerApplication: Apache + PHP
In the Server suite, PHP and Apache applications can be directly activated. It is simpler for new users.
In addition, domain name settings can be directly performed through the graphic interface.
Easy to useConfigurationDomain name and so on. More and more stupid like IIS.
If you want to manuallyConfigurationTo access the Apache file, enter
/Library/Server/Web/Config/Apache2/directory
Httpd_server_app.conf totalConfigurationFile.
The/sites directory is for different sitesConfigurationFile.
Default
0000_any_80 _. conf is the default site automatically created by the system.ConfigurationFile.
For PHP. ini files, there are two file associations under OS X 10.9.Configuration
/Library/Server/Web/Config/php. ini
And
/Etc/php. ini
/Library/Server/Web/Config/php. ini if it overlaps with/etc/php. ini, the former takes effect first.
After all the settings are enabled, you can open your browser and enter http: // 127.0.0.1 to view your website initialization page.
Mysql database
Of course, this is not yet completed, that is, to install the free database software Mysql. Although PostgreSQL is provided on Mac, Mysql is still widely used. Currently, small-sized databases in ChinaServerStill running on Mysql.
First, go to the Mysql official download database software.
Http://dev.mysql.com/downloads/mysql/
As of the posting date, Mysql 5.6.14. you only need to download the latest stable version. but you must download the 64Bit version. because OS X 10.9 is a pure 64-bit operating system. you do not need to register when downloading. Find No thanks, just start my download. you can.
It is recommended that you download the following DMG version
Http://cdn.mysql.com/Downloads/MySQL-5.6/mysql-5.6.14-osx10.7-x86_64.dmg
Easy to install with one click.
Install the SDK in the first three steps.
After installation, enter the terminal for easy access.
Alias mysql =/usr/local/mysql/bin/mysql
Alias mysqladmin =/usr/local/mysql/bin/mysqladmin
Add a shortcut and enter mysql to try it out.
Now you will see the most famous 2002 error. This is also the Mysql encountered on OS X.ConfigurationProblems that must be encountered.
The solution is as follows.
Do you still remember the php. ini file we mentioned earlier? Open the/etc/php. ini file
Find
Mysql. default_socket =
Add/tmp/mysql. sock
Mysql. default_socket =/tmp/mysql. sock
Then start input in the terminal
- Sudo apachectl restart
You can restart the web service to load the newConfiguration.
The first thing to do after Mysql is started is to set a password for the Root user. Enter the password in the terminal.
- Mysqladmin-uroot password "My password ""