|
|
|
¸®´ª½ºÆÁ Go Unix Power Tools Online Book
Go Bash Guide
|
|
Read No. 104 article |
2002-02-06 01:19:16 |
|
|
|
|
NickName |
Ç®ºñ´© |
Subject |
ÀϹݰèÁ¤ mysql ¾ÏÈ£ ÀÚµ¿È |
|
|
1. MySql ¼³Á¤ ÆÄÀÏ À§Ä¡
- PREFIX/share/mysql/my-example.cnf
2.Mysql ½ÇÇà ½ºÅ©¸³Æ® À§Ä¡
-PREFIX/share/mysql/mysql.server
#cat mysql.server
...
if test -w / #determine if we should look at the root config file
then #or user config file
conf=/etc/my.cnf
else
conf=$HOME/.my.cnf #Using the users config file
fi
...
#
´Ù½Ã ¸»ÇÏ¿© Mysql ½ÇÇà ½ºÅ©¸³Æ® ÆÄÀÏ ¿¡ ÀÇÇؼ my-example.cnf ÆÄÀÏÀ» PREFIX/etc/my.cnf ¶Ç´Â $HOME/.my.cnf ÆÄÀÏ·Î
º¹»çÇÑ´Ù.
- /etc/my.cnf, PREFIX/etc/my.cnf:Àüü »ç¿ëÀÚ¿¡°Ô Àû¿ë
- $HOME/.my.cnf:ÇØ´ç °èÁ¤ »ç¿ëÀÚ¸¸ Àû¿ë
ex) root »ç¿ëÀÚ¸¸ Àû¿ë ½Ãų°æ¿ì
#cp my-example.conf ~root/.my.cnf
#cat ~root/.my.cnf
...
[client]
password=000000
port=3306
sock=/tmp/mysql.sock
...
#
"000000" ºÎºÐ¿¡ ÀÚ½ÅÀÌ ¼³Á¤ÇÑ Æнº¿öµå¸¦ Àû´Â´Ù. ´Ù¸¥ »ç¿ëÀÚ°¡ ÇԺηΠÆнº¿öµå¸¦ º¸Áö ¸øÇϵµ·Ï Æ۹̼Ç(600)ÀûÀýÇÏ°Ô ¼³Á¤
ÇÑ´Ù.
#
#chmod 600 .my.cnf
|
|
Page Loading [ 0.03 Sec ]
SQL Time [ 0 Sec ]
|
|
|