Fire Station building school (bkjia.com) NewsIn recent years, the proportion of Linux in the Web server market has been increasing. In addition to the free and secure nature of Linux, the Linux application services have become increasingly abundant. Most common services have good solutions on Linux. For the most widely used Web Services on Intenet, Linux has a better performance. No one can tell the exact number of websites on the Internet, but among the many websites, websites using PHP and supporting JSP undoubtedly occupy a huge market share. The following describes how to set up a Web server that supports jsp php MySQL on Linux.
Apache is undoubtedly the first choice for Web Services. MySQL is used for databases, which is enough for general applications. Of course, large databases such as oracle and DB2 can be installed in Linux, but they are expensive. As for the development language support, supporting JSP and PHP is undoubtedly the most popular and widely used web development language at present. All of these software can be found on the following websites:
Resin: http://www.caucho.com/
JDK: http://java.sun.com/
Apache: http://www.apache.org
MySQL: http://www.mysql.com
PHP: http://www.php.net
MM. MySQL: http://mmmysql.sourceforge.net/
Download the corresponding software from the above website. The software downloaded by the author is as follows:
Mysql-4.0.15.tar.gz
Apache_1.3.28.tar.gz
Php-4.3.3.tar.gz
Resin-3.0.3.tar.gz
Mysql-connector-java-3.1.0-alpha.tar.gz
J2sdk-1_4_2_01-linux-i586.bin
1. Install MySQL
The installation of MySQL is relatively simple, but the compilation process may be a bit long. The specific steps are as follows:
Reference content is as follows: # Tar-xzpvf mysql-4.0.15.tar.gz # adduser-s/bin/false mysql #. /configure -- prefix =/usr/local/terry_yu/mysql -- enable-author er -- with-innodb -- with-charset = gb2312 # make install #/usr/local/terry_yu/ mysql/bin/mysql_install_db # chown-R root/usr/local/terry_yu/mysql/# chown-R mysql/usr/local/terry_yu/mysql/var # chgrp-R mysql/ usr/local/terry_yu/mysql/#/usr/local/terry_yu/mysql/bin/mysql_install_db |
Modify/etc/ld. so. conf and add the following line at the end:
/Usr/local/terry_yu/mysql/lib and then execute the following command:
# Ldconfig start MySQL with the following command
/Usr/local/terry_yu/mysql/bin/mysqld_safe & run the following command to modify the MySQL root Password:
/Usr/local/terry_yu/mysql/bin/mysqladmin-uroot password abcdefg
Run the following command to access the MySQL command line:
Reference content is as follows: [Root @ terry root] #/usr/local/terry_yu/mysql/bin/mysql-uroot-p Enter password: Welcome to the MySQL monitor. commands end with; or \ g. your MySQL connection id is 1 to server version: 4.0.15 Type 'help; 'or' \ H' for help. type '\ C' to clear the buffer. Mysql> quit Bye |
The above information indicates that MySQL has been successfully run.
Ii. Install JDK
Reference content is as follows: # Chmod 755 j2sdk-1_4_2_01-linux-i586.bin #. /j2sdk-1_4_2_01-linux-i586.bin # mv j2sdk1.4.2 _ 01 // usr/local/terry_yu/# cd/usr/local/terry_yu/# ln-s j2sdk1.4.2 _ 01/jdk # ln-s jdk/jre /jre # vi/etc/profile JAVA_HOME =/usr/local/terry_yu/jdk RESIN_HOME =/usr/local/terry_yu/resin CLASSPATH =. :.. /$ JAVA_HOME/lib: $ JAVA_HOME/jre/lib: $ RESIN_HOME/lib:/usr/local/terry_yu/jdbc PATH = $ PATH: $ JAVA_HOME/bin: $ JAVA_HOME/jre/bin |
Log out of the current logon environment and log on again. Then, the environment variable you just set will take effect. Then, run the following command to test it:
[Root @ terry root] # java-version java version "1.4.2 _ 01" Java (TM) 2 Runtime Environment, Standard Edition (build 1.4.2 _ 01-b06) Java HotSpot (TM) client VM (build 1.4.2 _ 01-b06, mixed mode). If similar information is displayed, the JDK environment is ready. In fact, in the above/etc/profile, we not only set the JDK environment variables, but also set the environment variables for Resin and JDBC. These are all necessary settings for installing Resin later.
- 2 pages in total:
- Previous Page
- 1
- 2
- Next Page