Ubuntu11.10 build and configure Nagios

Source: Internet
Author: User
Tags install openssl
Install ubuntu11.101_top32bit install apache2, php5, openssl, libssl-dev, gcc compiler and Development Library, gd development library, php, php-apache, php-related plug-ins can use the apt-get command install these software packages, type the command: sudoapt-getinstallapache2sudoapt-getinstallbuild-essen

Install Ubuntu 11.10 Desktop 32bit

Install plug-ins related to apache2, php5, openssl, libssl-dev, gcc compiler and Development Library, gd development library, php, php-apache, and php.

You can use the apt-get command to install these software packages. type the command:

Sudo apt-get install apache2

Sudo apt-get install build-essential

Sudo apt-get install libgd2-xpm-dev

Sudo apt-get install openssl

Sudo apt-get install libssl-dev

Sudo apt-get install php5

Sudo apt-get install libapache2-mod-php5 (this may have been installed when you install php5, if you do not need to install it)

Sudo apt-get install lib1_8

Sudo apt-get install libjpeg8-dev

Sudo apt-get install curl

Sudo apt-get install libcurl3

Sudo apt-get install libpng12-0

Sudo apt-get install libpng12-dev

Sudo apt-get install freetype2-demos

Sudo apt-get install libfreetype6

Sudo apt-get install libxml2

Sudo apt-get install libxml2-dev

Configure apache

If the vim editor is not installed by default, install vim first, because the default vi editor is quite disgusting in ubuntu.

Sudo apt-get install vim

Sudo vim/etc/apache2/apache2.conf

Press shift-g, that is, G, to the end of the article, add the following configuration

AddType application/x-httpd-php. php. htm. html

Adddefacharcharset UTF-8

DirectoryIndexindex. php index.html

Start apache service

Sudo/etc/init. d/apache2 start

Use the chkconfig tool to set it to random startup. If chkconfig is not installed, install chkconfig first.

Sudo apt-get install chkconfig

Sudo update-rc.d apache2 defaults

Sudochkconfig apache2 on

Test whether php Parsing is normal

Switch to the/var/www directory in shell

Cd/var/www

Clear files

Rm-rf *

Create test page

Vimindex. php

Phpinfo ();

?>

Exit and save

Open a browser and test:

Http: // localhost

Whether php information is displayed normally

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.