2011. 10. 13.

solaris 10 기본 mysql 설정법



cat /etc/sfw/mysql/README.solaris.mysql <- 여기에 나온거 그대로 하면 끝
<아래 내용>
To use mysql a number of post-install procedures need to be made by root.
The following steps are derived from the mysql manual (manual.ps, manual.txt or manual_toc.html) found in the /usr/sfw/src/mysql/Docs directory.
Initialise the database tables.
/usr/sfw/bin/mysql_install_db
Create mysql user and group and change data directory group.
groupadd mysql
useradd -g mysql mysql
chgrp -R mysql /var/mysql
chmod -R 770 /var/mysql
installf SUNWmysqlr /var/mysql d 770 root mysql
MySQL reads configuration files from different places in the following order.

Filename                Purpose
---------               ---------
/etc/my.cnf             Global options

DATADIR/my.cnf          Server-specific options

defaults-extra-file     The file specified with
                        --defaults-extra-file=path

~/.my.cnf               User-specific options
Optionally copy a mysql daemon configuration file to configuration directory.
Note there are other configuration profiles available.
For default solaris installation DATADIR is /var/mysql.# cp /usr/sfw/share/mysql/my-medium.cnf /var/mysql/my.cnf
Start mysql daemon by hand
/usr/sfw/sbin/mysqld_safe --user=mysql &
Optionally perform the following steps for automatic start and stop of mysql daemon at boot and shutdown.
Link boot time start up script from rc3.d and rc[012S].d
ln /etc/sfw/mysql/mysql.server /etc/rc3.d/S99mysql
ln /etc/sfw/mysql/mysql.server /etc/rc0.d/K00mysql
ln /etc/sfw/mysql/mysql.server /etc/rc1.d/K00mysql
ln /etc/sfw/mysql/mysql.server /etc/rc2.d/K00mysql
ln /etc/sfw/mysql/mysql.server /etc/rcS.d/K00mysql
reboot
mysql <- 정상 동작 확인
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2 to server version: 4.0.15-log
 
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
 
mysql>

댓글 없음:

사회 동향] 코로나19 서울 확진자 발생 추이

선거 이후에도 증가 없이 줄어들기를 바라며, 그래프 보여 주는데가 없어서 갱신중 4/17 updated