Ubuntu系统下使用apt-get安装Mysql8
记录一下在Ubuntu20.04 64位系统下面使用apt-get方式安装mysql8关系型数据库
Centos下使用yum安装Mysql8(Mysql5.7)以及常见的配置和使用
首先肯定是检查下当前Ubuntu系统是否已经安装过mysql数据库 一般拿到新的云服务器是没有安装的
root@myw:~# whereis mysql
mysql:
root@myw:~# find / -name 'mysql*'
/etc/apparmor.d/abstractions/mysql
/usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/mysql.cpython-38.pyc
/usr/lib/python3/dist-packages/sos/report/plugins/mysql.py
/usr/share/bash-completion/completions/mysqladmin
/usr/share/bash-completion/completions/mysql
/usr/share/vim/vim81/syntax/mysql.vim
root@myw:~#
Ubuntu系统和centos所用的依赖包管理器不一样
Ubuntu用的是apt包管理器 centos用的是yum包管理器
那么这里使用apt-get来安装mysql 为了能够安装高版本的mysql 我这里首先是更新apt-get 更新之后去安装mysql 发现mysql安装好后是8.x版本 对于使用8.x版本来说,这是一个很欣喜的消息
更新apt-get系统软件库
apt-get update
root@myw:~# apt-get update
Get:1 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Hit:2 http://archive.ubuntu.com/ubuntu focal InRelease
Get:3 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:4 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages [2,464 kB]
Get:5 http://archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
Get:6 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [2,850 kB]
Get:7 http://security.ubuntu.com/ubuntu focal-security/main Translation-en [385 kB]
Get:8 http://security.ubuntu.com/ubuntu focal-security/main amd64 c-n-f Metadata [13.2 kB]
Get:9 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 Packages [2,210 kB]
Get:10 http://security.ubuntu.com/ubuntu focal-security/restricted Translation-en [309 kB]
Get:11 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 c-n-f Metadata [580 B]
Get:12 http://security.ubuntu.com/ubuntu focal-security/universe amd64 Packages [885 kB]
Get:13 http://security.ubuntu.com/ubuntu focal-security/universe Translation-en [185 kB]
Get:14 http://security.ubuntu.com/ubuntu focal-security/universe amd64 c-n-f Metadata [19.1 kB]
Get:15 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 Packages [23.6 kB]
Get:16 http://security.ubuntu.com/ubuntu focal-security/multiverse Translation-en [5,504 B]
Get:17 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 c-n-f Metadata [548 B]
Get:18 http://archive.ubuntu.com/ubuntu focal-updates/main Translation-en [468 kB]
Get:19 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 c-n-f Metadata [17.1 kB]
Get:20 http://archive.ubuntu.com/ubuntu focal-updates/restricted amd64 Packages [2,327 kB]
Get:21 http://archive.ubuntu.com/ubuntu focal-updates/restricted Translation-en [325 kB]
Get:22 http://archive.ubuntu.com/ubuntu focal-updates/restricted amd64 c-n-f Metadata [576 B]
Get:23 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [1,117 kB]
Get:24 http://archive.ubuntu.com/ubuntu focal-updates/universe Translation-en [267 kB]
Get:25 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 c-n-f Metadata [25.6 kB]
Get:26 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 Packages [25.8 kB]
Get:27 http://archive.ubuntu.com/ubuntu focal-updates/multiverse Translation-en [7,484 B]
Get:28 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 c-n-f Metadata [620 B]
Get:29 http://archive.ubuntu.com/ubuntu focal-backports/main amd64 Packages [45.7 kB]
Get:30 http://archive.ubuntu.com/ubuntu focal-backports/main Translation-en [16.3 kB]
Get:31 http://archive.ubuntu.com/ubuntu focal-backports/main amd64 c-n-f Metadata [1,420 B]
Get:32 http://archive.ubuntu.com/ubuntu focal-backports/universe amd64 Packages [25.0 kB]
Get:33 http://archive.ubuntu.com/ubuntu focal-backports/universe Translation-en [16.3 kB]
Get:34 http://archive.ubuntu.com/ubuntu focal-backports/universe amd64 c-n-f Metadata [880 B]
Fetched 14.4 MB in 6s (2,221 kB/s)
Reading package lists... Done
root@myw:~#
直接安装mysql
apt-get install mysql-server -y
root@myw:~# apt-get install mysql-server -y
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:libcgi-fast-perl libcgi-pm-perl libencode-locale-perl libevent-core-2.1-7 libevent-pthreads-2.1-7 libfcgi-perl libhtml-parser-perl libhtml-tagset-perl libhtml-template-perl libhttp-date-perl libhttp-message-perl libio-html-perlliblwp-mediatypes-perl libmecab2 libtimedate-perl liburi-perl mecab-ipadic mecab-ipadic-utf8 mecab-utils mysql-client-8.0 mysql-client-core-8.0 mysql-common mysql-server-8.0 mysql-server-core-8.0
Suggested packages:libdata-dump-perl libipc-sharedcache-perl libwww-perl mailx tinyca
The following NEW packages will be installed:libcgi-fast-perl libcgi-pm-perl libencode-locale-perl libevent-core-2.1-7 libevent-pthreads-2.1-7 libfcgi-perl libhtml-parser-perl libhtml-tagset-perl libhtml-template-perl libhttp-date-perl libhttp-message-perl libio-html-perlliblwp-mediatypes-perl libmecab2 libtimedate-perl liburi-perl mecab-ipadic mecab-ipadic-utf8 mecab-utils mysql-client-8.0 mysql-client-core-8.0 mysql-common mysql-server mysql-server-8.0 mysql-server-core-8.0
0 upgraded, 25 newly installed, 0 to remove and 271 not upgraded.
Need to get 36.7 MB of archives.
After this operation, 318 MB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu focal/main amd64 mysql-common all 5.8+1.0.5ubuntu2 [7,496 B]
Get:2 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 mysql-client-core-8.0 amd64 8.0.34-0ubuntu0.20.04.1 [5,075 kB]
Get:3 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 mysql-client-8.0 amd64 8.0.34-0ubuntu0.20.04.1 [22.0 kB]
Get:4 http://archive.ubuntu.com/ubuntu focal/main amd64 libevent-core-2.1-7 amd64 2.1.11-stable-1 [89.1 kB]
Get:5 http://archive.ubuntu.com/ubuntu focal/main amd64 libevent-pthreads-2.1-7 amd64 2.1.11-stable-1 [7,372 B]
Get:6 http://archive.ubuntu.com/ubuntu focal/main amd64 libmecab2 amd64 0.996-10build1 [233 kB]
Get:7 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 mysql-server-core-8.0 amd64 8.0.34-0ubuntu0.20.04.1 [22.6 MB]
Get:8 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 mysql-server-8.0 amd64 8.0.34-0ubuntu0.20.04.1 [1,325 kB]
Get:9 http://archive.ubuntu.com/ubuntu focal/main amd64 libhtml-tagset-perl all 3.20-4 [12.5 kB]
Get:10 http://archive.ubuntu.com/ubuntu focal/main amd64 liburi-perl all 1.76-2 [77.5 kB]
Get:11 http://archive.ubuntu.com/ubuntu focal/main amd64 libhtml-parser-perl amd64 3.72-5 [86.3 kB]
Get:12 http://archive.ubuntu.com/ubuntu focal/main amd64 libcgi-pm-perl all 4.46-1 [186 kB]
Get:13 http://archive.ubuntu.com/ubuntu focal/main amd64 libfcgi-perl amd64 0.79-1 [33.1 kB]
Get:14 http://archive.ubuntu.com/ubuntu focal/main amd64 libcgi-fast-perl all 1:2.15-1 [10.5 kB]
Get:15 http://archive.ubuntu.com/ubuntu focal/main amd64 libencode-locale-perl all 1.05-1 [12.3 kB]
Get:16 http://archive.ubuntu.com/ubuntu focal/main amd64 libhtml-template-perl all 2.97-1 [59.0 kB]
Get:17 http://archive.ubuntu.com/ubuntu focal/main amd64 libtimedate-perl all 2.3200-1 [34.0 kB]
Get:18 http://archive.ubuntu.com/ubuntu focal/main amd64 libhttp-date-perl all 6.05-1 [9,920 B]
Get:19 http://archive.ubuntu.com/ubuntu focal/main amd64 libio-html-perl all 1.001-1 [14.9 kB]
Get:20 http://archive.ubuntu.com/ubuntu focal/main amd64 liblwp-mediatypes-perl all 6.04-1 [19.5 kB]
Get:21 http://archive.ubuntu.com/ubuntu focal/main amd64 libhttp-message-perl all 6.22-1 [76.1 kB]
Get:22 http://archive.ubuntu.com/ubuntu focal/main amd64 mecab-utils amd64 0.996-10build1 [4,912 B]
Get:23 http://archive.ubuntu.com/ubuntu focal/main amd64 mecab-ipadic all 2.7.0-20070801+main-2.1 [6,714 kB]
Get:24 http://archive.ubuntu.com/ubuntu focal/main amd64 mecab-ipadic-utf8 all 2.7.0-20070801+main-2.1 [4,380 B]
Get:25 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 mysql-server all 8.0.34-0ubuntu0.20.04.1 [9,468 B]
Fetched 36.7 MB in 12s (3,130 kB/s)
Preconfiguring packages ...
Selecting previously unselected package mysql-common.
(Reading database ... 72145 files and directories currently installed.)
Preparing to unpack .../0-mysql-common_5.8+1.0.5ubuntu2_all.deb ...
Unpacking mysql-common (5.8+1.0.5ubuntu2) ...
Selecting previously unselected package mysql-client-core-8.0.
Preparing to unpack .../1-mysql-client-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb ...
Unpacking mysql-client-core-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Selecting previously unselected package mysql-client-8.0.
Preparing to unpack .../2-mysql-client-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb ...
Unpacking mysql-client-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Selecting previously unselected package libevent-core-2.1-7:amd64.
Preparing to unpack .../3-libevent-core-2.1-7_2.1.11-stable-1_amd64.deb ...
Unpacking libevent-core-2.1-7:amd64 (2.1.11-stable-1) ...
Selecting previously unselected package libevent-pthreads-2.1-7:amd64.
Preparing to unpack .../4-libevent-pthreads-2.1-7_2.1.11-stable-1_amd64.deb ...
Unpacking libevent-pthreads-2.1-7:amd64 (2.1.11-stable-1) ...
Selecting previously unselected package libmecab2:amd64.
Preparing to unpack .../5-libmecab2_0.996-10build1_amd64.deb ...
Unpacking libmecab2:amd64 (0.996-10build1) ...
Selecting previously unselected package mysql-server-core-8.0.
Preparing to unpack .../6-mysql-server-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb ...
Unpacking mysql-server-core-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Setting up mysql-common (5.8+1.0.5ubuntu2) ...
update-alternatives: using /etc/mysql/my.cnf.fallback to provide /etc/mysql/my.cnf (my.cnf) in auto mode
Selecting previously unselected package mysql-server-8.0.
(Reading database ... 72361 files and directories currently installed.)
Preparing to unpack .../00-mysql-server-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb ...
Unpacking mysql-server-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Selecting previously unselected package libhtml-tagset-perl.
Preparing to unpack .../01-libhtml-tagset-perl_3.20-4_all.deb ...
Unpacking libhtml-tagset-perl (3.20-4) ...
Selecting previously unselected package liburi-perl.
Preparing to unpack .../02-liburi-perl_1.76-2_all.deb ...
Unpacking liburi-perl (1.76-2) ...
Selecting previously unselected package libhtml-parser-perl.
Preparing to unpack .../03-libhtml-parser-perl_3.72-5_amd64.deb ...
Unpacking libhtml-parser-perl (3.72-5) ...
Selecting previously unselected package libcgi-pm-perl.
Preparing to unpack .../04-libcgi-pm-perl_4.46-1_all.deb ...
Unpacking libcgi-pm-perl (4.46-1) ...
Selecting previously unselected package libfcgi-perl.
Preparing to unpack .../05-libfcgi-perl_0.79-1_amd64.deb ...
Unpacking libfcgi-perl (0.79-1) ...
Selecting previously unselected package libcgi-fast-perl.
Preparing to unpack .../06-libcgi-fast-perl_1%3a2.15-1_all.deb ...
Unpacking libcgi-fast-perl (1:2.15-1) ...
Selecting previously unselected package libencode-locale-perl.
Preparing to unpack .../07-libencode-locale-perl_1.05-1_all.deb ...
Unpacking libencode-locale-perl (1.05-1) ...
Selecting previously unselected package libhtml-template-perl.
Preparing to unpack .../08-libhtml-template-perl_2.97-1_all.deb ...
Unpacking libhtml-template-perl (2.97-1) ...
Selecting previously unselected package libtimedate-perl.
Preparing to unpack .../09-libtimedate-perl_2.3200-1_all.deb ...
Unpacking libtimedate-perl (2.3200-1) ...
Selecting previously unselected package libhttp-date-perl.
Preparing to unpack .../10-libhttp-date-perl_6.05-1_all.deb ...
Unpacking libhttp-date-perl (6.05-1) ...
Selecting previously unselected package libio-html-perl.
Preparing to unpack .../11-libio-html-perl_1.001-1_all.deb ...
Unpacking libio-html-perl (1.001-1) ...
Selecting previously unselected package liblwp-mediatypes-perl.
Preparing to unpack .../12-liblwp-mediatypes-perl_6.04-1_all.deb ...
Unpacking liblwp-mediatypes-perl (6.04-1) ...
Selecting previously unselected package libhttp-message-perl.
Preparing to unpack .../13-libhttp-message-perl_6.22-1_all.deb ...
Unpacking libhttp-message-perl (6.22-1) ...
Selecting previously unselected package mecab-utils.
Preparing to unpack .../14-mecab-utils_0.996-10build1_amd64.deb ...
Unpacking mecab-utils (0.996-10build1) ...
Selecting previously unselected package mecab-ipadic.
Preparing to unpack .../15-mecab-ipadic_2.7.0-20070801+main-2.1_all.deb ...
Unpacking mecab-ipadic (2.7.0-20070801+main-2.1) ...
Selecting previously unselected package mecab-ipadic-utf8.
Preparing to unpack .../16-mecab-ipadic-utf8_2.7.0-20070801+main-2.1_all.deb ...
Unpacking mecab-ipadic-utf8 (2.7.0-20070801+main-2.1) ...
Selecting previously unselected package mysql-server.
Preparing to unpack .../17-mysql-server_8.0.34-0ubuntu0.20.04.1_all.deb ...
Unpacking mysql-server (8.0.34-0ubuntu0.20.04.1) ...
Setting up libmecab2:amd64 (0.996-10build1) ...
Setting up mysql-client-core-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Setting up libhtml-tagset-perl (3.20-4) ...
Setting up liblwp-mediatypes-perl (6.04-1) ...
Setting up libencode-locale-perl (1.05-1) ...
Setting up mecab-utils (0.996-10build1) ...
Setting up libevent-core-2.1-7:amd64 (2.1.11-stable-1) ...
Setting up libio-html-perl (1.001-1) ...
Setting up libtimedate-perl (2.3200-1) ...
Setting up mysql-client-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Setting up libfcgi-perl (0.79-1) ...
Setting up liburi-perl (1.76-2) ...
Setting up libevent-pthreads-2.1-7:amd64 (2.1.11-stable-1) ...
Setting up libhttp-date-perl (6.05-1) ...
Setting up mecab-ipadic (2.7.0-20070801+main-2.1) ...
Compiling IPA dictionary for Mecab. This takes long time...
reading /usr/share/mecab/dic/ipadic/unk.def ... 40
emitting double-array: 100% |###########################################|
/usr/share/mecab/dic/ipadic/model.def is not found. skipped.
reading /usr/share/mecab/dic/ipadic/Noun.demonst.csv ... 120
reading /usr/share/mecab/dic/ipadic/Postp-col.csv ... 91
reading /usr/share/mecab/dic/ipadic/Noun.number.csv ... 42
reading /usr/share/mecab/dic/ipadic/Adj.csv ... 27210
reading /usr/share/mecab/dic/ipadic/Postp.csv ... 146
reading /usr/share/mecab/dic/ipadic/Noun.proper.csv ... 27328
reading /usr/share/mecab/dic/ipadic/Conjunction.csv ... 171
reading /usr/share/mecab/dic/ipadic/Auxil.csv ... 199
reading /usr/share/mecab/dic/ipadic/Adverb.csv ... 3032
reading /usr/share/mecab/dic/ipadic/Noun.others.csv ... 151
reading /usr/share/mecab/dic/ipadic/Suffix.csv ... 1393
reading /usr/share/mecab/dic/ipadic/Adnominal.csv ... 135
reading /usr/share/mecab/dic/ipadic/Filler.csv ... 19
reading /usr/share/mecab/dic/ipadic/Noun.place.csv ... 72999
reading /usr/share/mecab/dic/ipadic/Prefix.csv ... 221
reading /usr/share/mecab/dic/ipadic/Symbol.csv ... 208
reading /usr/share/mecab/dic/ipadic/Noun.adverbal.csv ... 795
reading /usr/share/mecab/dic/ipadic/Others.csv ... 2
reading /usr/share/mecab/dic/ipadic/Noun.name.csv ... 34202
reading /usr/share/mecab/dic/ipadic/Noun.adjv.csv ... 3328
reading /usr/share/mecab/dic/ipadic/Interjection.csv ... 252
reading /usr/share/mecab/dic/ipadic/Noun.org.csv ... 16668
reading /usr/share/mecab/dic/ipadic/Verb.csv ... 130750
reading /usr/share/mecab/dic/ipadic/Noun.nai.csv ... 42
reading /usr/share/mecab/dic/ipadic/Noun.verbal.csv ... 12146
reading /usr/share/mecab/dic/ipadic/Noun.csv ... 60477
emitting double-array: 100% |###########################################|
reading /usr/share/mecab/dic/ipadic/matrix.def ... 1316x1316
emitting matrix : 100% |###########################################| done!
update-alternatives: using /var/lib/mecab/dic/ipadic to provide /var/lib/mecab/dic/debian (mecab-dictionary) in auto mode
Setting up mysql-server-core-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Setting up mecab-ipadic-utf8 (2.7.0-20070801+main-2.1) ...
Compiling IPA dictionary for Mecab. This takes long time...
reading /usr/share/mecab/dic/ipadic/unk.def ... 40
emitting double-array: 100% |###########################################|
/usr/share/mecab/dic/ipadic/model.def is not found. skipped.
reading /usr/share/mecab/dic/ipadic/Noun.demonst.csv ... 120
reading /usr/share/mecab/dic/ipadic/Postp-col.csv ... 91
reading /usr/share/mecab/dic/ipadic/Noun.number.csv ... 42
reading /usr/share/mecab/dic/ipadic/Adj.csv ... 27210
reading /usr/share/mecab/dic/ipadic/Postp.csv ... 146
reading /usr/share/mecab/dic/ipadic/Noun.proper.csv ... 27328
reading /usr/share/mecab/dic/ipadic/Conjunction.csv ... 171
reading /usr/share/mecab/dic/ipadic/Auxil.csv ... 199
reading /usr/share/mecab/dic/ipadic/Adverb.csv ... 3032
reading /usr/share/mecab/dic/ipadic/Noun.others.csv ... 151
reading /usr/share/mecab/dic/ipadic/Suffix.csv ... 1393
reading /usr/share/mecab/dic/ipadic/Adnominal.csv ... 135
reading /usr/share/mecab/dic/ipadic/Filler.csv ... 19
reading /usr/share/mecab/dic/ipadic/Noun.place.csv ... 72999
reading /usr/share/mecab/dic/ipadic/Prefix.csv ... 221
reading /usr/share/mecab/dic/ipadic/Symbol.csv ... 208
reading /usr/share/mecab/dic/ipadic/Noun.adverbal.csv ... 795
reading /usr/share/mecab/dic/ipadic/Others.csv ... 2
reading /usr/share/mecab/dic/ipadic/Noun.name.csv ... 34202
reading /usr/share/mecab/dic/ipadic/Noun.adjv.csv ... 3328
reading /usr/share/mecab/dic/ipadic/Interjection.csv ... 252
reading /usr/share/mecab/dic/ipadic/Noun.org.csv ... 16668
reading /usr/share/mecab/dic/ipadic/Verb.csv ... 130750
reading /usr/share/mecab/dic/ipadic/Noun.nai.csv ... 42
reading /usr/share/mecab/dic/ipadic/Noun.verbal.csv ... 12146
reading /usr/share/mecab/dic/ipadic/Noun.csv ... 60477
emitting double-array: 100% |###########################################|
reading /usr/share/mecab/dic/ipadic/matrix.def ... 1316x1316
emitting matrix : 100% |###########################################| done!
update-alternatives: using /var/lib/mecab/dic/ipadic-utf8 to provide /var/lib/mecab/dic/debian (mecab-dictionary) in auto mode
Setting up libhtml-parser-perl (3.72-5) ...
Setting up libhttp-message-perl (6.22-1) ...
Setting up mysql-server-8.0 (8.0.34-0ubuntu0.20.04.1) ...
update-alternatives: using /etc/mysql/mysql.cnf to provide /etc/mysql/my.cnf (my.cnf) in auto mode
Renaming removed key_buffer and myisam-recover options (if present)
mysqld will log errors to /var/log/mysql/error.log
mysqld is running as pid 19288
Created symlink /etc/systemd/system/multi-user.target.wants/mysql.service → /lib/systemd/system/mysql.service.
insserv: warning: script 'S03denyhosts' missing LSB tags and overrides
insserv: warning: script 'denyhosts' missing LSB tags and overrides
Setting up libcgi-pm-perl (4.46-1) ...
Setting up libhtml-template-perl (2.97-1) ...
Setting up mysql-server (8.0.34-0ubuntu0.20.04.1) ...
Setting up libcgi-fast-perl (1:2.15-1) ...
Processing triggers for systemd (245.4-4ubuntu3.5) ...
Processing triggers for man-db (2.9.1-1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.2) ...
root@myw:~#
从执行指令安装的这些信息来看 默认安装mysql后 默认是启动的,看这条信息
mysqld will log errors to /var/log/mysql/error.log
mysqld is running as pid 19288
这是一条很欣喜的是消息,首先来确认下mysql的版本 8.0.x
root@myw:~# mysql -V
mysql Ver 8.0.34-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu))
root@myw:~# mysql --version
mysql Ver 8.0.34-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu))
root@myw:~#
确认下mysql是否启动 在这里使用指令发现缺少工具,那么使用apt安装一下便可以
root@myw:~# netstat -lnp|grep 3306Command 'netstat' not found, but can be installed with:apt install net-toolsroot@myw:~#
执行
root@myw:~# apt-get install net-tools
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:net-tools
0 upgraded, 1 newly installed, 0 to remove and 271 not upgraded.
Need to get 196 kB of archives.
After this operation, 864 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu focal/main amd64 net-tools amd64 1.60+git20180626.aebd88e-1ubuntu1 [196 kB]
Fetched 196 kB in 2s (110 kB/s)
Selecting previously unselected package net-tools.
(Reading database ... 72727 files and directories currently installed.)
Preparing to unpack .../net-tools_1.60+git20180626.aebd88e-1ubuntu1_amd64.deb ...
Unpacking net-tools (1.60+git20180626.aebd88e-1ubuntu1) ...
Setting up net-tools (1.60+git20180626.aebd88e-1ubuntu1) ...
Processing triggers for man-db (2.9.1-1) ...
root@myw:~#
确认mysql是否运行
root@myw:~# netstat -lnp|grep 3306
tcp 0 0 127.0.0.1:33060 0.0.0.0:* LISTEN 19601/mysqld
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 19601/mysqld
root@myw:~# netstat -lnp|grep mysql
tcp 0 0 127.0.0.1:33060 0.0.0.0:* LISTEN 19601/mysqld
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 19601/mysqld
unix 2 [ ACC ] STREAM LISTENING 163194 19601/mysqld /var/run/mysqld/mysqlx.sock
unix 2 [ ACC ] STREAM LISTENING 162394 19601/mysqld /var/run/mysqld/mysqld.sock
root@myw:~# netstat -lnp|grep mysqld
tcp 0 0 127.0.0.1:33060 0.0.0.0:* LISTEN 19601/mysqld
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 19601/mysqld
unix 2 [ ACC ] STREAM LISTENING 163194 19601/mysqld /var/run/mysqld/mysqlx.sock
unix 2 [ ACC ] STREAM LISTENING 162394 19601/mysqld /var/run/mysqld/mysqld.sock
root@myw:~#
进入mysql内可以直接使用mysql指令进去,不需要密码
root@myw:~# mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 8.0.34-0ubuntu0.20.04.1 (Ubuntu)Copyright (c) 2000, 2023, Oracle and/or its affiliates.Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql> \s
--------------
mysql Ver 8.0.34-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu))Connection id: 8
Current database:
Current user: root@localhost
SSL: Not in use
Current pager: stdout
Using outfile: ''
Using delimiter: ;
Server version: 8.0.34-0ubuntu0.20.04.1 (Ubuntu)
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: utf8mb4
Db characterset: utf8mb4
Client characterset: utf8mb4
Conn. characterset: utf8mb4
UNIX socket: /var/run/mysqld/mysqld.sock
Binary data as: Hexadecimal
Uptime: 4 min 33 secThreads: 2 Questions: 5 Slow queries: 0 Opens: 119 Flush tables: 3 Open tables: 38 Queries per second avg: 0.018
--------------mysql>
也可以使用root来登录 root用户不需要输入密码的
root@myw:~# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 8.0.34-0ubuntu0.20.04.1 (Ubuntu)Copyright (c) 2000, 2023, Oracle and/or its affiliates.Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql>
查看mysql内的用户信息,发现其中有一条数据User是debian-sys-maint 这条直接删掉
mysql> use mysql
Database changed
mysql> select Host, User, plugin, authentication_string, password_lifetime from user;
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+
| Host | User | plugin | authentication_string | password_lifetime |
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+
| localhost | debian-sys-maint | caching_sha2_password | $A$005$
^2lO) KVuHJ5LuXU8r1FPmt5.KJA.LCBgue/SrC42rvBmqDmSv3 | NULL |
| localhost | mysql.infoschema | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL |
| localhost | mysql.session | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL |
| localhost | mysql.sys | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL |
| localhost | root | auth_socket | | NULL |
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+
5 rows in set (0.01 sec)mysql> delete from user where user='debian-sys-maint';
Query OK, 1 row affected (0.00 sec)mysql> select host,user,plugin,authentication_string, password_lifetime from user;
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+
| host | user | plugin | authentication_string | password_lifetime |
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+
| localhost | mysql.infoschema | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL |
| localhost | mysql.session | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL |
| localhost | mysql.sys | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL |
| localhost | root | auth_socket | | NULL |
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+
4 rows in set (0.00 sec)mysql>
数据库执行初始化
安装好mysql数据库后,本身就可以使用了,也可以执行一次初始化(在数据库运行时才能执行)
mysql_secure_installation
是否启用密码有效验证插件
root@myw:~# mysql_secure_installationSecuring the MySQL server deployment.Connecting to MySQL using a blank password.VALIDATE PASSWORD COMPONENT can be used to test passwords
and improve security. It checks the strength of password
and allows the users to set only those passwords which are
secure enough. Would you like to setup VALIDATE PASSWORD component?// 是否启用密码有效验证插件 必须选择是 y
Press y|Y for Yes, any other key for No: y
设置密码强度复杂度
There are three levels of password validation policy:LOW Length >= 8
MEDIUM Length >= 8, numeric, mixed case, and special characters
STRONG Length >= 8, numeric, mixed case, special characters and dictionary file// 设置密码强度复杂度 中级 八位 数字 大小写字母 特殊字符
Please enter 0 = LOW, 1 = MEDIUM and 2 = STRONG: 1
移除匿名用户
Skipping password set for root as authentication with auth_socket is used by default.
If you would like to use password authentication instead, this can be done with the "ALTER_USER" command.
See https://dev.mysql.com/doc/refman/8.0/en/alter-user.html#alter-user-password-management for more information.By default, a MySQL installation has an anonymous user,
allowing anyone to log into MySQL without having to have
a user account created for them. This is intended only for
testing, and to make the installation go a bit smoother.
You should remove them before moving into a production
environment.// 移除匿名用户
Remove anonymous users? (Press y|Y for Yes, any other key for No) : y
Success.
是否允许远程登录
Normally, root should only be allowed to connect from
'localhost'. This ensures that someone cannot guess at
the root password from the network.
// 是否允许远程登录
Disallow root login remotely? (Press y|Y for Yes, any other key for No) : n
删除测试数据库
... skipping.
By default, MySQL comes with a database named 'test' that
anyone can access. This is also intended only for testing,
and should be removed before moving into a production
environment.// 删除测试数据库
Remove test database and access to it? (Press y|Y for Yes, any other key for No) : y- Dropping test database...
Success.- Removing privileges on test database...
Success.
重新刷新权限
Reloading the privilege tables will ensure that all changes
made so far will take effect immediately.
重新刷新权限
Reload privilege tables now? (Press y|Y for Yes, any other key for No) : y
Success.All done!
root@myw:~#
mysql数据安装好 默认加入了开机启动的 因此也不需要担心服务器重启
mysql 常用的 开 关 重启 取消开机启动指令
// 启动
systemctl start mysql// 重启
systemctl restart mysql// 停止
systemctl stop mysql// 查看启动状态
systemctl status mysql// 加入开机启动
systemctl enable mysql// 取消开机启动
systemctl disable mysql
通过创建一个数据库方式 再去找这个数据库的名字就能找到mysql默认存数据的位置
在centos系统中/etc/my.cnf里配置mysql的参数 但是在Ubuntu系统有些不同,在Ubuntu系统的/etc下面是找不到my.cnf配置文件的,但是可以找到一个mysql的文件夹
打开my.cnf文件 里面的内容如下 mysql.cnf里也差不多的
一般情况下配置编码 但在mysql8里默认编码就可以utf8mb4,所以其他参数在简单应用里不需要调整的,有一个点需要注意,mysql8默认是打开了binlog日志存储的,如果稍微数据量大,那么会产生大量的日志文件(在/var/lib/mysql下面存在,binlog.index, binlog.0000xx这类很大的文件),云服务器的云盘太少,很容易爆满的,因此一般应用需要把它关掉
可以先去查看
mysql> SHOW VARIABLES LIKE 'log_bin';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| log_bin | ON |
+---------------+-------+
1 row in set (0.00 sec)mysql>
ON是开启的,关掉需要配置
先找到mysqld.cnf文件
打开后的文件内容
#
# The MySQL database server configuration file.
#
# One can use all long options that the program supports.
# Run program with --help to get a list of available options and with
# --print-defaults to see which it would actually understand and use.
#
# For explanations see
# http://dev.mysql.com/doc/mysql/en/server-system-variables.html# Here is entries for some specific programs
# The following values assume you have at least 32M ram[mysqld]
#
# * Basic Settings
#
user = mysql
# pid-file = /var/run/mysqld/mysqld.pid
# socket = /var/run/mysqld/mysqld.sock
# port = 3306
# datadir = /var/lib/mysql# If MySQL is running as a replication slave, this should be
# changed. Ref https://dev.mysql.com/doc/refman/8.0/en/server-system-variables.html#sysvar_tmpdir
# tmpdir = /tmp
#
# Instead of skip-networking the default is now to listen only on
# localhost which is more compatible and is not less secure.
bind-address = 127.0.0.1
mysqlx-bind-address = 127.0.0.1
#
# * Fine Tuning
#
key_buffer_size = 16M
# max_allowed_packet = 64M
# thread_stack = 256K# thread_cache_size = -1# This replaces the startup script and checks MyISAM tables if needed
# the first time they are touched
myisam-recover-options = BACKUP# max_connections = 151# table_open_cache = 4000#
# * Logging and Replication
#
# Both location gets rotated by the cronjob.
#
# Log all queries
# Be aware that this log type is a performance killer.
# general_log_file = /var/log/mysql/query.log
# general_log = 1
#
# Error log - should be very few entries.
#
log_error = /var/log/mysql/error.log
#
# Here you can see queries with especially long duration
# slow_query_log = 1
# slow_query_log_file = /var/log/mysql/mysql-slow.log
# long_query_time = 2
# log-queries-not-using-indexes
#
# The following can be used as easy to replay backup logs or for replication.
# note: if you are setting up a replication slave, see README.Debian about
# other settings you may need to change.
# server-id = 1
# log_bin = /var/log/mysql/mysql-bin.log
# binlog_expire_logs_seconds = 2592000
max_binlog_size = 100M
# binlog_do_db = include_database_name
# binlog_ignore_db = include_database_name
在这个文件的末尾加上配置
disable-log-bin
或者
skip-log-bin
再执行指令
mysql> SHOW VARIABLES LIKE 'log_bin';
+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| log_bin | OFF |
+---------------+-------+
1 row in set (0.00 sec)mysql>
可以看到biglog已经关掉了
在查询指令可以看到更多信息
show variables like "%bin%";
mysql> show variables like "%bin%";
+------------------------------------------------+----------------------+
| Variable_name | Value |
+------------------------------------------------+----------------------+
| bind_address | 127.0.0.1 |
| binlog_cache_size | 32768 |
| binlog_checksum | CRC32 |
| binlog_direct_non_transactional_updates | OFF |
| binlog_encryption | OFF |
| binlog_error_action | ABORT_SERVER |
| binlog_expire_logs_auto_purge | ON |
| binlog_expire_logs_seconds | 2592000 |
| binlog_format | ROW |
| binlog_group_commit_sync_delay | 0 |
| binlog_group_commit_sync_no_delay_count | 0 |
| binlog_gtid_simple_recovery | ON |
| binlog_max_flush_queue_time | 0 |
| binlog_order_commits | ON |
| binlog_rotate_encryption_master_key_at_startup | OFF |
| binlog_row_event_max_size | 8192 |
| binlog_row_image | FULL |
| binlog_row_metadata | MINIMAL |
| binlog_row_value_options | |
| binlog_rows_query_log_events | OFF |
| binlog_stmt_cache_size | 32768 |
| binlog_transaction_compression | OFF |
| binlog_transaction_compression_level_zstd | 3 |
| binlog_transaction_dependency_history_size | 25000 |
| binlog_transaction_dependency_tracking | COMMIT_ORDER |
| innodb_api_enable_binlog | OFF |
| log_bin | OFF |
| log_bin_basename | |
| log_bin_index | |
| log_bin_trust_function_creators | OFF |
| log_bin_use_v1_row_events | OFF |
| log_statements_unsafe_for_binlog | ON |
| max_binlog_cache_size | 18446744073709547520 |
| max_binlog_size | 104857600 |
| max_binlog_stmt_cache_size | 18446744073709547520 |
| mysqlx_bind_address | 127.0.0.1 |
| sql_log_bin | ON |
| sync_binlog | 1 |
+------------------------------------------------+----------------------+
38 rows in set (0.00 sec)mysql>
远程路由连接mysql
mysql安装在云端 要在本地通过一些远程连接工具来连接云端的mysql 需要创建能够远程连接的账号
mysql> CREATE USER 'myroot'@'%' IDENTIFIED BY 'myW.123456';
Query OK, 0 rows affected (0.01 sec)mysql> GRANT ALL ON *.* TO 'myroot'@'%';
Query OK, 0 rows affected (0.00 sec)
mysql> use mysql
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -ADatabase changed
mysql> select Host, User, plugin, authentication_string, password_lifetime, password_last_changed from user;
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+-----------------------+
| Host | User | plugin | authentication_string | password_lifetime | password_last_changed |
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+-----------------------+
| % | myroot | caching_sha2_password | $A$005$^`=S'1HhJ|hR/^,9,iVqqzJ3IKSfy7BMFtllgWqDvbSm5U76E84OVTJXWQZUtF. | NULL | 2023-09-21 14:18:21 |
| localhost | mysql.infoschema | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL | 2023-09-21 12:40:28 |
| localhost | mysql.session | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL | 2023-09-21 12:40:28 |
| localhost | mysql.sys | caching_sha2_password | $A$005$THISISACOMBINATIONOFINVALIDSALTANDPASSWORDTHATMUSTNEVERBRBEUSED | NULL | 2023-09-21 12:40:28 |
| localhost | root | auth_socket | | NULL | 2023-09-21 12:40:28 |
+-----------+------------------+-----------------------+------------------------------------------------------------------------+-------------------+-----------------------+
5 rows in set (0.00 sec)mysql>
可以看到我在这里创建了一个myroot用户 密码是myW.123456 是满足远程连接的
使用navicat(15版本以上支持mysql8的效果更好)
可以看到连接不上,
在centos下安装的mysql8 只要账号满足就可以自我本地电脑远程连接,但是在Ubuntu下还需要改刚才的那个配置文件
目录下面
/etc/mysql/mysql.conf.d/mysqld.cnf
将
bind-address = 127.0.0.1
改成
bind-address = 0.0.0.0
修改后必须重启mysql 不重启不生效的
然后访问
再来看在Ubuntu系统里关于mysql的信息和路径
root@myw:~# whereis mysql
mysql: /usr/bin/mysql /usr/lib/mysql /etc/mysql /usr/share/mysql /usr/share/man/man1/mysql.1.gz
root@myw:~# find / -name 'mysql*'
/etc/init/mysql.conf
/etc/logrotate.d/mysql-server
/etc/apparmor.d/abstractions/mysql
/etc/mysql
/etc/mysql/mysql.cnf
/etc/mysql/conf.d/mysql.cnf
/etc/mysql/conf.d/mysqldump.cnf
/etc/mysql/mysql.conf.d
/etc/mysql/mysql.conf.d/mysql.cnf
/etc/mysql/mysql.conf.d/mysqld.cnf
/etc/init.d/mysql
/etc/logcheck/ignore.d.workstation/mysql-server-8_0
/etc/logcheck/ignore.d.server/mysql-server-8_0
/etc/logcheck/ignore.d.paranoid/mysql-server-8_0
/etc/systemd/system/multi-user.target.wants/mysql.service
/usr/bin/mysqlpump
/usr/bin/mysqld_multi
/usr/bin/mysql_migrate_keyring
/usr/bin/mysqlshow
/usr/bin/mysqloptimize
/usr/bin/mysql_ssl_rsa_setup
/usr/bin/mysqlslap
/usr/bin/mysql_config_editor
/usr/bin/mysqlreport
/usr/bin/mysqldump
/usr/bin/mysqladmin
/usr/bin/mysql_tzinfo_to_sql
/usr/bin/mysqlimport
/usr/bin/mysqlrepair
/usr/bin/mysqld_safe
/usr/bin/mysqlanalyze
/usr/bin/mysqldumpslow
/usr/bin/mysql_upgrade
/usr/bin/mysql
/usr/bin/mysqlbinlog
/usr/bin/mysql_secure_installation
/usr/bin/mysqlcheck
/usr/sbin/mysqld
/usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/mysql.cpython-38.pyc
/usr/lib/python3/dist-packages/sos/report/plugins/mysql.py
/usr/lib/mysql
/usr/lib/mysql/plugin/mysql_no_login.so
/usr/lib/mysql/plugin/mysql_clone.so
/usr/lib/systemd/system/mysql.service
/usr/share/lintian/overrides/mysql-client-8.0
/usr/share/lintian/overrides/mysql-common
/usr/share/lintian/overrides/mysql-server-8.0
/usr/share/mysql-common
/usr/share/bash-completion/completions/mysqladmin
/usr/share/bash-completion/completions/mysql
/usr/share/vim/vim81/syntax/mysql.vim
/usr/share/man/man1/mysqlrepair.1.gz
/usr/share/man/man1/mysqladmin.1.gz
/usr/share/man/man1/mysqldumpslow.1.gz
/usr/share/man/man1/mysqloptimize.1.gz
/usr/share/man/man1/mysql.1.gz
/usr/share/man/man1/mysqlbinlog.1.gz
/usr/share/man/man1/mysqlreport.1.gz
/usr/share/man/man1/mysqldump.1.gz
/usr/share/man/man1/mysql_upgrade.1.gz
/usr/share/man/man1/mysql_tzinfo_to_sql.1.gz
/usr/share/man/man1/mysqlanalyze.1.gz
/usr/share/man/man1/mysql_config_editor.1.gz
/usr/share/man/man1/mysqlman.1.gz
/usr/share/man/man1/mysqlpump.1.gz
/usr/share/man/man1/mysqlshow.1.gz
/usr/share/man/man1/mysqld_multi.1.gz
/usr/share/man/man1/mysqld_safe.1.gz
/usr/share/man/man1/mysqlimport.1.gz
/usr/share/man/man1/mysql_ssl_rsa_setup.1.gz
/usr/share/man/man1/mysql_secure_installation.1.gz
/usr/share/man/man1/mysqlslap.1.gz
/usr/share/man/man1/mysqlcheck.1.gz
/usr/share/man/man8/mysqld.8.gz
/usr/share/mysql
/usr/share/mysql/mysqld_multi.server
/usr/share/mysql/mysql-log-rotate
/usr/share/mysql/mysql-systemd-start
/usr/share/doc/mysql-client-8.0
/usr/share/doc/mysql-common
/usr/share/doc/mysql-server-8.0
/usr/share/doc/mysql-server-8.0/mysqld.sym.gz
/usr/share/doc/mysql-client-core-8.0
/usr/share/doc/mysql-server-core-8.0
/usr/share/doc/mysql-server
/run/mysqld
/run/mysqld/mysqld.sock
/run/mysqld/mysqld.sock.lock
/run/mysqld/mysqlx.sock
/run/mysqld/mysqlx.sock.lock
/var/log/mysql
/var/cache/apt/archives/mysql-server-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-server-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-server_8.0.34-0ubuntu0.20.04.1_all.deb
/var/cache/apt/archives/mysql-client-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-common_5.8+1.0.5ubuntu2_all.deb
/var/cache/apt/archives/mysql-client-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/lib/mysql-keyring
/var/lib/dpkg/info/mysql-server.list
/var/lib/dpkg/info/mysql-server-8.0.prerm
/var/lib/dpkg/info/mysql-common.preinst
/var/lib/dpkg/info/mysql-common.conffiles
/var/lib/dpkg/info/mysql-common.postinst
/var/lib/dpkg/info/mysql-common.list
/var/lib/dpkg/info/mysql-common.md5sums
/var/lib/dpkg/info/mysql-server-8.0.postrm
/var/lib/dpkg/info/mysql-common.prerm
/var/lib/dpkg/info/mysql-server-8.0.templates
/var/lib/dpkg/info/mysql-client-8.0.list
/var/lib/dpkg/info/mysql-client-core-8.0.md5sums
/var/lib/dpkg/info/mysql-server.md5sums
/var/lib/dpkg/info/mysql-server-8.0.preinst
/var/lib/dpkg/info/mysql-server-8.0.postinst
/var/lib/dpkg/info/mysql-server-8.0.conffiles
/var/lib/dpkg/info/mysql-server-8.0.md5sums
/var/lib/dpkg/info/mysql-server-8.0.list
/var/lib/dpkg/info/mysql-server-core-8.0.triggers
/var/lib/dpkg/info/mysql-server-8.0.config
/var/lib/dpkg/info/mysql-client-core-8.0.list
/var/lib/dpkg/info/mysql-server-core-8.0.md5sums
/var/lib/dpkg/info/mysql-client-8.0.md5sums
/var/lib/dpkg/info/mysql-server-core-8.0.list
/var/lib/dpkg/info/mysql-common.postrm
/var/lib/dpkg/info/mysql-server-core-8.0.shlibs
/var/lib/mysql-upgrade
/var/lib/mysql
/var/lib/mysql/mysql.ibd
/var/lib/mysql/mysql
/var/lib/mysql-files
/var/lib/systemd/deb-systemd-helper-enabled/multi-user.target.wants/mysql.service
/var/lib/systemd/deb-systemd-helper-enabled/mysql.service.dsh-also
/sys/fs/cgroup/pids/system.slice/mysql.service
/sys/fs/cgroup/devices/system.slice/mysql.service
/sys/fs/cgroup/memory/system.slice/mysql.service
/sys/fs/cgroup/systemd/system.slice/mysql.service
/sys/fs/cgroup/unified/system.slice/mysql.service
root@myw:~#
卸载mysql
首先查看mysql的依赖项
dpkg --list|grep mysql
root@myw:~# dpkg --list|grep mysql
ii mysql-client-8.0 8.0.34-0ubuntu0.20.04.1 amd64 MySQL database client binaries
ii mysql-client-core-8.0 8.0.34-0ubuntu0.20.04.1 amd64 MySQL database core client binaries
ii mysql-common 5.8+1.0.5ubuntu2 all MySQL database common files, e.g. /etc/mysql/my.cnf
ii mysql-server 8.0.34-0ubuntu0.20.04.1 all MySQL database server (metapackage depending on the latest version)
ii mysql-server-8.0 8.0.34-0ubuntu0.20.04.1 amd64 MySQL database server binaries and system database setup
ii mysql-server-core-8.0 8.0.34-0ubuntu0.20.04.1 amd64 MySQL database server binaries
root@myw:~#
卸载
apt-get autoremove mysql* --purge
root@myw:~# apt-get autoremove mysql* --purge
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'mysql-source-8.0' for glob 'mysql*'
Note, selecting 'mysqltcl' for glob 'mysql*'
Note, selecting 'mysql-client-5.5' for glob 'mysql*'
Note, selecting 'mysql-client-5.6' for glob 'mysql*'
Note, selecting 'mysql-client-5.7' for glob 'mysql*'
Note, selecting 'mysql-common-5.6' for glob 'mysql*'
Note, selecting 'mysql-server-5.5' for glob 'mysql*'
Note, selecting 'mysql-server-5.6' for glob 'mysql*'
Note, selecting 'mysql-server-5.7' for glob 'mysql*'
Note, selecting 'mysql-client-8.0' for glob 'mysql*'
Note, selecting 'mysql-testsuite' for glob 'mysql*'
Note, selecting 'mysql-server' for glob 'mysql*'
Note, selecting 'mysql-router' for glob 'mysql*'
Note, selecting 'mysql-server-8.0' for glob 'mysql*'
Note, selecting 'mysql-client' for glob 'mysql*'
Note, selecting 'mysql-sandbox' for glob 'mysql*'
Note, selecting 'mysql-client-core-5.5' for glob 'mysql*'
Note, selecting 'mysql-client-core-5.6' for glob 'mysql*'
Note, selecting 'mysql-client-core-5.7' for glob 'mysql*'
Note, selecting 'mysql-client-core-8.0' for glob 'mysql*'
Note, selecting 'mysql-testsuite-5.5' for glob 'mysql*'
Note, selecting 'mysql-testsuite-5.6' for glob 'mysql*'
Note, selecting 'mysql-testsuite-5.7' for glob 'mysql*'
Note, selecting 'mysql-common' for glob 'mysql*'
Note, selecting 'mysql-testsuite-8.0' for glob 'mysql*'
Note, selecting 'mysqltuner' for glob 'mysql*'
Note, selecting 'mysql-server-core-5.5' for glob 'mysql*'
Note, selecting 'mysql-server-core-5.6' for glob 'mysql*'
Note, selecting 'mysql-server-core-5.7' for glob 'mysql*'
Note, selecting 'mysql-server-core-8.0' for glob 'mysql*'
Package 'mysql-client-5.7' is not installed, so not removed
Package 'mysql-client-core-5.7' is not installed, so not removed
Note, selecting 'mysql-common' instead of 'mysql-common-5.6'
Package 'mysql-server-5.5' is not installed, so not removed
Package 'mysql-server-5.7' is not installed, so not removed
Package 'mysql-server-core-5.7' is not installed, so not removed
Package 'mysql-client-core-5.5' is not installed, so not removed
Package 'mysql-client-core-5.6' is not installed, so not removed
Package 'mysql-client-5.5' is not installed, so not removed
Package 'mysql-client-5.6' is not installed, so not removed
Package 'mysql-server-core-5.5' is not installed, so not removed
Package 'mysql-server-core-5.6' is not installed, so not removed
Package 'mysql-server-5.6' is not installed, so not removed
Package 'mysql-testsuite-5.5' is not installed, so not removed
Package 'mysql-testsuite-5.6' is not installed, so not removed
Package 'mysql-testsuite-5.7' is not installed, so not removed
Package 'mysql-sandbox' is not installed, so not removed
Package 'mysqltcl' is not installed, so not removed
Package 'mysqltuner' is not installed, so not removed
Package 'mysql-client' is not installed, so not removed
Package 'mysql-router' is not installed, so not removed
Package 'mysql-source-8.0' is not installed, so not removed
Package 'mysql-testsuite' is not installed, so not removed
Package 'mysql-testsuite-8.0' is not installed, so not removed
The following packages will be REMOVED:libcgi-fast-perl* libcgi-pm-perl* libencode-locale-perl* libevent-core-2.1-7* libevent-pthreads-2.1-7* libfcgi-perl* libhtml-parser-perl* libhtml-tagset-perl* libhtml-template-perl* libhttp-date-perl* libhttp-message-perl* libio-html-perl*liblwp-mediatypes-perl* libmecab2* libtimedate-perl* liburi-perl* mecab-ipadic* mecab-ipadic-utf8* mecab-utils* mysql-client-8.0* mysql-client-core-8.0* mysql-common* mysql-server* mysql-server-8.0* mysql-server-core-8.0*
0 upgraded, 0 newly installed, 25 to remove and 271 not upgraded.
After this operation, 318 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 72776 files and directories currently installed.)
Removing libcgi-fast-perl (1:2.15-1) ...
Removing libhtml-template-perl (2.97-1) ...
Removing libcgi-pm-perl (4.46-1) ...
Removing libhttp-message-perl (6.22-1) ...
Removing libencode-locale-perl (1.05-1) ...
Removing mysql-server (8.0.34-0ubuntu0.20.04.1) ...
Removing mysql-server-8.0 (8.0.34-0ubuntu0.20.04.1) ...
update-alternatives: using /etc/mysql/my.cnf.fallback to provide /etc/mysql/my.cnf (my.cnf) in auto mode
Removing mysql-server-core-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Removing libevent-pthreads-2.1-7:amd64 (2.1.11-stable-1) ...
Removing libevent-core-2.1-7:amd64 (2.1.11-stable-1) ...
Removing libfcgi-perl (0.79-1) ...
Removing libhtml-parser-perl (3.72-5) ...
Removing libhtml-tagset-perl (3.20-4) ...
Removing libhttp-date-perl (6.05-1) ...
Removing libio-html-perl (1.001-1) ...
Removing liblwp-mediatypes-perl (6.04-1) ...
Removing mecab-ipadic-utf8 (2.7.0-20070801+main-2.1) ...
update-alternatives: using /var/lib/mecab/dic/ipadic to provide /var/lib/mecab/dic/debian (mecab-dictionary) in auto mode
Removing mecab-ipadic (2.7.0-20070801+main-2.1) ...
Removing mecab-utils (0.996-10build1) ...
Removing libmecab2:amd64 (0.996-10build1) ...
Removing libtimedate-perl (2.3200-1) ...
Removing liburi-perl (1.76-2) ...
Removing mysql-client-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Removing mysql-client-core-8.0 (8.0.34-0ubuntu0.20.04.1) ...
Removing mysql-common (5.8+1.0.5ubuntu2) ...
Processing triggers for man-db (2.9.1-1) ...
Processing triggers for libc-bin (2.31-0ubuntu9.2) ...
(Reading database ... 72215 files and directories currently installed.)
Purging configuration files for mysql-server-8.0 (8.0.34-0ubuntu0.20.04.1) ...
insserv: warning: script 'S03denyhosts' missing LSB tags and overrides
insserv: warning: script 'denyhosts' missing LSB tags and overrides
Purging configuration files for libmecab2:amd64 (0.996-10build1) ...
Purging configuration files for mysql-common (5.8+1.0.5ubuntu2) ...
dpkg: warning: while removing mysql-common, directory '/etc/mysql' not empty so not removed
Processing triggers for systemd (245.4-4ubuntu3.5) ...
root@myw:~# dpkg --list|grep mysql
root@myw:~#
可以看到mysql的依赖项都卸载了,在查询有没有mysql
root@myw:~# whereis mysql
mysql: /etc/mysql
root@myw:~#
可以看到配置文件夹还在 删除配置文件夹
root@myw:~# rm -rf /etc/mysql
root@myw:~# whereis mysql
mysql:
root@myw:~#
再看
root@myw:~# find / -name 'mysql*'
/etc/apparmor.d/abstractions/mysql
/usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/mysql.cpython-38.pyc
/usr/lib/python3/dist-packages/sos/report/plugins/mysql.py
/usr/share/bash-completion/completions/mysqladmin
/usr/share/bash-completion/completions/mysql
/usr/share/vim/vim81/syntax/mysql.vim
/var/cache/apt/archives/mysql-server-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-server-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-server_8.0.34-0ubuntu0.20.04.1_all.deb
/var/cache/apt/archives/mysql-client-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-common_5.8+1.0.5ubuntu2_all.deb
/var/cache/apt/archives/mysql-client-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/lib/mysql-keyring
/var/lib/mysql
/var/lib/mysql/mysql.ibd
/var/lib/mysql/mysql
/var/lib/mysql-files
root@myw:~#
mysql虽然卸载了但是他的配置信息依旧是保留着的 刚刚删了/etc/mysql的配置文件夹 现在来看mysql的存储数据的地方/var/lib/mysql***
这里面的文件就是mysql原有的数据信息,一般我们都是备份后才卸载mysql的,所以这里面的文件没用了需要删掉
root@myw:~# rm -rf /var/lib/mysql
root@myw:~# rm -rf /var/lib/mysql-keyring
root@myw:~# rm -rf /var/lib/mysql-files
root@myw:~# find / -name 'mysql*'
/etc/apparmor.d/abstractions/mysql
/usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/mysql.cpython-38.pyc
/usr/lib/python3/dist-packages/sos/report/plugins/mysql.py
/usr/share/bash-completion/completions/mysqladmin
/usr/share/bash-completion/completions/mysql
/usr/share/vim/vim81/syntax/mysql.vim
/var/cache/apt/archives/mysql-server-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-server-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-server_8.0.34-0ubuntu0.20.04.1_all.deb
/var/cache/apt/archives/mysql-client-core-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
/var/cache/apt/archives/mysql-common_5.8+1.0.5ubuntu2_all.deb
/var/cache/apt/archives/mysql-client-8.0_8.0.34-0ubuntu0.20.04.1_amd64.deb
root@myw:~#
在/var/cache/apt/archives/下关于mysql的deb文件 可以不删除 但是要改变mysql的版本 建议还是可以删除的
root@myw:~# rm -rf /var/cache/apt/archives/mysql*
root@myw:~# find / -name 'mysql*'
/etc/apparmor.d/abstractions/mysql
/usr/lib/python3/dist-packages/sos/report/plugins/__pycache__/mysql.cpython-38.pyc
/usr/lib/python3/dist-packages/sos/report/plugins/mysql.py
/usr/share/bash-completion/completions/mysqladmin
/usr/share/bash-completion/completions/mysql
/usr/share/vim/vim81/syntax/mysql.vim
root@myw:~#
如此在Ubuntu下面mysql算是卸载干净了。
在Ubuntu系统下安装mysql比在centos要稍显简单一点儿,其他安装方式遇到再记录
相关文章:
Ubuntu系统下使用apt-get安装Mysql8
记录一下在Ubuntu20.04 64位系统下面使用apt-get方式安装mysql8关系型数据库 Centos下使用yum安装Mysql8(Mysql5.7)以及常见的配置和使用 首先肯定是检查下当前Ubuntu系统是否已经安装过mysql数据库 一般拿到新的云服务器是没有安装的 rootmyw:~# whe…...
jenkins联动显示或隐藏参数
1. 添加组件 Active Choices Plug-in 如jenkins无法联网,可在以下两个地址中下载插件,然后放到/home/jenkins/.jenkins/plugin下面重启jenkins即可 Active Choices Active Choices | Jenkins plugin 2. 效果如下: sharding为空时…...
Error: Activity class {xxx.java} does not exist
git切换到不同的branch之后,报下面的错误: Error: Activity class {xxx.java} does not exist 解决方案: 首先clean 然后会删除build目录 然后点击:Invalidate Caches Android Studio重启,然后重新build即可。...
保护模式阶段测试-模拟3环0环调用
保护模式阶段测试-模拟3环0环调用 最近又复习了一下保护模式相关的内容,然后打算搞个能够把段页的大部分知识能够串联起来的测试代码 最终想到的一个项目如下: 三环部分: 0.编写一个函数读取高2g的地址内容 1.通过设备通信到0环告诉0环我新…...
Dart笔记:stream_channel 包用法
标题1 标题2 作者:李俊才 (jcLee95):https://blog.csdn.net/qq_28550263 邮箱 :291148484163.com 本文地址:https://blog.csdn.net/qq_28550263/article/details/133426961 【介绍】stream_channel是一个用…...
Java进阶必会JVM-深入浅出Java虚拟机
系列文章目录 送书第一期 《用户画像:平台构建与业务实践》 送书活动之抽奖工具的打造 《获取博客评论用户抽取幸运中奖者》 送书第二期 《Spring Cloud Alibaba核心技术与实战案例》 送书第三期 《深入浅出Java虚拟机》 文章目录 系列文章目录前言一、推荐书籍二…...
1200*B. Sorted Adjacent Differences(构造)
Problem - 1339B - Codeforces 解析: 题目要求每相邻两个值差的绝对值相等或递增。 先排序,可以想到我们先取两侧的数肯定相距最远,然后靠中心每次取两个数,这样符合题目要求。 直接遍历,先取的是答案靠后的数据&…...
恼人的TCP套接字部分发送成功场景
源起 以前就知道套接字有可能出现部分发送成功的可能,直到近段时间一个典型的使用场景触发了明确的此问题,才予以重视,比较深入地考虑解决这个问题的方案! 分析 因为TCP的流式特征,如果出现部分发送成功,…...
ROS2 中的轻量级、自动化、受控回放
一、说明 这篇文章描述了一种在 ROS2 中实现受控重播器的轻量级方法。用以测试中将现象重新播放一遍,以实现调参或故障定位的目的。所有源代码都可以在这里找到。该帖子也可在此处获得。 二、问题:不同步重播 任何曾经认真开发过 ROS2 的人都会知道这个问…...
Egg使用jwt拦截jtoken验证
安装 npm install egg-jwt注册插件 在config文件夹子下 plugin,js下 use strict;module.exports {//mysqlmysql: {enable: true,package: egg-mysql},//jwtjwt: {enable: true,package: egg-jwt} };使用中间件 在app文件下创建 middleware 文件夹 在middleware 文件下创建…...
装饰器模式详解和实现(设计模式 二)
装饰器模式(Decorator Pattern)是一种结构型设计模式,它允许你动态地将对象添加到现有对象中,以提供额外的功能,同时又不影响其他对象。 实现示例 1.定义一个接口或抽象类,表示被装饰对象的公共接口 //抽…...
面试问到MySQL模块划分与架构体系怎么办
面试问到Mysql模块划分与架构体系怎么办 文章目录 1. 应用层连接管理器(Connection Manager)安全性和权限模块(Security and Privilege Module) 2. MySQL服务器层2.1. 服务支持和工具集2.2. SQL Interface2.3. 解析器举个解析器 …...
并查集及其优化
1.并查集 #define SIZE 100 int UFSets[SIZE];void Initial(int S[]) {for (int i 0; i < SIZE; i)S[i]-1; }int Find(int S[], int x) {//查while(S[x] > 0)x S[x];return x; }void Union(int S[], int Root1, int Root2) {//并if(Root1 Root2)return;S[Root2] Roo…...
LeetCode 周赛上分之旅 #48 一道简单的树上动态规划问题
⭐️ 本文已收录到 AndroidFamily,技术和职场问题,请关注公众号 [彭旭锐] 和 BaguTree Pro 知识星球提问。 学习数据结构与算法的关键在于掌握问题背后的算法思维框架,你的思考越抽象,它能覆盖的问题域就越广,理解难度…...
mysql报错:Column Count Doesn‘t Match Value Count at Row 1
mysql中执行insert、update、delete报错:Column Count Doesnt Match Value Count at Row 1 的解决方案 通常情况:字段不匹配 如:student有id, name, age字段 -- 错误写法 INSERT INTO student VALUES(5,horse)-- 正确写法 INSERT INTO stu…...
安卓 kuaishou 设备did和egid 学习分析
did和egid注册 接口 https://gdfp.ksapisrv.com/rest/infra/gdfp/report/kuaishou/android did 是本地生成的16进制 或者 获取的 android_id public static final Random f16237a new Random(System.currentTimeMillis()); public static long m19668a() { return f1623…...
基于Vue+ELement实现增删改查案例与表单验证(附源码)
🎉🎉欢迎来到我的CSDN主页!🎉🎉 🏅我是Java方文山,一个在CSDN分享笔记的博主。📚📚 🌟推荐给大家我的专栏《ELement》。🎯🎯 …...
webpack:使用externals配置来排除打包后的某个依赖插件IgnorePlugin的使用
背景 假设,我们写了一个库并使用 webpack 打包输出 bundle,但是这个库依赖一个第三方包,比如依赖 lodash,这时候我们不想把这个库打包进 bundle 里因为体积会变大,而且我们的主项目里已经安装了这个 lodash࿰…...
2023年中国工业脱水机行业供需分析:随着自动化和智能化技术的快速发展,销量同比增长4.9%[图]
工业脱水机行业是指专门从湿润的固体物料中去除水分的设备制造和相关服务。它广泛应用于食品加工、化工、制药、纺织、环保等行业,用于去除物料中的水分,提高产品质量和降低能耗。 工业脱水机行业分类 资料来源:共研产业咨询(共研…...
[论文笔记]MacBERT
引言 今天带来MacBERT的阅读笔记。论文题目是 重新审视中文自然语言处理的预训练模型。 本篇主要是探讨中文预训练语言模型在非英文语言中的有效性,然后提出了一种简单而有效的模型,称为MacBERT,它在多个方面改进了RoBERTa,特别是采用纠错型掩码语言模型(MLM as correcti…...
AI发展目前最大挑战是什么?
影响AI成本的因素包括多个方面: 首先,AI技术的复杂性是其成本高昂的一个重要原因。AI技术需要进行大量数据处理、模型训练和优化,这需要耗费大量的计算资源和时间。同时,AI技术需要高水平的专业人才进行设计、开发和维护…...
自然语言处理NLP:LTP、SnowNLP、HanLP 常用NLP工具和库对比
文章目录 常见NLP任务常见NLP工具英文NLP工具中文NLP工具 常见NLP任务 Word Segmentation 分词 – Tokenization Stem extraction 词干提取 - Stemming Lexical reduction 词形还原 – Lemmatization Part of Speech Tagging 词性标注 – Parts of Speech Named entity rec…...
百度交易中台之内容分润结算系统架构浅析
作者 | 交易中台团队 导读 随着公司内容生态的蓬勃发展,内容产出方和流量提供方最关注的“收益结算”的工作,也就成为重中之重。本文基于内容分润结算业务为入口,介绍了实现过程中的重难点,比如千万级和百万级数据量下的技术选型和…...
【索引】常见的索引、B+树结构、什么时候需要使用索引、优化索引方法、索引主要的数据结构、聚簇索引、二级索引、创建合适的索引等重点知识汇总
目录 索引的分类 什么时候需要 / 不需要创建索引? 有什么优化索引的方法 MySQL索引主要使用的两种数据结构是什么 为什么 MySQL 采用 B 树作为索引 聚簇索引和二级索引 根据给定的表,如何创建索引比较好 索引的分类 普通索引:最基本的…...
Egg 封装接口返回信息
中间件封装 代码 const msgArr {"200":成功,"401":token失效 } module.exports (option, app) > {return async function(ctx, next) {try{//成功是返回的信息ctx.emit(code,data,msg)>{console.log(1111,code,data,msg)ctx.body {code,data:dat…...
Android AMS——创建APP进程(五)
接上一篇,在 ActivityTaskSupervisor 中会判断进程是否存在,如果进程不存在,则会创建进程,执行 startProcessAsync() 方法。如果进程存在,则执行 realStartActivityLocked() 方法。在APP 的启动时,进程是不存在的。所以我们先来分析一下进程不存在的情况。 一、创建进程…...
凉鞋的 Unity 笔记 102. 场景层次 与 GameObject 的增删改查
102. 场景层次 与 GameObject 的增删改查 在上一篇,我们完成了 Unity 引擎的 Hello world 输出,并且完成了第一个基本循环: 通过这次基本循环的完成,我们获得了一点点的 Unity 使用经验,这非常重要。 有实践经验后再…...
信息安全:网络安全审计技术原理与应用.
信息安全:网络安全审计技术原理与应用. 网络安全审计是指对网络信息系统的安全相关活动信息进行获取、记录、存储、分析和利用的工作。网络安全审计的作用在于建立“事后“安全保障措施,保存网络安全事件及行为信息,为网络安全事件分析提供线…...
嵌入式Linux应用开发-第十三章APP怎么读取按键值
嵌入式Linux应用开发-第十三章读取按键及按键驱动程序 第十三章 APP怎么读取按键值13.1 妈妈怎么知道孩子醒了13.2 APP读取按键的4种方法13.2.1 查询方式13.2.2 休眠-唤醒方式13.2.3 poll方式13.2.4 异步通知方式13.2.4.1 异步通知的原理:发信号13.2.4.2 应用程序之…...
Web 中间件怎么玩?
本次主要是聊聊关于 web 中间件, 分为如下四个方面 什么是 web 框架中间件 为什么要使用 web 中间件 如何使用及其原理 哪些场景需要使用中间件 开门见山 web 中间件是啥 Web 框架中的中间件主要指的是在 web 请求到具体路由之前或者之后,会经过一个或…...
检测网站是否被墙/活动推广方案策划
无人机其实不是个新鲜玩意儿,它早就有了,而且给社会做出了巨大的贡献。笔者小时候看《动物世界》时,就非常好奇,那种百鸟乱飞的画面是怎么拍出来的,难不成要摄影师趴到树上蹲点,等着鸟儿们一同起飞…...
汕头时时彩网站建设/市场调研怎么做
要减少移动版本号,本号,或者到“威风”站点或其他能够下载到iPhone固件的站点上下载固件,然后打开iTunes,进入到 然后按着(alt),同一时候用鼠标点击(更新button)会进入到…...
广州 日本 设计网站/百度一下你就知道百度首页
随着企业业务的需要变化,企业对网络的依赖程度也将相应增加,IT部门需要对网络进行持续的改造与优化,以适应最新的企业业务应用需求。在一系列的IT持续性改进措施中,消除因为网络缓慢所造成的“抱怨”势在必行,同时还需…...
南磨房做网站公司/网站软件下载
1.AngularJS 模板---step2: mvc(Model-View-Controller)模式在后端用的比较多,在前端也是一样的常用; 在AngularJS中,一个视图是模型通过HTML模板渲染之后的映射。这意味着,不论model什么时候发生变化,AngularJS会实时更新结合点,…...
阿里巴巴1688怎么做网站/推广网站平台
一、JDBC 1. 概念 JDBC(Java DataBase Connectivity),Java 数据库连接, Java语言操作数据库JDBC本质:其实是官方(sun公司)定义的一套操作所有关系型数据库的规则,即接口。各个数据…...
b2b电子商务网站交易流程表/百度快照怎么做
2019独角兽企业重金招聘Python工程师标准>>> 总结归纳性能调优的一般步骤 存储引擎:【链接】 I/O模型:【链接】 转载于:https://my.oschina.net/bravozu/blog/1831748...