프로그램/DB 12

mysql/mariadb tree query

with 를 사용 할 수 없는 환경에서 쿼리 mysql : 8.0 이상 with 사용 가능 mariadb : 10.2.2 이상 with 사용 가능 set @id := 330; select @tmp_id AS tree_company_id ,(SELECT @tmp_id := parent_company_id FROM company WHERE company_id = tree_company_id) AS tree_parent_company_id ,(@tree_level := @tree_level + 1) AS tree_level from ( select @tmp_id := @id,@tree_level := 0 ) AS vars join ( select * from company where 1=1 ) AS h WHE..

프로그램/DB 2019.10.30

MariaDB ColumnStore 1.1.x Install Guide

MariaDB ColumnStore 1.1.x Install Guide 시나리오 서버 3대에 설치 예정 (Centos 6.9) Master 1대 (Parent OAM : UM + PM) 172.16.10.65 pm1 Slave 2대 (PM) 172.16.10.64 pm2 172.16.10.62 pm3 준비작업 firewall off selinux disabled Master에서 모든 Slave에 ssh-key를 배포하여 자동 로그인이 가능하게 한다 [root@pm1 ~]# ssh-keygen [root@pm1 ~]# ssh-copy-id -i ~/.ssh/id_rsa.pub pm2 [root@pm1 ~]# ssh-copy-id -i ~/.ssh/id_rsa.pub pm3 [root@pm1 ~]# ssh-..

프로그램/DB 2018.03.30

mysql community server init root password

centos 에 mysql 을 설치했는데 이놈이 미친건지 처음부터 말썽이다초기 root 비번 설정부터 오류를!!!!! [root@localhost ~]# /usr/bin/mysqladmin -u root -h localhost password 'mypassword'/usr/bin/mysqladmin: connect to server at 'localhost' failederror: 'Access denied for user 'root'@'localhost' (using password: NO)' 우선 서비스를 중단 한다[root@localhost ~]# service mysqld stop 일단 무장 해제? 시키고[root@localhost ~]# mysqld_safe --skip-grant & 쳐들어간다..

프로그램/DB 2014.11.04

centos yum install mariadb 10.0

vi /etc/yum.repo.d/mariadb.repo # MariaDB 10.0 CentOS repository list - created 2014-10-14 01:27 UTC# http://mariadb.org/mariadb/repositories/[mariadb]name = MariaDBbaseurl = http://yum.mariadb.org/10.0/centos6-amd64gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDBgpgcheck=1 yum install -y MariaDB-server 시스템 테이블 설치mysql_install_db --user=mysql 서비스 시작service mysql start mysql에서는 데몬 이름이 mysqld 이었..

프로그램/DB 2014.10.14