Linux Intermediate Architecture First chapter Two

Source: Internet
Author: User
Tags curl install php fully qualified domain name

The beginning forgot to write, later again tidy, starting from now on debugging Apache


One, Apache installation (installed to half only remembered to write blog, sorry)

[[email protected] apache2.2.27]# Pwd/application/apache2.2.27[[email protected] apache2.2.27]#./BIN/APACHECTL-T # # # Syntax detection normal httpd:could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for Servernamesyntax O K[[email protected] apache2.2.27]#./bin/apachectl Start # # #启动apache服务正常httpd: Could not reliably determine the server ' s Fully qualified domain name, using 127.0.0.1 for SERVERNAMEHTTPD (PID 55992) already running


Question one, the access error is as follows

[Email protected] apache2.2.27]# wget 192.168.152.133--2017-02-17 10:42:03--http://192.168.152.133/Connecting to 192.168.152.133:80. Connected. HTTP request sent, awaiting response ... 403 forbidden2017-02-17 10:42:03 ERROR 403:forbidden.

Solution Ideas:

Iptables, SELinux has been closed.

So consider that the Apache installation path belongs to the user is not set up well

[[email protected] apache2.2.27]# ll /application/apache2.2.27/ -d ### Permissions have been modified good drwxr-xr-x. 15 apache1 apache1 4096 feb 17 10:01 /application/ apache2.2.27/[[email protected] apache2.2.27]# ./bin/apachectl restart  ### Restart Apache Service [[email protected] bin]# cp apachectl /etc/init.d/httpd[[email  Protected] init.d]# service httpd stop[[email protected] init.d]# service  HTTPD START[[EMAIL PROTECTED] INIT.D]# PS -EF |GREP HTTPD question two, The error is as follows Httpd: could not reliably determine the server ' s fully qualified  domain name, using 127.0.0.1 for servername solution:sed -i  ' s% #ServerName  www.example.com:80%ServerName  /application/apache2.2.27/conf/httpd.conf  test for normal access to [email  protected] apache2.2.27]# wget 192.168.152.133--2017-02-17 10:46:44--  http://192.168.152.133/Connecting to  192.168.152.133:80... connected. Http request sent, awaiting response... 200 oklength: 44 [text/html] saving to:  "Index.html" 100%[======================================================================== ====>] 44          --.-K/s   in  0s      2017-02-17 10:46:44  (3.76 mb/s)  -  "index.html"  SAVED [44/44]

To this Apache preliminary configuration is complete!


Second, the following start installation configuration MySQL


[Email protected] tools]# Tar XF mysql-5.1.62.tar.gz

[Email protected] tools]# CD mysql-5.1.62

./configure\

--prefix=/application/mysql5.1.72\

--with-unix-socket-path=/application/mysql5.1.72/tmp/mysql.sock\

--localstatedir=/application/mysql5.1.72/data \

--enable-assembler\

--enable-thread-safe-client\

--with-mysqld-user=mysql\

--with-big-tables\

--without-debug\

--with-pthread\

--enable-assembler\

--with-extra-charsets=complex\

--with-readline\

--with-ssl\

--with-embedded-server\

--enable-local-infile\

--with-plugins=partition,innobase\

--with-mysqld-ldflags=-all-static\

--with-client-ldflags=-all-static

Question One,

Checking for termcap functions Library ... configure:error:No curses/termcap Library found

Workaround:

[[email protected] mysql-5.1.62] #yum install ncurses ncurses-devel-y

When it appears Thank you for choosing mysql! ./configure finished, you can install the

Make && make install

Configure MySQL

CP Support-files/mysql.server/etc/init.d/mysql # # # put the startup script on the boot initialization directory

Note: If MySQL and Web services are not placed on the same server, then MySQL installation ends here

Third, install PHP

Get the environment you need before you install PHP

Install the Libiconv library file first

Tar XF libiconv-1.14.tar.gz cd libiconv-1.14ls./configure--prefix=/usr/local/libiconvmake && make install

[Email protected] tools]# CD php-5.3.15

./configure \

--prefix=/application/php5.3.27\

--with-apxs2=/application/apache/bin/apxs\

--with-mysql=/application/mysql\

--WITH-XMLRPC \

--WITH-OPENSSL \

--with-zlib \

--with-freetype-dir\

--WITH-GD \

--with-jpeg-dir \

--with-png-dir \

--with-iconv=/usr/local/libiconv\

--enable-short-tags\

--enable-sockets \

--enable-zend-multibyte\

--ENABLE-SOAP \

--enable-mbstring \

--enable-static \

--enable-gd-native-ttf\

--with-curl \

--with-xsl \

--ENABLE-FTP \

--with-libxml-dir

Question One,

Configure:error:xml2-config not found. Please check your LIBXML2 installation.

This is a lack of necessary library files

Workaround:

Yum installzlib libjpeg freetype libpng gd libxslt-devel Curl Libiconv zlib-devel libxml2-devel Lib Jpeg-devel freetype-devellibpng-devel gd-devel curl-devel-y


The Thank for using PHP appears. Indicates successful installation


Lamp installation temporarily placed aside, later configured

This article is from the "Dongliqiang" blog, make sure to keep this source http://6207422.blog.51cto.com/6197422/1898857

Linux Intermediate Architecture Chapter two

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.