사용 Software
제품명 |
버전 |
아키텍쳐 |
Oracle VirtualBox |
5.2.22 |
X86_64bit |
서버 정보
OS |
DB |
MEMORY |
Oracle Linux 7.5 |
MySQL 8.0.19 |
2048MB |
1.Yum 설치
Yum은 VM 네트워크 구성을 NAT로 설정하여 인터넷 접속 환경이 가능하게 한 상태에서 진행해야 합니다.
제일 간단하게 설치가 가능합니다.
1.SELINUX 끄기
아래 내용을 추가해서 SELINUX의 사용을 멈춥니다.
# vi /etc/selinux/config
SELINUX=disabled
2.MYSQL 설치
MYSQL Community Server 설치
# yum install http://repo.mysql.com/mysql80-community-release-el7-3.noarch.rpm
Loaded plugins: langpacks, ulninfo
mysql80-community-release-el7-3.noarch.rpm | 25 kB 00:00:00
Examining /var/tmp/yum-root-aMPGXq/mysql80-community-release-el7-3.noarch.rpm: mysql80-community-release-el7-3.noarch
Marking /var/tmp/yum-root-aMPGXq/mysql80-community-release-el7-3.noarch.rpm as an update to mysql80-community-release-el7-1.noarch
Resolving Dependencies
--> Running transaction check
---> Package mysql80-community-release.noarch 0:el7-1 will be updated
---> Package mysql80-community-release.noarch 0:el7-3 will be an update
--> Processing Conflict: mysql80-community-release-el7-3.noarch conflicts mysql-community-release
--> Finished Dependency Resolution
Error: mysql80-community-release conflicts with mysql-community-release-el7-5.noarch
You could try using --skip-broken to work around the problem
** Found 16 pre-existing rpmdb problem(s), 'yum check' output follows:
compat-libstdc++-33-3.2.3-72.el7.i686 is a duplicate with compat-libstdc++-33-3.2.3-69.el6.x86_64
elfutils-libelf-0.170-4.el7.i686 has missing requires of libz.so.1
glibc-2.17-222.el7.i686 has missing requires of libfreebl3.so
glibc-2.17-222.el7.i686 has missing requires of libfreebl3.so(NSSRAWHASH_3.12.3)
ksh-20120801-137.0.1.el7.x86_64 has installed conflicts pdksh: pdksh-5.2.14-8.i386
libXi-devel-1.7.9-1.el7.i686 has missing requires of pkgconfig(xfixes)
libXi-devel-1.7.9-1.el7.x86_64 has missing requires of pkgconfig(xfixes)
libaio-devel-0.3.107-10.el6.x86_64 is a duplicate with libaio-devel-0.3.105-2.x86_64
libaio-devel-0.3.107-10.el6.x86_64 has missing requires of libaio = ('0', '0.3.107', '10.el6')
libaio-devel-0.3.109-13.el7.i686 is a duplicate with libaio-devel-0.3.107-10.el6.x86_64
mysql80-community-release-el7-1.noarch has installed conflicts mysql-community-release: mysql-community-release-el7-5.noarch
unixODBC-2.3.1-11.el7.i686 is a duplicate with unixODBC-2.2.11-7.1.x86_64
unixODBC-2.3.1-11.el7.i686 has missing requires of libltdl.so.7
unixODBC-2.3.1-11.el7.i686 has missing requires of libreadline.so.6
unixODBC-devel-2.3.1-11.el7.i686 is a duplicate with unixODBC-devel-2.2.11-7.1.x86_64
zlib-devel-1.2.7-17.el7.i686 has missing requires of libz.so.1
3.MYSQL 8.0 설치
# yum install mysql-server
Loaded plugins: langpacks, ulninfo
Resolving Dependencies
--> Running transaction check
---> Package mysql-community-server.x86_64 0:8.0.19-1.el7 will be installed
--> Processing Dependency: mysql-community-client(x86-64) >= 8.0.11 for package: mysql-community-server-8.0.19-1.el7.x86_64
--> Running transaction check
---> Package mysql-community-client.x86_64 0:8.0.19-1.el7 will be installed
--> Finished Dependency Resolution
Installed size: 2.1 G
..생략
Installed:
mysql-community-server.x86_64 0:8.0.19-1.el7
Dependency Installed:
mysql-community-client.x86_64 0:8.0.19-1.el7
Complete!
4.Mysql Version 확인
# mysqladmin --version
mysqladmin Ver 8.0.19 for Linux on x86_64 (MySQL Community Server - GPL)
5.Mysql 기동 확인
# systemctl start mysqld
# systemctl stop mysqld
# systemctl status mysqld
● mysqld.service - MySQL Server
Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)
Active: active (running) since Mon 2020-02-03 10:45:30 KST; 12s ago
Docs: man:mysqld(8)
http://dev.mysql.com/doc/refman/en/using-systemd.html
Process: 5824 ExecStartPre=/usr/bin/mysqld_pre_systemd (code=exited, status=0/SUCCESS)
Main PID: 5910 (mysqld)
Status: "Server is operational"
CGroup: /system.slice/mysqld.service
└─5910 /usr/sbin/mysqld
6.초기접속 설정
Mysql 8.0은 최초 기동 후 root의 임시비밀번호가 주어지며 그것을 이용해서 login 후 비밀번호를 변경해주어야 합니다.
최초 접속
# grep 'temporary password' /var/log/mysqld.log
2020-02-03T01:45:26.186657Z 5 [Note] [MY-010454] [Server] A temporary password
i s generated for root@localhost: HjuwqolYh3+O
# mysql -u root -p
Enter password: HjuwqolYh3+O
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 8.0.19
Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved.
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> alter user 'root'@'localhost' identified by 'mysql1234';
Query OK, 0 rows affected (0.01 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)
바뀐 비번으로 재접속 시도
mysql> exit
Bye
# mysql -u root -p
Enter password: mysql1234
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 10
Server version: 8.0.19 MySQL Community Server - GPL
Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved.
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> select version();
+-----------+
| version() |
+-----------+
| 8.0.19 |
+-----------+
1 row in set (0.00 sec)
끝
'다른 DBMS > MySQL&MariaDB' 카테고리의 다른 글
시스템 변수 변경방법 (0) | 2020.12.08 |
---|---|
MYSQL설치(바이너리) (0) | 2020.12.04 |
MYSQL설치(RPM) (0) | 2020.12.03 |
Column Size 증가시 테스트 (0) | 2020.10.15 |
Galera_Cluster 구축하기 (0) | 2020.02.06 |
댓글