Install JDK + TOMCAT + MYSQL in Ubuntu

Source: Internet
Author: User

Click Ubuntu system => System Management => New Software Package Manager

Search for the jdk mysql keyword and select the software source to be installed from the search list.

I. Configuration ~ /. Bashrc File
Default JDK installation path/usr/lib/jvm/

In ~ /. Add it to the bashrc configuration file

JAVA_HOME =/usr/lib/jvm/java-1.5.0-sun

JAVA_BIN =/usr/lib/jvm/java-1.5.0-sun/bin

PATH = $ JAVA_HOME/bin: $ PATH

TOMCAT_HOME =/home/portal/apache-tomcat-6.0.13

CLASSPATH =.: $ JAVA_HOME/lib: $ TOMCAT_HOME/lib

Export JAVA_HOME JAVA_BIN PATH TOMCAT_HOME CLASSPATH

Ii. Configure/etc/environment
In the/etc/environment configuration file, add

PATH = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"
LANG = "zh_CN.UTF-8"
LANGUAGE = "zh_CN: zh"

CLASSPATH = ".:/usr/lib/jvm/java-1.5.0-sun/lib"
JAVA_HOME = "/usr/lib/jvm/java-1.5.0-sun /"

Iii. Mysql Remote Access Authorization
Mysql> grant all privileges on *. * TO admin @ localhost identified by 'Password' with grant option;
Mysql> grant all privileges on *. * TO admin @ % identified by 'Password' with grant option;

In the first sentence, an admin user is added to authorize access through a local machine (localhost) and the password is "password ". The second sentence is to authorize the admin user to initiate access from any other host (wildcard % ).

$ Sudo gedit/etc/mysql/my. cnf

Earlier versions

> Skip-networking => # skip-networking

New Version

> Bind-address = 127.0.0.1 => bind-address = IP address of your machine

Or comment out bind-address = 127.0.0.1 => # bind-address = 127.0.0.1

Restart MYSQL service $ sudo/etc/init. d/mysql restart

Then you can remotely access MySQL.

Iv. garbled characters in Ubuntu MySQL
$ Sudo gedit/etc/mysql/my. cnf

[Client]
Default-character-set = utf8
[Mysqld]
Default-character-set = utf8

Restart MYSQL service $ sudo/etc/init. d/mysql restart

Related Article

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.