The entire process of installing VMware, JDK, and Tomcat in win7

Source: Internet
Author: User

I. Prepare Resources

Simply put: it is to build a linux environment.

1. VMware (Virtual Machine)

Linux operating system Carrier

Workstation or Player

2. Operating System

I use centos: http://www.centoscn.com/CentosSoft/iso/2013/0331/184.html

Ii. Installation

I assume that the installation is complete at the beginning, and some common linux environments cannot be used when we enter the environment. Here I use permanent modifications (if one-time modifications are required, you can see what others do ).

1. You can use echo $ PATH to check how many items are added to the environment variable PATH.

Use vi to open the etc/profile file and add the following statement at the end:

Export PATH =/sbin:/usr/sbin: $ PATH

Move the file to your favorite location:

Cp command

The function of this command is to copy the given file or directory to another file or directory, just like the copy command in DOS, which is very powerful.

Syntax: cp [Option] source file or directory target file or directory

Note: This Command copies the specified source file to the target file or multiple source files to the target directory.

The options of this command are as follows:

-A this option is usually used when copying directories. It retains links and file attributes, and Recursively copies directories. Its role is equal to the combination of dpR options.

-D: the link is retained during copy.

-F delete an existing target file without prompting.

-I and f options are opposite. A prompt is displayed asking the user to confirm before overwriting the target file. When the answer is y, the target file will be overwritten, which is an interactive copy.

-P in addition to copying the source file content, cp also copies the modification time and access permissions to the new file.

-If the source file provided by r is a directory file, cp will recursively copy all subdirectories and files in the directory. The target file must be a directory name.

-L do not copy, but only link files.

It should be noted that, in order to prevent users from using the cp command to destroy another file inadvertently, for example, if the target file name specified by the user is an existing file name, after copying the file with the cp command, this file will be overwritten by the newly copied source file. Therefore, we recommend that you use the I option when copying the file using the cp command.

$ Cp-I exam1.c/usr/wang/shiyan1.c

Copy the file exam1.c to the/usr/wang directory and change it to shiyan1.c. If you do not want to rename a file, run the following command:

$ Cp exam1.c/usr/wang/

$ Cp-r/usr/xu/usr/liu/copy all the files and Their subdirectories in the/usr/xu directory to the/usr/liu directory.

Mv command

You can use the mv command to rename a file or directory or move the file from one directory to another. This command is like a combination of ren and move in DOS.

3. Install JDK (assuming that the basic linux environment has been created)

1. I used a browser in the virtual machine environment: downloaded JDK and tomcat

2. Decompress

Unzip tar-zxvf apache-tomcat-6.0.24.tar.gz

Modify environment variables:

Vi/etc/profile

Export JAVA_HOME =/home1/irteam/apps/jdk1.6.0 _ 32 jdk installation directory
Export PATH = $ JAVA_HOME/bin: $ PATH
Export CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar

3. Modify static IP addresses

/Etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE = eth0

ONBOOT = yes

BOOTPROTO = static

IPADDR = 192.168.0.3

NETMASK = 255.255.255.0

GATEWAY = 192.168.0.1

Make the IP address take effect:

/Sbin/ifdown eth0

/Sbin/ifup eth0

Configure dns resolution

Echo "nameserver 211.98.1.28">/etc/resolv. conf

Notify gateway to update information:

/Etc/init. d/network restart

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.