Ubuntu10 Nginx-0.8.54 Installation

Source: Internet
Author: User
Tags install openssl openssl download openssl library


Nginx is an http and reverse proxy server. In high-concurrency environments, the performance is better than apache, so we also install nginx In ubuntu. Download nginx-0.8.54.tar.gz, decompress and compile the installation command instructions: tar (z-use gzip to compress or decompress the archive; x-expand the archive; v-display the processed files in detail; f-specifies the archive or device) Java code tar-zxvf nginx-0.8.54.tar.gz to enter the relevant directory Java code. /configure make sudo make install if you are lucky, everything is OK, but I believe no one is lucky, haha. Ubuntu does not install any libraries by default. All dependent libraries must be manually installed. It is estimated that CentOS and other linux will be better. Generally, errors occur. Let's take a look at the possible problems. The pcre library is missing. /configure: error: the HTTP rewrite module requires the PCRE library. you can either disable the module by using -- without-http_rewrite_module option, or install the PCRE library into the system, or build the PCRE library statically from the source with nginx by using -- with-pcre = <path> option. solution: download and install the pcre-8.12 to solve the problem, decompress the package and perform the following operations on the pcre Java code. /configure make sudo make install If you are lucky enough to make a pcre, the gcc-c ++ and libtool are missing, that is, the c ++ compiling package libtool: compile: unrecognized option '-DHAVE_CONFIG_H 'libtool: compile: Try 'libtool -- help' for more information. make [1]: *** [pcrecpp. lo] Error 1 www.2cto.com make [1]: Leaving directory '/home/guangbo/work/pcre-8.12' make: *** [all] Error 2 guangbo @ guangbo-laptop :~ /Work/pcre-8.12 $ libtool-help-DHAVE_CONFIG_H The program 'libtool' is currently not installed. You can install it by typing: sudo apt-get install libtool guangbo @ guangbo-laptop :~ /Work/pcre-8.12 $ solution: install libtool and gcc-c ++ Java code sudo apt-get install libtool sudo apt-get install gcc-c ++ error guangbo @ guangbo-laptop: ~ /Soft/pcre-8.12 $ sudo apt-get install gcc-c ++ Reading package lists... done Building dependency tree Reading state information... done E: Couldn't find package gcc-c solution: update the source and reinstall gcc-c ++. Java code sudo apt-get install build-essential sudo apt-get update # It takes a long time to update the source sudo apt-get install gcc-c ++ www.2cto.com upgrade, if no error is reported, skip this step. Sudo apt-get upgrade # Update installed packages. The openssl library is missing for a long time. /configure: error: the HTTP cache module requires md5 functions from OpenSSL library. you can either disable the module by using -- without-http-cache option, or install the OpenSSL library into the system, or build the OpenSSL library statically from the source with nginx by using -- with-http_ssl_module -- with-openssl = <path> options. solution: Java code sud O apt-get install openssl lacks the zlib library. /configure: error: the HTTP gzip module requires the zlib library. you can either disable the module by using -- without-http_gzip_module option, or install the zlib library into the system, or build the zlib library statically from the source with nginx by using -- with-zlib = <path> option. solution: Download a libssl-dev package to install openssl. java code sudo apt-get install l Ibssl-dev does not have nginx and logs directory access permission [alert]: cocould not open error log file: open () "/usr/local/nginx/logs/error. log "failed (13: Permission denied) 06:09:33 [emerg] 24855 #0: mkdir ()"/usr/local/nginx/client_body_temp "failed (13: Permission denied) www.2cto.com solution: Java code sudo chmod a + rwx-R logs sudo chmod a + rwx-R/usr/local/nginx to test whether nginx is successfully installed, formally install and run the Java code sudo apt-get instal L open http: // localhost in the nginx/usr/local/nginx/sbin/nginx browser. The welcome page is displayed. Disable nginx Java code. /sbin/nginx-s stop Ubuntu Linux utility command tar (z-use gzip to compress or decompress the archive; x-expand the file from the archive; v-display the processed file in detail; f-specify the archive or device) tar-zxvf nginx-0.8.54.tar.gz ip view ifconfig compile make install compiled source package make install edit file sudo gedit/etc/profile modify root limit: chmod description (u: the same permissions as the file owner [a: Everyone]; +: added permissions; rwx: readable, writable, and executable)-R: recursive all directories and files sudo chmod a + rwx-R logs check whether the library is successfully installed dpkg -- list | grep openssl download and installation library sudo apt-get install libtool check whether the service is started properly ps -ef | grep: openssl installation path whereis openssl update source sudo apt-get update installed package sudo apt-get upgrade author peterwei

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.