머리말
MariaDB의 MySQL 데이터베이스 관리 시스템은 주로 유지 보수에 오픈 소스 커뮤니티에 의해, 지점이며, GPL을 사용하는 목적은 MariaDB가 쉽게 MySQL을위한 대용품이 될 수 그래서, API 및 명령 줄을 포함하여 MySQL은,와 완벽하게 호환됩니다 라이센스. 스토리지 엔진의 측면에서, 대신 MySQL의 이노의 XtraDB를 사용합니다. 주요 MariaDB MySQL의 설립자 마이클 Widenius에 의해 개발, MariaDB 마이클 와이드 니 어스 이름은 그의 딸 마리아의 이름에서 유래
MariaDB를 설치 리눅스는
설치
MariaDB를 설치 yum을 사용하여
yum install mariadb*
설치 MariaDB 먼저 MariaDB를 시작합니다
systemctl start mariadb
설정 부팅
systemctl enable mariadb
MariaDB 다음의 관련 간단한 구성
mysql_secure_installation
첫째, 암호를 설정, 암호를 입력하라는 메시지가 표시됩니다
Enter current password for root (enter for none): #–初次运行直接回车
암호
Set root password? [Y/n] # – 是否设置root用户密码,输入y并回车或直接回车
New password: # – 输入root用户的密码
Re-enter new password: # – 再输入一次你设置的密码
다른 구성
Remove anonymous users? [Y/n] # – 是否删除匿名用户,回车
Disallow root login remotely? [Y/n] # –是否禁止root远程登录,回车
Remove test database and access to it? [Y/n] # – 是否删除test数据库,回车
Reload privilege tables now? [Y/n] # – 是否重新加载权限表,回车
MariaDB 초기화가 완료되면 다음 테스트 로그인
mysql -u root -p
Enter password:
구성
MariaDB 문자 세트 구성 파일/etc/my.cnf
vi /etc/my.cnf
에서 [mysqld]
라벨 아래에 추가
init_connect='SET collation_connection = utf8_unicode_ci'
init_connect='SET NAMES utf8'
character-set-server=utf8
collation-server=utf8_unicode_ci
skip-character-set-client-handshake
파일/etc/my.cnf.d/client.cnf
vi /etc/my.cnf.d/client.cnf
에 [client]
추가
default-character-set=utf8
파일/etc/my.cnf.d/mysql-clients.cnf
vi /etc/my.cnf.d/mysql-clients.cnf
에 [mysql]
추가
default-character-set=utf8
모든 구성이 완료되면 다시 시작 mariadb
systemctl restart mariadb
입력 한 후 MariaDB 문자 집합을 볼
mysql> show variables like "%character%";show variables like "%collation%";
로 표시
+--------------------------+----------------------------+
| Variable_name | Value |
+--------------------------+----------------------------+
| character_set_client | utf8 |
| character_set_connection | utf8 |
| character_set_database | utf8 |
| character_set_filesystem | binary |
| character_set_results | utf8 |
| character_set_server | utf8 |
| character_set_system | utf8 |
| character_sets_dir | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------+
8 rows in set (0.00 sec)
+----------------------+-----------------+
| Variable_name | Value |
+----------------------+-----------------+
| collation_connection | utf8_unicode_ci |
| collation_database | utf8_unicode_ci |
| collation_server | utf8_unicode_ci |
+----------------------+-----------------+
3 rows in set (0.00 sec)
문자 세트 구성이 완료됩니다.
추가 사용자 권한을 설정
사용자 명령 만들기
mysql>create user username@localhost identified by 'password';
직접 명령은 사용자 및 권한 부여를 만들 수 있습니다
mysql>grant all on *.* to username@localhost indentified by 'password';
네트워크 외부 부여 착륙 권리
mysql>grant all privileges on *.* to username@'%' identified by 'password';
권한 및 권한은 부여 할 수 있습니다
mysql>grant all privileges on *.* to username@'hostname' identified by 'password' with grant option;
간단한 사용자 구성과 케이스에 기본 권리.
어떤은의 일부에 대한 권한이 부여 all privileges
또는 all
변경 select,insert,update,delete,create,drop,index,alter,grant,references,reload,shutdown,process,file
의 일부.
참고
리눅스 시스템 자습서 : MariaDB 서버 버전을 확인하는 방법 http://www.linuxidc.com/Linux/2015-08/122382.htm
MariaDB 프록시 별도의 읽기 및 달성하기 위해 쓰기 http://www.linuxidc.com/Linux/2014-05/101306.htm
구성 MariaDB 데이터베이스에 리눅스 컴파일러 설치 방법 http://www.linuxidc.com/Linux/2014-11/109049.htm
냠 MariaDB 데이터베이스를 설치하여 CentOS는 시스템 http://www.linuxidc.com/Linux/2014-11/109048.htm
설치 MariaDB와 MySQL이 공존 http://www.linuxidc.com/Linux/2014-11/109047.htm
10 MariaDB에 우분투 5.5에서 MySQL 데이터베이스를 마이그레이션하는 방법 http://www.linuxidc.com/Linux/2014-11/109471.htm
[번역] 우분투 14.04 (트러스티) 서버가 설치 MariaDB http://www.linuxidc.com/Linux/2014-12/110048.htm