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

Analysis on installation and Application of MySQL Database system

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

Share

Shulou(Shulou.com)06/01 Report--

The following mainly brings you to install the application of MySQL database system analysis, I hope that these words can bring you practical use, which is also the main purpose of my editing this article. All right, don't talk too much nonsense, let's just read the following.

1. Uninstall the original mysql

In the figure above, mysql was installed using rpm, so use rpm-e msyql-- nodeps to uninstall

2. Before installing mysql, you need to install the software development package. If you check "Software Development" when installing the operating system, you do not need to install it.

3. Mount the CD of the mysql software package

4. Open it after mounting

5. Mysql5.5 needs to be installed with cmake compilation and installation, so install the cmakepackage first.

6. Create and run users and unpack

7. Configuration

Cmake-DCMAKE_INSTALL_PREFIX=/usr/local/mysql-DSYSCONFDIR=/etc/-DDEFAULT_CHARSET=utf8-DDEFAULT_COLLATION=utf8_general_ci-DWITH_EXTRA_CHARSETS=all

8. Compile and install

9. Other adjustments after installation

1) permission setting

2) establish a configuration file

Cp support-files/my-medium.cnf / etc/my.cnf

3) initialize the database

4) set environment variables

Note that the last line above is:. / etc/profile (click on the space and enter / etc/profile)

10. Add system services

11. Enable mysql service

12. Access mysql database

13. Basic orders

1) check which databases are in the current server

2) check which tables are in the mysql database

3) View the structure of the users table

14. Commonly used commands

1) create a new database auth and table users

2) Delete users table and auth database

3) insert data

4) query data

The statement of addition, deletion, modification and query is exactly the same as that of sqlserver. You can refer to the sqlserver statement. I will not demonstrate it in detail here.

15. User authorization of database

1) create a new user xiaoqi and grant select permissions to all tables in the auth database

2) Log in to the server using xiaoqi

3) create a new database bdqn and authorize the host connection from the ip address 192.168.4.19 with the user name dbuser and password pwd@123, allowing any operation in the bdqn database

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