Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Introduction and installation method of MySQL Database

2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article introduces the relevant knowledge of "introduction and installation of MySQL database". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

I. introduction of MySQL database

MySQL is a relational database management system developed by the Swedish company MySQL AB and belongs to the products of Oracle. MySQL is one of the most popular relational database management systems. In the aspect of WEB application, MySQL is one of the best RDBMS (Relational Database Management System) application software.

MySQL is a relational database management system in which relational databases store data in different tables instead of all data in one large warehouse, which increases speed and flexibility.

The SQL language used by MySQL is the most commonly used standardized language for accessing databases. MySQL software adopts the dual licensing policy, which is divided into community version and commercial version. Because of its small size, high speed and low total cost of ownership, especially open source, the development of small and medium-sized websites generally choose MySQL as the website database.

II. Relational database and non-relational database

Database is generally divided into relational database and non-relational database. Redis is a non-relational database.

1. Relational database-sql

Use the SQL statement for the operation.

The data is stored on disk.

Common relational databases are MySQL, Oracle, SqlServer and sqlite.

two。 Non-relational database-nosql

Does not rely on sql statements.

The data is stored in memory.

Data can be persisted.

III. Installation of MySQL database

I use the CentOS system myself, so the following descriptions are available for CentOS, and the Ubuntu system should be different.

download

Log in to the official website and download the address to get an installation package mysql-5.7.28-1.el7.x86_64.rpm-bundle.tar.

Decompression

Extract the installation package $tar-xvf mysql-5.7.28-1.el7.x86_64.rpm-bundle.tar

Get the following installation packages

Mysql-community-client-5.7.28-1.el7.x86_64.rpm

Mysql-community-common-5.7.28-1.el7.x86_64.rpm

Mysql-community-devel-5.7.28-1.el7.x86_64.rpm

Mysql-community-embedded-5.7.28-1.el7.x86_64.rpm

Mysql-community-embedded-compat-5.7.28-1.el7.x86_64.rpm

Mysql-community-embedded-devel-5.7.28-1.el7.x86_64.rpm

Mysql-community-libs-5.7.28-1.el7.x86_64.rpm

Mysql-community-libs-compat-5.7.28-1.el7.x86_64.rpm

Mysql-community-server-5.7.28-1.el7.x86_64.rpm

Mysql-community-test-5.7.28-1.el7.x86_64.rpm

Installation

We only need to install these four.

Mysql-community-libs-5.7.28-1.el7.x86_64.rpm

Mysql-community-common-5.7.28-1.el7.x86_64.rpm

Mysql-community-client-5.7.28-1.el7.x86_64.rpm

Mysql-community-server-5.7.28-1.el7.x86_64.rpm

$rpm-ivh mysql-community-libs-5.7.28-1.el7.x86_64.rpm

$rpm-ivh mysql-community-common-5.7.28-1.el7.x86_64.rpm

$rpm-ivh mysql-community-client-5.7.28-1.el7.x86_64.rpm

$rpm-ivh mysql-community-server-5.7.28-1.el7.x86_64.rpm

Start up

Once it's all installed, we can start mysql server.

$service mysqld start

Check to see if the process starts successfully.

$ps aux | grep "mysql-*"

Log in

A password is required for the first login.

$mysql-u root-p

The initial password is in / var/log/mysqld.log.

$cat / var/log/mysqld.log

Enter the password to access the database.

Change the password.

When you get in, you can change the password.

$mysql > set password = password ('your password').

It should be noted here that the newly set password must meet the requirements.

1. There must be a special symbol.

two。 There must be uppercase and lowercase letters.

3. Numbers must be included.

4. The length must be greater than 8 characters.

Just refresh it at last.

$mysql > FLUSH PRIVILEGES

In this way, our MySQL is installed.

This is the end of the introduction and installation of MySQL database. Thank you for your reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report