Linux Experience (jdk7+tomcat7+mysql5.5) deployment environment

Source: Internet
Author: User

--------------------------------------------------------------------------------------------------------------- ---JDK0: Download jdk http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html1: Uninstall (root user) 1.0: Query for installed jdk# rpm-qa|grep JDK ***# rpm-qa|grep java ***1.1: Remove by name (-E for delete,-nodeps to prevent JDK from associating with program. Cause the deletion to fail!

# rpm-e-nodeps***1.2: Execute java-version again; If prompted-bash:java-version:command not found do not continue with the following scenarios, the JDK is removed successfully.

1.3: Delete folder manually (-F to delete entire folder and subfolders) # rm-f/usr/bin/java # rm-f/usr/bin/javac # rm-f/etc/alternatives/java # rm-f/etc/alte Rnatives/javac2: Install (Root user) 2.1: Add permissions to each user # CHOMD +x jdk_*.*.*.rpm2.2: Install jdk# RPM-IVH jdk_*.*.*.rpm2.3: Changes such as the following configuration file |-- # CD/Switch to root folder |--# CD ECT profile folder |--# VI/profile Change/etc/profile file (global All users) |--#打开profile后. Press I to enter edit mode. Added at the end: #set java environmentexport java_home=/usr/share/jdk1.7.0_60export path= $JAVA _home/bin: $PATHexport classpath=. : $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar|--#按catl +c Enter Normall mode, enter #wq save and close |--# Find-name. Bash_ Profile find the location of Bash_profile./skel/.bash_profile|--# vi./skel/.bash_profile. Change the. bash_profile file (using these environment variables for a user right) |--# When profile is open, press I to enter edit mode. Added at the end: Export java_home=/usr/java/jdk1.7.0_60# First confirm if your JDK is also this folder export path= $JAVA _home/bin: $PATHexport classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar|--#按catl +c into normall mode, enter #wq save and close |--#source/etc/ After profile execution 2.4: test [[email protected] ~]# vim hello.javapublic class hello{public static void Main (STring[] args) {System.out.println ("Hello World");}} [[email protected] ~]# javac hello.java[[email protected] ~]# java Hellohello World3: Many other specific HTTP/ www.2cto.com/os/201211/171035. HTML------------------------------------------------------------------------------------------------------------------Tom CAT0::HTTP://TOMCAT.APACHE.ORG/DOWNLOAD-70.CGI1: Decompression tomcat#unzip xxx.zip#zip decompression #tar-zxvf xxx.tar.gx# Tar decompression 2: Then move Tomcat to/usr/java/tomcat[version];(personal advice) #mv-RF tomcat_x.x.x/usr/java/tomcat[version]3: Configuring the Tomcat environment (optional) #vim/etc/profile= #在末尾增加例如以下配置export Tomcat_home=/usr/java/tomcat7/binexport catalina_home=/usr/java/tomcat7# Its purpose: To be able to execute under the Random folder./shutdown.sh or./STARTUP.SH4: Test access: http://localhost:80805: Then you can package the Web project as a zip, by pscp xx in the window cmd [Email protected]://xx//xx uploads the project to the server. Then to the server decompression, and then restart Tomcat, you can execute .... Whistling 5: Specific references: Http://blog.sina.com.cn/s/blog_ 866c5a5d0101cn1l.html---------------------------------------------------------------------------------------------------- --------------MySql0: Download site: http://dev.mysql.com/downloads/mysql/5.1.html1: Install server[[email protected] ~]# RPM-IVH xxx.emp; 2: Install client[[email protected] ~]# rpm-ivh xxx.emp;3:mysql key folder |--database folder [[email protected] ~]#/var/lib/ mysql|--configuration file [[[Email protected] ~]#/usr/share/mysql (mysql.server and configuration files) |--related commands [[email protected] ~]#/usr /bin/(mysqladmin|mysqldump) |--startup script [[email protected] ~]#/etc/rc.d/init.d (startup script file MySQL folder) 4: Start Mysql[[email  protected] ~]#/etc/init.d/mysql start5: View the port number in use (assuming 3306 starts successfully) [[email protected] ~]# netstat-natactive Internet connections (servers and established) Proto recv-q send-q Local address Foreign Address State TCP 0 0 127.0.0.1:2208 0.0.0.0:* LISTEN TCP 0 0 0.0 .0.0:776 0.0.0.0:* LISTEN TCP 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN TCP 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 6: Setup password after installation MySQL has a default user Root,password is not.

[[email protected] ~]#/usr/bin/mysqladmin/-u root-p password 1234567: Login to Mysql[[email protected] ~]# mysql-u root-p 12 34568: Query Database Show DATABASES9: query table use testshow TABLES10: Stop mysql[[email protected] ~]#/usr/bin/mysqladmin-u root-p Shutdown11: Common Cause 11.1:linuxe 13:07mysql after startup. Linuxe MySQL cannot be connected under Windows. Error: 1130-host. is not allowed-connect to-this MySQL server open MySQL remote connection does not use localhost to resolve Way Http://www.cnblogs.com/xyzdw/archive/2011/08/11/2135227.html I was resolved by following the grant all privileges on * * to ' username ' @ '% ' identified by ' password ' with GRANT OPTION; FLUSH privileges;12: Specific references: http://www.t086.com/article/638------------------------------------------------------- -----------------------------------------------------------


In the study, we all encounter very many wonderful problems. But this wonderful problem is a valuable experience for us to ascend.

So, please don't worry too much, blame yourself.

Be patient and calm down to solve the problem.


Linux Experience (jdk7+tomcat7+mysql5.5) deployment environment

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.