Ubuntu 10.04 install MySQL5, Cherokee, and PHP5

Source: Internet
Author: User
Cherokee is a fast, flexible, and easy-to-configure WebServer. it supports common technologies today: FastCGI, SCGI, PHP, CGI, TLSandSSL encrypted connections, virtualhosts, authentication, ontheflyencoding, loadbalancing, Apachecompatiblelogfiles, andmuchmor

Cherokee is a fast, flexible, and easy-to-configure Web Server. it supports common technologies today: FastCGI, SCGI, PHP, CGI, TLS and SSL encrypted connections, virtual hosts, authentication, on the fly encoding, load balancing, Apache compatible log files, and much more. this tutorial demonstrates how to install Cherokee on the Ubuntu 10.04 server with PHP5 (through FastCGI) and MySQL.

Cherokee can configure a Web-based control panel. We can start with the following:

Cherokee-admin-B

(Default: cherokee-admin Login 127.0.0.1 (localhost ))

Root @ server1 :~ # Cherokee-admin-B

Login:
User: admin
One-time Password: gU7dYa7zq31yjC6p

Web connection:
URL: http: // localhost: 9090/

[17:42:12. 448] (error) rrd_tools.c: 114-cocould not find the rrdtool binary.
Cherokee Web Server 0.99.39 (Feb 2 2010): Listening on port ALL: 9090, TLS
Disabled, IPv6 disabled, using epoll, 4096 fds system limit, max. 2041
Connections, caching I/O, single thread

You can find the username and password you need to log on to the network interface.

Http: // 192.168.0.100: 9090 /:

This is how the network interface:

Stop cherokee-admin and press CTRL + C to interrupt.

4. Install PHP5

You can run the FastCGI and Ubuntu FastCGI-enabled php5 installation packages to install PHP5 On Cherokee:

Aptitude install php5-cgi

5 configure PHP5

Modify/etc/php5/cgi/php. ini and add cgi. fix_pathinfo = 1.

Vi/etc/php5/cgi/php. ini

[...]cgi.fix_pathinfo = 1

Restart Cherokee:

/Etc/init. d/cherokee restart

6. Start PHP5 On Cherokee.

PHP is not started by default in Cherokee. To enable it, restart the Cherokee's web-based control panel...

Cherokee-admin-B

... Log On (http: // 192.168.0.100: 9090 /).

View Virtual Servers and select the default Virtual Host:

Click the wizard button:

Under Wizards> versions, click the link PHP icon next to the running Wizard:

Ages, click the link PHP icon next to the run wizard: "src =" http://img.vv15.com/images/201006/Cherokee1%20 (6).png "width = 550 jQuery1277538299859 =" 13 ">

PHP should now be listed in the behavior label. Make sure you mark its checkbox in the Final column:

By clicking the link in the target PHP column, you can change it if you like the default PHP setting (this is not necessary, the default setting should be in most cases case ). the handler on the FastCGI settings tab:

When you leave the control panel, you must restart Cherokee to make effect more effective. In this way, select Graceful to restart the control panel, and click the left sidebar to save the changes in the Saved state:

Press Ctrl + C to stop the control panel. 7. Test PHP5/Getting. For details, install the default Web site root file/var/www. We will create a small php file (info. php ).

This file will show many useful details about our PHP installation, such as the installed PHP version.

Vi/var/www/info. php

     

Enter at the address (e.g. http: // 192.168.0.100/info. php ):

Know that PHP5 is working, and it's working through FastCGI, as shown in the Server API line. if you scroll further down, you will see all modules that are already enabled in PHP5. MySQL is not listed there which means we don't have MySQL support in PHP5 yet.

8 Getting MySQL Support In PHP5

To get MySQL support in PHP, we can install the php5-mysql package. it's a good idea to install some other PHP5 modules as well as you might need them for your applications. you can search for available PHP5 modules like this:

Aptitude search php5

Pick the ones you need and install them like this:

Aptitude install php5-mysql php5-curl php5-gd php5-idn php5-imagick php5-imap php5-mcrypt php5-memcache php5-mhash php5-ming php5-ps php5-pspell php5-recode

Now restart Cherokee:

/Etc/init. d/cherokee restart

Now reload http: // 192.168.0.100/info. php in your browser and scroll down to the modules section again. You shoshould now find lots of new modules there, including the MySQL module:

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.