Yum Command Mysql,jdk,tomcat

Source: Internet
Author: User

First, use the Yum list available XXX command to list the packages that can be installed in the remote repository

1. List Java packages that can be installed

       Yum List available java*

The output is as follows:

2. List the Tomcat packages that can be installed

       Yum List available tomcat*

The output is as follows:

3. List the MySQL packages that can be installed

       Yum List available mysql*

Output:

Use yum Install package 1, Package 2 ..... command to install the package we need

Yum install tomcat6 Tomcat6-webapps tomcat6-admin-webapps tomcat6-docs-webapp tomcat6-javadoc mysql-server Java-1.6.0-openjdk

Second, set MYSQ password:

-U root password ' new password '

Third, after installing TOMCAT6 and MySQL has been added to the system services, can now start to do these services

Service mysqld StartService tomcat6 start

or set the boot to start automatically

Chkconfig mysqld Onchkconfig Tomcat6 on

Four, the firewall to open TOMCAT6 port, the default is 8080

/sbin/iptables-i input-p TCP--dport 8080-J ACCEPT/etc/rc.d/init.d/iptables save/etc/init.d/ iptables restart

Or simply open the/etc/sysconfig/iptables file for editing, add access to port 8080, and then restart the firewall "service iptables restart"

V. TOMCAT6 application Deployment directory and configuration file location:

/usr/share/tomcat6/webapps/ROOT/etc/tomcat6

Six, MySQL configuration location:

/etc/my.cnf

I'm the one who executed this command to find out.

Find/-name MY.CNF

Vii. See if the default storage engine for MySQL supports INNODB and whether the default engine is InnoDB "many projects require"

1. After logging in to MySQL, execute the following command

Mysql>show engines;

The output results are as follows:

As you can see, the default storage engine is not InnoDB, and we modify it as follows/ETC/MY.CNF

Vi/etc/my.cnf

In the [mysqld] configuration section, add:

default-storage-engine=innodb

Then save exit and restart MySQL to

Service MySQL Restart

Look again at show engines and discover that the default database engine is InnoDB.

Viii. How to view MySQL database and whether Tomcat started successfully

To view ports:

Netstat-antp

If you have 3306 ports and 8080 port instructions to succeed, of course you can test tomcat via the browser to see if it starts more directly:

http://localhost:8080

Yum Command Mysql,jdk,tomcat

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.