Use Aliyun windows to deploy Javaweb services __java

Source: Internet
Author: User
    The same is the first time to share their learning process, itself is not to engage in the development of the background, because the work needs to first contact the cloud server, the background is java. The
    purchase of Ali Server ECS, I purchased the Windows system, according to official support use:
1 2 3

Aliyun official support documentation to connect to local computer resources

    Remote Desktop Connection, after the connection is a computer, in the local computer how to play on this computer how to play Bai.
    so the need to deploy Java background jdk,tomcat,mysql to install again, first download the installation package on the local computer, the installation package copy to the server. You
    will upload the Cloud Server JDK installation package, Tomcat, and MySQL installation package to the shared disk.
1 2 3 4


revisit JDK, Tomcat, MySQL download installation JDK

JDK website Download Connection

    Copy the JDK installation package to the cloud server.
    installation (recommended default installation, if you forget the installation path, find it, it is purely personal habits)
    set environment variables.
    Create a new two variable under the system variable and set the parameters:
    variable name java_home, variable value C:\ProgramFiles\Java\jdk1.8.0 (the installation path of your own computer JDK);
    variable name: CLASSPATH, Variable value.; %java_home%\lib;%java_home%\lib\tools.jar (Add. Means current path),
    variable name path, variable value;%java_home%\bin;%java_home%\jre\bin;
    win+r cmd Enter java-version to see if the installation was successful.
1 2 3 4 5 6 7 8 9 Tomcat

Tomcat website

Tomcat has the installation package, also has the installation-free compression pack, when downloading the choice.
It used to be an installation-free version.
1, open the Command Prompt window (win key +r input cmd can)
2, to the Tomcat directory, input service.bat is good
This is the direct use of the installation package. Copy the installation package to the cloud server.

Configure Tomcat Environment variables:
1 2

1, new catalina_home: variable name catalina_home, variable value is tomcat directory
2. Add%catalina_home%\common\lib\servlet.jar to classpath and separate them with semicolons.
3, add the Tomcat directory in the path system variable and separate it with a semicolon. Mysql

Download
Direct Baidu MySQL, this can be used

Copy the installation package to the cloud server.
then install the words can use the default installation, you can also customize the installation of custom, you can choose to install MySQL Workbench, but I still use navicat, if the Navicat also installed.

a problem was encountered while installing, possibly because the uninstall was not uninstalled completely.
1 2 3 4 5

From the forum to find a lot of ways, and finally directly skipped this step, this time the default root user password is empty. Then
use the Navicat directly to connect, the password is empty, and then modify the user password, it can be used normally.
1 2 3 Complete Configuration
    Here's how to run the SQL file and import data into the cloud server MySQL. The
    Java background is then exported to the war file, and the war file is placed under the Tomcat's WebApp folder in the cloud server to start Tomcat and complete.
    change the address to the IP address in the Aliyun instance, and test.
    (if Tomcat fails to start on Tomcat, click Startup will flash through and the Java environment is not configured properly.) )

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.